Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
T
Tour Travel Agency AGR
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dio Maulana
Tour Travel Agency AGR
Commits
8e4309f6
Commit
8e4309f6
authored
May 26, 2023
by
Dio Maulana
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
history page
parent
0249322d
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
217 additions
and
0 deletions
+217
-0
history.dart
lib/page/history/history.dart
+213
-0
routes.dart
lib/resource/routes.dart
+4
-0
No files found.
lib/page/history/history.dart
0 → 100644
View file @
8e4309f6
import
'package:flutter/material.dart'
;
import
'package:tour_travel_agr/helper/components_widget/custom_appbar.dart'
;
import
'package:tour_travel_agr/helper/components_widget/transaction_list.dart'
;
import
'package:tour_travel_agr/helper/widget_responsive.dart'
;
import
'package:tour_travel_agr/resource/assets.dart'
;
import
'package:tour_travel_agr/resource/colors.dart'
;
import
'package:tour_travel_agr/resource/font.dart'
;
import
'package:tour_travel_agr/resource/size.dart'
;
import
'package:tour_travel_agr/resource/style.dart'
;
class
HistoryView
extends
StatelessWidget
{
const
HistoryView
({
super
.
key
});
@override
Widget
build
(
BuildContext
context
)
{
return
Scaffold
(
backgroundColor:
ColorManager
.
backgroundColor
,
body:
ScreenResponsive
(
widget:
const
BodyWidget
(),
widthScreen:
MediaQuery
.
of
(
context
).
size
.
width
,
),
);
}
}
class
BodyWidget
extends
StatelessWidget
{
const
BodyWidget
({
super
.
key
,
});
@override
Widget
build
(
BuildContext
context
)
{
return
Container
(
padding:
EdgeInsets
.
only
(
top:
AppPadding
.
safeAreaTop
(
context
),
left:
AppPadding
.
p20
,
right:
AppPadding
.
p20
,
bottom:
AppPadding
.
safeAreaBot
(
context
),
),
child:
Column
(
children:
[
const
CustomAppBar
(
text:
"Transaksi"
),
Container
(
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
5
,
),
border:
Border
.
all
(
color:
ColorManager
.
grey
.
withOpacity
(
0.25
,
),
),
),
margin:
EdgeInsets
.
only
(
top:
AppMargin
.
m16
,
bottom:
AppMargin
.
m20
,
),
padding:
EdgeInsets
.
symmetric
(
horizontal:
AppPadding
.
p20
,
vertical:
AppPadding
.
p9
,
),
child:
Center
(
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
children:
[
Text
(
"24 Maret 2023"
,
style:
getSemiBoldStyle
(
color:
Colors
.
black
,
fontFamily:
FontConstants
.
openSans
,
),
),
Image
(
image:
AssetImage
(
Assets
.
calenderIcon
,
),
)
],
),
),
),
Row
(
children:
[
WidgetHead
(
text:
"Transaksi"
,
icon:
Assets
.
moneyIcon
,
iconColor:
ColorManager
.
pink
,
countText:
"10"
,
countTextColor:
ColorManager
.
primary
,
),
SizedBox
(
width:
AppMargin
.
m8
,
),
WidgetHead
(
text:
"Total"
,
icon:
Assets
.
totalIcon
,
iconColor:
ColorManager
.
softGreen
,
countText:
"Ro 1.200.000"
,
countTextColor:
ColorManager
.
green
,
),
],
),
SizedBox
(
height:
AppMargin
.
m20
,
),
Expanded
(
child:
ListView
.
builder
(
padding:
EdgeInsets
.
zero
,
itemCount:
10
,
itemBuilder:
(
c
,
index
)
{
return
const
ListTransaction
(
date:
"10 Maret 2023"
,
title:
"AGR Surabaya"
,
subtitle:
"Rp 520.000"
,
);
},
),
),
],
),
);
}
}
class
WidgetHead
extends
StatelessWidget
{
const
WidgetHead
({
super
.
key
,
required
this
.
text
,
required
this
.
icon
,
required
this
.
countText
,
required
this
.
iconColor
,
required
this
.
countTextColor
,
});
final
String
text
;
final
String
icon
;
final
Color
iconColor
;
final
String
countText
;
final
Color
countTextColor
;
@override
Widget
build
(
BuildContext
context
)
{
return
Expanded
(
child:
Container
(
width:
double
.
infinity
,
height:
129
,
padding:
EdgeInsets
.
all
(
AppPadding
.
p15
),
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
12
,
),
color:
ColorManager
.
backgroundColor
,
boxShadow:
[
BoxShadow
(
color:
Colors
.
grey
.
withOpacity
(
0.3
),
blurRadius:
2
,
offset:
const
Offset
(
5
,
5
),
),
],
),
child:
Column
(
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
children:
[
Row
(
crossAxisAlignment:
CrossAxisAlignment
.
start
,
children:
[
Container
(
width:
32
,
height:
32
,
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
100
),
color:
iconColor
,
),
margin:
EdgeInsets
.
only
(
right:
AppMargin
.
m8
,
),
child:
Center
(
child:
Image
(
width:
20
,
height:
20
,
image:
AssetImage
(
icon
,
),
),
),
),
Text
(
text
,
style:
getSemiBoldStyle
(
color:
Colors
.
black
,
fontFamily:
FontConstants
.
openSans
,
),
)
],
),
Row
(
children:
[
const
Spacer
(),
Text
(
countText
,
style:
getSemiBoldStyle
(
color:
countTextColor
,
fontSize:
16
,
fontFamily:
FontConstants
.
openSans
,
),
)
],
)
],
),
),
);
}
}
lib/resource/routes.dart
View file @
8e4309f6
import
'package:flutter/material.dart'
;
import
'package:tour_travel_agr/page/history/history.dart'
;
import
'package:tour_travel_agr/page/profile/change_password/change_password.dart'
;
import
'package:tour_travel_agr/page/forgot_password/forgot_password.dart'
;
import
'package:tour_travel_agr/page/login/login.dart'
;
...
...
@@ -60,6 +61,9 @@ class RouteGenerator {
case
Routes
.
reimburseRoute
:
return
pageRouteCustom
(
const
ReimbursementView
(),
nameRoute:
Routes
.
reimburseRoute
);
case
Routes
.
historyRoute
:
return
pageRouteCustom
(
const
HistoryView
(),
nameRoute:
Routes
.
historyRoute
);
default
:
return
unDefinedRoute
();
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment