Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
feelver
Overview
Overview
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
2F-ART
feelver
Commits
6bb31c96
Commit
6bb31c96
authored
Aug 20, 2020
by
Mobile : Art
Browse files
Options
Browse Files
Download
Plain Diff
update
parents
15596b8b
17b588a0
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
235 additions
and
307 deletions
+235
-307
lib/main.dart
+2
-0
lib/model/category/category_model.dart
+33
-31
lib/service/api.dart
+14
-13
lib/ui/favorite/favorite.dart
+29
-28
lib/ui/home/home.dart
+0
-0
lib/ui/home/home_presenter.dart
+15
-10
lib/ui/review_shop/review_shop_page.dart
+108
-81
lib/ui/shop/shop_Nearby_places.dart
+0
-0
lib/ui/shop/shop_list.dart
+20
-98
lib/ui/shop/shop_main.dart
+1
-0
lib/ui/shop/shop_service.dart
+3
-1
pubspec.lock
+10
-45
No files found.
lib/main.dart
View file @
6bb31c96
...
@@ -34,6 +34,8 @@ class MyApp extends StatelessWidget {
...
@@ -34,6 +34,8 @@ class MyApp extends StatelessWidget {
home:
MainShop
()
home:
MainShop
()
//home: EditProfile(),
//home: EditProfile(),
);
);
...
...
lib/model/category/category_model.dart
View file @
6bb31c96
class
CategoryModel
{
List
<
Result
>
result
;
class
categoryModel
{
CategoryModel
({
this
.
result
});
List
<
DATA
>
dATA
;
categoryModel
({
this
.
dATA
});
c
ategoryModel
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
C
ategoryModel
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
if
(
json
[
'
DATA
'
]
!=
null
)
{
if
(
json
[
'
result
'
]
!=
null
)
{
dATA
=
new
List
<
DATA
>();
result
=
new
List
<
Result
>();
json
[
'
DATA
'
].
forEach
((
v
)
{
json
[
'
result
'
].
forEach
((
v
)
{
dATA
.
add
(
new
DATA
.
fromJson
(
v
));
result
.
add
(
new
Result
.
fromJson
(
v
));
});
});
}
}
}
}
Map
<
String
,
dynamic
>
toJson
()
{
Map
<
String
,
dynamic
>
toJson
()
{
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
final
Map
<
String
,
dynamic
>
data
=
new
Map
<
String
,
dynamic
>();
if
(
this
.
dATA
!=
null
)
{
data
[
'DATA'
]
=
this
.
dATA
.
map
((
v
)
=>
v
.
toJson
()).
toList
();
if
(
this
.
result
!=
null
)
{
data
[
'result'
]
=
this
.
result
.
map
((
v
)
=>
v
.
toJson
()).
toList
();
}
}
return
data
;
return
data
;
}
}
}
}
class
DATA
{
class
Result
{
int
id
;
int
id
;
int
parentId
;
int
parentId
;
String
name
;
String
name
;
...
@@ -30,33 +31,34 @@ class DATA {
...
@@ -30,33 +31,34 @@ class DATA {
String
displayName
;
String
displayName
;
String
cover
;
String
cover
;
String
detail
;
String
detail
;
dynamic
type
;
Null
type
;
String
status
;
String
status
;
int
sortOrder
;
int
sortOrder
;
dynamic
storeId
;
Null
storeId
;
dynamic
vendorId
;
Null
vendorId
;
dynamic
createdAt
;
Null
createdAt
;
String
updatedAt
;
String
updatedAt
;
String
visibility
;
String
visibility
;
DATA
(
Result
(
{
this
.
id
,
{
this
.
id
,
this
.
parentId
,
this
.
parentId
,
this
.
name
,
this
.
name
,
this
.
code
,
this
.
code
,
this
.
displayName
,
this
.
displayName
,
this
.
cover
,
this
.
cover
,
this
.
detail
,
this
.
detail
,
this
.
type
,
this
.
type
,
this
.
status
,
this
.
status
,
this
.
sortOrder
,
this
.
sortOrder
,
this
.
storeId
,
this
.
storeId
,
this
.
vendorId
,
this
.
vendorId
,
this
.
createdAt
,
this
.
createdAt
,
this
.
updatedAt
,
this
.
updatedAt
,
this
.
visibility
});
this
.
visibility
});
DATA
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
Result
.
fromJson
(
Map
<
String
,
dynamic
>
json
)
{
id
=
json
[
'id'
];
id
=
json
[
'id'
];
parentId
=
json
[
'parent_id'
];
parentId
=
json
[
'parent_id'
];
name
=
json
[
'name'
];
name
=
json
[
'name'
];
...
...
lib/service/api.dart
View file @
6bb31c96
...
@@ -22,14 +22,14 @@ import 'package:feelverapp/model/shopservice/shop_service_Model.dart';
...
@@ -22,14 +22,14 @@ import 'package:feelverapp/model/shopservice/shop_service_Model.dart';
import
'package:http/http.dart'
as
http
;
import
'package:http/http.dart'
as
http
;
class
Api
<
T
>
{
class
Api
<
T
>
{
final
String
_baseApi
=
"https://backend-uat.feelver.com/api"
;
final
String
_baseApi
=
"https://backend-uat.feelver.com/api"
;
final
_headerApi
=
{
final
_headerApi
=
{
"Authorization"
:
"Authorization"
:
"Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczpcL1wvYmFja2VuZC11YXQuZmVlbHZlci5jb21cL2FwaVwvbG9naW4iLCJpYXQiOjE1OTYxMDAzNTgsImV4cCI6MTYwMzMwMDM1OCwibmJmIjoxNTk2MTAwMzU4LCJqdGkiOiJ2YjA2S0FHR1JtZDFseEw1Iiwic3ViIjozNzMsInBydiI6Ijg3ZTBhZjFlZjlmZDE1ODEyZmRlYzk3MTUzYTE0ZTBiMDQ3NTQ2YWEifQ.UkY70AshvW5O4M63XY_Iv2IPBohSUUwnRF1oi46p2zs"
,
"Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczpcL1wvYmFja2VuZC11YXQuZmVlbHZlci5jb21cL2FwaVwvbG9naW4iLCJpYXQiOjE1OTYxMDAzNTgsImV4cCI6MTYwMzMwMDM1OCwibmJmIjoxNTk2MTAwMzU4LCJqdGkiOiJ2YjA2S0FHR1JtZDFseEw1Iiwic3ViIjozNzMsInBydiI6Ijg3ZTBhZjFlZjlmZDE1ODEyZmRlYzk3MTUzYTE0ZTBiMDQ3NTQ2YWEifQ.UkY70AshvW5O4M63XY_Iv2IPBohSUUwnRF1oi46p2zs"
,
};
};
static
final
String
baseApi
=
"https://backend-uat.feelver.com/api"
;
Future
<
Response
<
T
>>
favorite
(
Object
body
)
async
{
Future
<
Response
<
T
>>
favorite
(
Object
body
)
async
{
var
_model
;
var
_model
;
var
_fail
;
var
_fail
;
...
@@ -44,7 +44,7 @@ class Api<T> {
...
@@ -44,7 +44,7 @@ class Api<T> {
}
else
{
}
else
{
_fail
=
FailModel
.
fromJson
(
json
.
decode
(
response
.
body
));
_fail
=
FailModel
.
fromJson
(
json
.
decode
(
response
.
body
));
}
}
result
=
new
Response
(
_model
,
_fail
);
result
=
new
Response
<
T
>
(
_model
,
_fail
);
});
});
return
result
;
return
result
;
}
}
...
@@ -95,12 +95,12 @@ class Api<T> {
...
@@ -95,12 +95,12 @@ class Api<T> {
var
_model
;
var
_model
;
var
_fail
;
var
_fail
;
var
result
;
var
result
;
print
(
"this is body "
+
body
.
toString
());
//
print("this is body " + body.toString());
// (body as Map)['lang'] = allTranslations.currentLanguage;
// (body as Map)['lang'] = allTranslations.currentLanguage;
await
_httpConnection
(
await
_httpConnection
(
"
${this._baseApi}
/customer/info"
,
this
.
_headerApi
,
body
)
"
${this._baseApi}
/customer/info"
,
this
.
_headerApi
,
body
)
.
then
((
response
)
{
.
then
((
response
)
{
print
(
"ผลลัพ เท่ากับบบบ "
+
"
${response.body}
"
);
//
print("ผลลัพ เท่ากับบบบ " + "${response.body}");
if
(
response
.
statusCode
==
200
)
{
if
(
response
.
statusCode
==
200
)
{
_model
=
GetprofileModel
.
fromJson
(
json
.
decode
(
response
.
body
));
_model
=
GetprofileModel
.
fromJson
(
json
.
decode
(
response
.
body
));
}
else
{
}
else
{
...
@@ -220,21 +220,18 @@ class Api<T> {
...
@@ -220,21 +220,18 @@ class Api<T> {
return
result
;
return
result
;
}
}
Future
<
Response
<
T
>>
category
(
Object
body
)
async
{
Future
<
Response
<
T
>>
category
(
Object
body
)
async
{
var
_model
;
var
_model
;
var
_fail
;
var
_fail
;
var
result
;
var
result
;
// (body as Map)['lang'] = allTranslations.currentLanguage;
await
_httpConnection
(
"
${this._baseApi}
/category"
,
this
.
_headerApi
,
body
)
await
_httpConnection
(
"
${this._baseApi}
/category"
,
this
.
_headerApi
,
body
)
.
then
((
response
)
{
.
then
((
response
)
{
print
(
"ผลลัพ
ท์ เท่ากับ55555 "
"
${response.body}
"
);
print
(
"ผลลัพ
เท่ากับบบบ "
+
"
${response.body}
"
);
if
(
response
.
statusCode
==
200
)
{
if
(
response
.
statusCode
==
200
)
{
// Array to Map Json
_model
=
CategoryModel
.
fromJson
(
json
.
decode
(
response
.
body
));
Map
<
String
,
dynamic
>
myData
=
arrayToJson
(
response
.
body
);
_model
=
categoryModel
.
fromJson
(
myData
);
print
(
'myModel '
+
_model
);
}
else
{
}
else
{
_fail
=
FailModel
.
fromJson
(
json
.
decode
(
response
.
body
));
_fail
=
FailModel
.
fromJson
(
json
.
decode
(
response
.
body
));
}
}
...
@@ -243,6 +240,10 @@ class Api<T> {
...
@@ -243,6 +240,10 @@ class Api<T> {
return
result
;
return
result
;
}
}
Future
<
Response
<
T
>>
shoplist
(
Object
body
)
async
{
Future
<
Response
<
T
>>
shoplist
(
Object
body
)
async
{
var
_model
;
var
_model
;
var
_fail
;
var
_fail
;
...
...
lib/ui/favorite/favorite.dart
View file @
6bb31c96
...
@@ -9,10 +9,9 @@ class Favorite extends StatefulWidget {
...
@@ -9,10 +9,9 @@ class Favorite extends StatefulWidget {
_FavoriteState
createState
()
=>
_FavoriteState
();
_FavoriteState
createState
()
=>
_FavoriteState
();
}
}
class
_FavoriteState
extends
State
<
Favorite
>
with
TickerProviderStateMixin
{
class
_FavoriteState
extends
State
<
Favorite
>
{
bool
checkBoxValue
=
false
;
bool
checkBoxValue
=
false
;
FavoritePresenter
presenter
;
FavoritePresenter
presenter
;
@override
@override
...
@@ -36,7 +35,6 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
...
@@ -36,7 +35,6 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
bottomNavigationBar:
Container
(
bottomNavigationBar:
Container
(
color:
Color
.
fromRGBO
(
69
,
85
,
79
,
1
),
color:
Color
.
fromRGBO
(
69
,
85
,
79
,
1
),
height:
SizeConfig
.
getHeight
(
100
),
height:
SizeConfig
.
getHeight
(
100
),
),
),
);
);
}
}
...
@@ -60,17 +58,21 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
...
@@ -60,17 +58,21 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
bottom:
10
,
bottom:
10
,
),
),
child:
Container
(
child:
Container
(
child:
ListView
.
builder
(
child:
presenter
.
favoriteModel
==
null
itemCount:
5
,
?
Container
()
:
ListView
.
builder
(
itemCount:
presenter
.
favoriteModel
.
wishListItem
.
length
,
itemBuilder:
(
context
,
i
)
{
itemBuilder:
(
context
,
i
)
{
return
list
();
return
list
(
i
);
}),
}),
),
),
),
),
);
);
}
}
Widget
list
()
{
Widget
list
(
int
index
)
{
return
Container
(
return
Container
(
// color: Colors.red,
// color: Colors.red,
margin:
EdgeInsets
.
only
(
bottom:
15
),
margin:
EdgeInsets
.
only
(
bottom:
15
),
...
@@ -81,22 +83,19 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
...
@@ -81,22 +83,19 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
Row
(
Row
(
mainAxisAlignment:
MainAxisAlignment
.
start
,
mainAxisAlignment:
MainAxisAlignment
.
start
,
children:
<
Widget
>[
children:
<
Widget
>[
Padding
(
presenter
.
favoriteModel
==
null
padding:
const
EdgeInsets
.
only
(
left:
10
),
?
Image
.
asset
(
child:
presenter
.
favoriteModel
==
null
'assets/images/demo_img.png'
,
?
Image
.
asset
(
width:
SizeConfig
.
getWidth
(
110
),
'assets/images/demo_img.png'
,
height:
SizeConfig
.
getHeight
(
150
),
width:
SizeConfig
.
getWidth
(
110
),
fit:
BoxFit
.
fitWidth
,
height:
SizeConfig
.
getHeight
(
150
),
)
fit:
BoxFit
.
fitWidth
,
:
Image
.
network
(
)
presenter
.
favoriteModel
.
wishListItem
[
index
].
product
.
cover
,
:
Image
.
network
(
width:
SizeConfig
.
getWidth
(
110
),
presenter
.
favoriteModel
.
wishListItem
[
0
].
product
height:
SizeConfig
.
getHeight
(
150
),
.
cover
,
fit:
BoxFit
.
fitWidth
,
width:
SizeConfig
.
getWidth
(
110
),
),
height:
SizeConfig
.
getHeight
(
150
),
fit:
BoxFit
.
fitWidth
,
)),
Expanded
(
Expanded
(
child:
Container
(
child:
Container
(
padding:
EdgeInsets
.
only
(
padding:
EdgeInsets
.
only
(
...
@@ -111,7 +110,7 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
...
@@ -111,7 +110,7 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
child:
Row
(
child:
Row
(
children:
<
Widget
>[
children:
<
Widget
>[
Text
(
Text
(
'Ivory Relax and Spa'
,
presenter
.
favoriteModel
.
wishListItem
[
index
].
product
.
name
,
style:
TextStyle
(
style:
TextStyle
(
color:
Colors
.
black
,
color:
Colors
.
black
,
fontSize:
SizeConfig
.
getFontSize
(
15
)),
fontSize:
SizeConfig
.
getFontSize
(
15
)),
...
@@ -132,7 +131,7 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
...
@@ -132,7 +131,7 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
child:
Text
(
'นวดเเผนไทย'
,
child:
Text
(
'นวดเเผนไทย'
,
style:
TextStyle
(
style:
TextStyle
(
color:
Colors
.
black
,
color:
Colors
.
black
,
)),
)
,
),
),
),
SizedBox
(
SizedBox
(
height:
SizeConfig
.
getHeight
(
5
),
height:
SizeConfig
.
getHeight
(
5
),
...
@@ -149,14 +148,14 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
...
@@ -149,14 +148,14 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
SizedBox
(
SizedBox
(
width:
SizeConfig
.
getWidth
(
5
),
width:
SizeConfig
.
getWidth
(
5
),
),
),
Text
(
'90 นาที'
),
Text
(
presenter
.
favoriteModel
.
wishListItem
[
index
].
product
.
duration
),
Spacer
(),
Spacer
(),
Icon
(
Icon
(
Icons
.
local_offer
,
Icons
.
local_offer
,
color:
Color
(
0xFFEEAFB7
),
color:
Color
(
0xFFEEAFB7
),
),
),
Text
(
Text
(
'฿1,599.00'
,
"฿"
+
presenter
.
favoriteModel
.
wishListItem
[
index
].
product
.
specialPrice
,
style:
TextStyle
(
style:
TextStyle
(
decoration:
TextDecoration
.
lineThrough
,
decoration:
TextDecoration
.
lineThrough
,
fontSize:
SizeConfig
.
getFontSize
(
16
),
fontSize:
SizeConfig
.
getFontSize
(
16
),
...
@@ -176,7 +175,7 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
...
@@ -176,7 +175,7 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
children:
<
Widget
>[
children:
<
Widget
>[
Spacer
(),
Spacer
(),
Text
(
Text
(
'฿1,200.00'
,
"฿"
+
presenter
.
favoriteModel
.
wishListItem
[
index
].
product
.
price
,
style:
TextStyle
(
style:
TextStyle
(
fontSize:
SizeConfig
.
getFontSize
(
20
),
fontSize:
SizeConfig
.
getFontSize
(
20
),
color:
Color
(
0xFFFD2956
),
color:
Color
(
0xFFFD2956
),
...
@@ -193,12 +192,14 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
...
@@ -193,12 +192,14 @@ class _FavoriteState extends State<Favorite> with TickerProviderStateMixin {
),
),
],
],
),
),
],
],
),
),
),
),
);
);
}
}
Widget
header
()
{
Widget
header
()
{
return
Container
(
return
Container
(
child:
Stack
(
child:
Stack
(
...
...
lib/ui/home/home.dart
View file @
6bb31c96
This diff is collapsed.
Click to expand it.
lib/ui/home/home_presenter.dart
View file @
6bb31c96
...
@@ -21,7 +21,7 @@ class HomePresenter extends BasePresenter<HomePage> {
...
@@ -21,7 +21,7 @@ class HomePresenter extends BasePresenter<HomePage> {
GetprofileModel
getmodel
;
GetprofileModel
getmodel
;
LoginModel
logmodel
;
LoginModel
logmodel
;
c
ategoryModel
CatModel
;
C
ategoryModel
CatModel
;
TextEditingController
searchCtrl
=
TextEditingController
();
TextEditingController
searchCtrl
=
TextEditingController
();
SearchhomeModel
searchhomeModel
;
SearchhomeModel
searchhomeModel
;
...
@@ -29,19 +29,21 @@ class HomePresenter extends BasePresenter<HomePage> {
...
@@ -29,19 +29,21 @@ class HomePresenter extends BasePresenter<HomePage> {
HomePresenter
(
State
<
HomePage
>
state
)
:
super
(
state
);
HomePresenter
(
State
<
HomePage
>
state
)
:
super
(
state
);
Listitem
()
async
{
Listitem
()
async
{
_api
=
Api
<
categoryModel
>();
_api
=
Api
<
CategoryModel
>();
var
res
=
await
_api
.
category
({
var
res
=
await
_api
.
category
({
"access_type"
:
"
portal
"
,
"access_type"
:
"
mobile
"
,
});
});
print
(
"dddddddddddddddd"
);
if
(
res
.
fail
==
null
){
// LoadingView(state.context).hide();
if
(
res
.
success
!=
null
){
setState
(()
{
setState
(()
{
CatModel
=
res
.
success
;
CatModel
=
res
.
success
;
print
(
'
${CatModel.dATA[0].name}
'
);
});
});
}
else
{
}
else
{
...
@@ -50,21 +52,24 @@ class HomePresenter extends BasePresenter<HomePage> {
...
@@ -50,21 +52,24 @@ class HomePresenter extends BasePresenter<HomePage> {
}
}
getSearch
()
async
{
getSearch
()
async
{
LoadingView
(
state
.
context
).
show
();
_api
=
Api
<
SearchhomeModel
>();
_api
=
Api
<
SearchhomeModel
>();
var
res
=
await
_api
.
homesearch
({
var
res
=
await
_api
.
homesearch
({
"keyword_shop"
:
searchCtrl
.
text
,
"keyword_shop"
:
searchCtrl
.
text
,
"lang"
:
"all"
,
"lang"
:
"all"
,
"access"
:
"portal"
,
"access"
:
"portal"
,
});
});
print
(
'
$searchCtrl
'
);
LoadingView
(
state
.
context
).
hide
();
print
(
'
$searchCtrl
'
);
if
(
res
.
fail
==
null
)
if
(
res
.
success
.
status
)
{
if
(
res
.
fail
==
null
)
setState
(()
{
setState
(()
{
searchhomeModel
=
res
.
success
;
searchhomeModel
=
res
.
success
;
category_model
=
res
.
success
;
category_model
=
res
.
success
;
});
});
}
else
{
else
{
}
}
...
@@ -87,7 +92,7 @@ print('$searchCtrl');
...
@@ -87,7 +92,7 @@ print('$searchCtrl');
setState
(()
{
setState
(()
{
getmodel
=
res
.
success
;
getmodel
=
res
.
success
;
});
});
print
(
"Hii"
+
getmodel
.
result
[
0
].
name
);
//
print("Hii" + getmodel.result[0].name);
}
else
{
}
else
{
Alert
(
Alert
(
style:
AlertStyle
(
style:
AlertStyle
(
...
...
lib/ui/review_shop/review_shop_page.dart
View file @
6bb31c96
...
@@ -36,47 +36,39 @@ class _ReviewShopPageState extends State<ReviewShopPage> {
...
@@ -36,47 +36,39 @@ class _ReviewShopPageState extends State<ReviewShopPage> {
child:
Column
(
child:
Column
(
children:
<
Widget
>[
children:
<
Widget
>[
texttop
(),
texttop
(),
star
(),
containt
(),
containt
(),
],
],
),
),
);
);
}
}
Widget
texttop
(){
Widget
containt
()
{
return
Container
(
return
Expanded
(
margin:
EdgeInsets
.
only
(
child:
Container
(
right:
SizeConfig
.
getPadding
(
16
),
child:
ListView
.
builder
(
left:
SizeConfig
.
getPadding
(
16
),
itemCount:
3
,
top:
SizeConfig
.
getPadding
(
5
),
itemBuilder:
(
context
,
i
)
{
bottom:
SizeConfig
.
getPadding
(
10
)),
return
list
();
child:
Row
(
}),
children:
<
Widget
>[
),
Text
(
'รีวิว(จากผู้ใช้บริการจริง)'
,
style:
TextStyle
(
color:
Color
(
0xFF6AB3AA
),
fontSize:
SizeConfig
.
getFontSize
(
14
),
),
),
Spacer
(),
],
),
);
);
}
}
Widget
containt
(){
Widget
star
()
{
return
Card
(
return
Container
(
// color: Colors.blue,
margin:
EdgeInsets
.
only
(
margin:
EdgeInsets
.
only
(
right:
SizeConfig
.
getPadding
(
16
),
right:
SizeConfig
.
getPadding
(
16
),
left:
SizeConfig
.
getPadding
(
16
),
left:
SizeConfig
.
getPadding
(
16
),
top:
SizeConfig
.
getPadding
(
2
0
),
top:
SizeConfig
.
getPadding
(
1
0
),
bottom:
SizeConfig
.
getPadding
(
10
)),
bottom:
SizeConfig
.
getPadding
(
10
)),
child:
Container
(
child:
Container
(
margin:
EdgeInsets
.
only
(
// color: Colors.red,
padding:
EdgeInsets
.
only
(
right:
SizeConfig
.
getPadding
(
15
),
right:
SizeConfig
.
getPadding
(
15
),
left:
SizeConfig
.
getPadding
(
15
),
left:
SizeConfig
.
getPadding
(
15
),
bottom:
SizeConfig
.
getPadding
(
20
),
top:
SizeConfig
.
getPadding
(
10
),
top:
SizeConfig
.
getPadding
(
20
),
),
),
// color: Colors.blueGrey,
// color: Colors.blueGrey,
child:
Column
(
child:
Column
(
...
@@ -229,9 +221,25 @@ class _ReviewShopPageState extends State<ReviewShopPage> {
...
@@ -229,9 +221,25 @@ class _ReviewShopPageState extends State<ReviewShopPage> {
Divider
(
Divider
(
color:
Color
(
0xFF606060
),
color:
Color
(
0xFF606060
),
),
),
Container
(
],
color:
Colors
.
deepPurpleAccent
,
),
child:
Row
(
),
);
}
Widget
list
()
{
return
Card
(
child:
Container
(
// color: Colors.deepPurpleAccent,
margin:
EdgeInsets
.
only
(
right:
SizeConfig
.
getPadding
(
20
),
left:
SizeConfig
.
getPadding
(
20
),
top:
SizeConfig
.
getPadding
(
10
),
bottom:
SizeConfig
.
getPadding
(
10
),
),
child:
Column
(
children:
<
Widget
>[
Row
(
children:
<
Widget
>[
children:
<
Widget
>[
ClipRRect
(
ClipRRect
(
borderRadius:
BorderRadius
.
circular
(
50
),
borderRadius:
BorderRadius
.
circular
(
50
),
...
@@ -247,7 +255,7 @@ class _ReviewShopPageState extends State<ReviewShopPage> {
...
@@ -247,7 +255,7 @@ class _ReviewShopPageState extends State<ReviewShopPage> {
),
),
Expanded
(
Expanded
(
child:
Container
(
child:
Container
(
color:
Colors
.
green
,
//
color: Colors.green,
child:
Column
(
child:
Column
(
crossAxisAlignment:
CrossAxisAlignment
.
start
,
crossAxisAlignment:
CrossAxisAlignment
.
start
,
children:
<
Widget
>[
children:
<
Widget
>[
...
@@ -295,70 +303,89 @@ class _ReviewShopPageState extends State<ReviewShopPage> {
...
@@ -295,70 +303,89 @@ class _ReviewShopPageState extends State<ReviewShopPage> {
),
),
],
],
),
),
),
Container
(
Container
(
// color: Colors.blue,
color:
Colors
.
blue
,
child:
Column
(
child:
Column
(
children:
<
Widget
>[
children:
<
Widget
>[
Padding
(
Padding
(
padding:
const
EdgeInsets
.
only
(
padding:
const
EdgeInsets
.
only
(
top:
10
,
bottom:
10
,
left:
2
,
right:
2
),
top:
10
,
bottom:
10
,
left:
2
,
right:
2
),
child:
Text
(
child:
Text
(
'การบริการและบรรยากาศดีมาก มีห้องอาบน้ำพร้อมผ้าเช็ดตัว สบู่ ครีมสระผม พนักงานดูแลเอาใจใส่ และคอยแนะนำตลอดจนถึง therapist มีความเป็นมืออาชีพให้ความผ่อนคลายแก่ลูกค้า'
,
'การบริการและบรรยากาศดีมาก มีห้องอาบน้ำพร้อมผ้าเช็ดตัว สบู่ ครีมสระผม พนักงานดูแลเอาใจใส่ และคอยแนะนำตลอดจนถึง therapist มีความเป็นมืออาชีพให้ความผ่อนคลายแก่ลูกค้า'
,
style:
TextStyle
(
style:
TextStyle
(
fontSize:
SizeConfig
.
getFontSize
(
12
),
fontSize:
SizeConfig
.
getFontSize
(
12
),
),
),
),
Row
(
children:
<
Widget
>[
RaisedButton
(
color:
Color
(
0xFF3694A3
),
shape:
RoundedRectangleBorder
(
borderRadius:
BorderRadius
.
circular
(
20
),
),
onPressed:
()
{},
child:
Text
(
"บริการดีมาก"
,
style:
TextStyle
(
color:
Colors
.
white
,
),
),
),
),
),
SizedBox
(
),
width:
SizeConfig
.
getWidth
(
14
),
Row
(
),
children:
<
Widget
>[
RaisedButton
(
RaisedButton
(
color:
Color
(
0xFF3694A3
),
color:
Color
(
0xFF3694A3
),
shape:
RoundedRectangleBorder
(
shape:
RoundedRectangleBorder
(
borderRadius:
BorderRadius
.
circular
(
20
),
borderRadius:
BorderRadius
.
circular
(
20
),
),
onPressed:
()
{},
child:
Padding
(
padding:
const
EdgeInsets
.
only
(
right:
10
,
left:
10
,
),
),
onPressed:
()
{},
child:
Text
(
child:
Text
(
"
คุ้มค่าดี
"
,
"
บริการดีมาก
"
,
style:
TextStyle
(
style:
TextStyle
(
color:
Colors
.
white
,
color:
Colors
.
white
,
),
),
),
),
),
),
),
SizedBox
(
],
width:
SizeConfig
.
getWidth
(
14
),
),
),
SizedBox
(
RaisedButton
(
height:
SizeConfig
.
getHeight
(
10
),
color:
Color
(
0xFF3694A3
),
),
shape:
RoundedRectangleBorder
(
],
borderRadius:
BorderRadius
.
circular
(
20
),
),
onPressed:
()
{},
child:
Padding
(
padding:
const
EdgeInsets
.
only
(
right:
10
,
left:
10
,
),
child:
Text
(
"คุ้มค่าดี"
,
style:
TextStyle
(
color:
Colors
.
white
,
),
),
),
),
],
),
SizedBox
(
height:
SizeConfig
.
getHeight
(
10
),
),
],
),
),
),
],
)),
);
}
Widget
texttop
()
{
return
Container
(
margin:
EdgeInsets
.
only
(
right:
SizeConfig
.
getPadding
(
16
),
left:
SizeConfig
.
getPadding
(
16
),
top:
SizeConfig
.
getPadding
(
15
),
bottom:
SizeConfig
.
getPadding
(
5
)),
child:
Row
(
children:
<
Widget
>[
Text
(
'รีวิว(จากผู้ใช้บริการจริง)'
,
style:
TextStyle
(
color:
Color
(
0xFF6AB3AA
),
fontSize:
SizeConfig
.
getFontSize
(
14
),
),
),
],
),
),
Spacer
(),
],
),
),
);
);
}
}
}
}
lib/ui/shop/shop_Nearby_places.dart
View file @
6bb31c96
This diff is collapsed.
Click to expand it.
lib/ui/shop/shop_list.dart
View file @
6bb31c96
...
@@ -345,6 +345,24 @@ class _ShopListState extends State<ShopList> with TickerProviderStateMixin {
...
@@ -345,6 +345,24 @@ class _ShopListState extends State<ShopList> with TickerProviderStateMixin {
fontWeight:
FontWeight
.
w700
),
fontWeight:
FontWeight
.
w700
),
),
),
),
),
Positioned
(
left:
SizeConfig
.
getPadding
(
280
),
top:
SizeConfig
.
getPadding
(
190
),
child:
Icon
(
Icons
.
star
,
color:
Colors
.
orangeAccent
,
size:
SizeConfig
.
getFontSize
(
18
),),
),
Positioned
(
left:
SizeConfig
.
getPadding
(
300
),
top:
SizeConfig
.
getPadding
(
190
),
child:
Text
(
"4.9"
,
textAlign:
TextAlign
.
left
,
style:
TextStyle
(
color:
Colors
.
black
,
fontSize:
SizeConfig
.
getFontSize
(
12
),
fontFamily:
"SF_Pro_Text"
,
fontWeight:
FontWeight
.
w700
),
),
),
],
],
),
),
),
),
...
@@ -390,104 +408,8 @@ class _ShopListState extends State<ShopList> with TickerProviderStateMixin {
...
@@ -390,104 +408,8 @@ class _ShopListState extends State<ShopList> with TickerProviderStateMixin {
fontWeight:
FontWeight
.
w700
),
fontWeight:
FontWeight
.
w700
),
),
),
),
),
Row
(
children:
<
Widget
>[
SizedBox
(
width:
SizeConfig
.
getWidth
(
20
),
),
Image
.
asset
(
'assets/images/clock.png'
,
width:
SizeConfig
.
getWidth
(
20
),
height:
SizeConfig
.
getWidth
(
20
),
),
SizedBox
(
width:
SizeConfig
.
getWidth
(
10
),
),
Text
(
'90 นาที'
,
textAlign:
TextAlign
.
left
,
style:
TextStyle
(
color:
Colors
.
black87
,
fontSize:
SizeConfig
.
getFontSize
(
12
),
fontFamily:
"SF_Pro_Text"
,
fontWeight:
FontWeight
.
w500
),
),
SizedBox
(
width:
SizeConfig
.
getWidth
(
30
),
),
Image
.
asset
(
'assets/images/sell.png'
,
width:
SizeConfig
.
getWidth
(
20
),
height:
SizeConfig
.
getWidth
(
20
),
),
SizedBox
(
width:
SizeConfig
.
getWidth
(
5
),
),
Text
(
'฿1,599.00 '
,
textAlign:
TextAlign
.
left
,
style:
TextStyle
(
color:
Color
.
fromRGBO
(
238
,
175
,
183
,
1
),
fontSize:
SizeConfig
.
getFontSize
(
12
),
decoration:
TextDecoration
.
lineThrough
,
fontFamily:
"SF_Pro_Text"
,
fontWeight:
FontWeight
.
w500
),
),
SizedBox
(
width:
SizeConfig
.
getWidth
(
5
),
),
Text
(
'฿1,599.00 '
,
textAlign:
TextAlign
.
left
,
style:
TextStyle
(
color:
Color
.
fromRGBO
(
253
,
41
,
86
,
1
),
fontSize:
SizeConfig
.
getFontSize
(
22
),
fontFamily:
"SF_Pro_Text"
,
fontWeight:
FontWeight
.
w700
),
),
],
),
InkWell
(
onTap:
()
{
Navigator
.
push
(
context
,
MaterialPageRoute
(
builder:
(
context
)
=>
ShopListDetail
(),
),
);
},
child:
Stack
(
children:
<
Widget
>[
Container
(
child:
Image
.
asset
(
'assets/images/btn_shoplist.png'
),
padding:
EdgeInsets
.
only
(
left:
SizeConfig
.
getPadding
(
20
),
right:
SizeConfig
.
getPadding
(
20
),
top:
SizeConfig
.
getPadding
(
20
),
bottom:
SizeConfig
.
getPadding
(
20
),
),
),
Container
(
alignment:
Alignment
.
center
,
child:
Text
(
'หยิบใส่รถเข็น'
,
textAlign:
TextAlign
.
center
,
style:
TextStyle
(
color:
Colors
.
white
,
fontSize:
SizeConfig
.
getFontSize
(
14
),
fontFamily:
"SF_Pro_Text"
,
fontWeight:
FontWeight
.
w700
),
),
padding:
EdgeInsets
.
only
(
left:
SizeConfig
.
getPadding
(
60
),
right:
SizeConfig
.
getPadding
(
20
),
top:
SizeConfig
.
getPadding
(
30
),
bottom:
SizeConfig
.
getPadding
(
20
),
),
)
],
),
)
],
],
),
),
);
);
...
...
lib/ui/shop/shop_main.dart
View file @
6bb31c96
...
@@ -273,6 +273,7 @@ class _MainShopState extends State<MainShop>
...
@@ -273,6 +273,7 @@ class _MainShopState extends State<MainShop>
},
},
),
),
],
],
),
),
),
),
Expanded
(
Expanded
(
...
...
lib/ui/shop/shop_service.dart
View file @
6bb31c96
...
@@ -3,6 +3,8 @@ import 'package:feelverapp/util/SizeConfig.dart';
...
@@ -3,6 +3,8 @@ import 'package:feelverapp/util/SizeConfig.dart';
import
'package:feelverapp/util/rating_star.dart'
;
import
'package:feelverapp/util/rating_star.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter/material.dart'
;
import
'../../service/api.dart'
;
class
ShopServicePage
extends
StatefulWidget
{
class
ShopServicePage
extends
StatefulWidget
{
@override
@override
_ShopServicePageState
createState
()
=>
_ShopServicePageState
();
_ShopServicePageState
createState
()
=>
_ShopServicePageState
();
...
@@ -76,7 +78,7 @@ class _ShopServicePageState extends State<ShopServicePage>
...
@@ -76,7 +78,7 @@ class _ShopServicePageState extends State<ShopServicePage>
:
Image
.
network
(
:
Image
.
network
(
'https://backend.feelver.com/storage/'
+
image
,
'https://backend.feelver.com/storage/'
+
image
,
fit:
BoxFit
.
cover
,
fit:
BoxFit
.
cover
,
)),
)
,
),
),
),
Expanded
(
Expanded
(
flex:
5
,
flex:
5
,
...
...
pubspec.lock
View file @
6bb31c96
# Generated by pub
# Generated by pub
# See https://dart.dev/tools/pub/glossary#lockfile
# See https://dart.dev/tools/pub/glossary#lockfile
packages:
packages:
archive:
dependency: transitive
description:
name: archive
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.13"
args:
dependency: transitive
description:
name: args
url: "https://pub.dartlang.org"
source: hosted
version: "1.6.0"
async:
async:
dependency: transitive
dependency: transitive
description:
description:
...
@@ -78,6 +64,13 @@ packages:
...
@@ -78,6 +64,13 @@ packages:
url: "https://pub.dartlang.org"
url: "https://pub.dartlang.org"
source: hosted
source: hosted
version: "1.0.8"
version: "1.0.8"
fake_async:
dependency: transitive
description:
name: fake_async
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0"
file:
file:
dependency: transitive
dependency: transitive
description:
description:
...
@@ -142,13 +135,6 @@ packages:
...
@@ -142,13 +135,6 @@ packages:
url: "https://pub.dartlang.org"
url: "https://pub.dartlang.org"
source: hosted
source: hosted
version: "3.1.4"
version: "3.1.4"
image:
dependency: transitive
description:
name: image
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.12"
image_cropper:
image_cropper:
dependency: "direct main"
dependency: "direct main"
description:
description:
...
@@ -225,7 +211,7 @@ packages:
...
@@ -225,7 +211,7 @@ packages:
name: path_provider_platform_interface
name: path_provider_platform_interface
url: "https://pub.dartlang.org"
url: "https://pub.dartlang.org"
source: hosted
source: hosted
version: "1.0.
2
"
version: "1.0.
3
"
pedantic:
pedantic:
dependency: transitive
dependency: transitive
description:
description:
...
@@ -233,13 +219,6 @@ packages:
...
@@ -233,13 +219,6 @@ packages:
url: "https://pub.dartlang.org"
url: "https://pub.dartlang.org"
source: hosted
source: hosted
version: "1.9.0"
version: "1.9.0"
petitparser:
dependency: transitive
description:
name: petitparser
url: "https://pub.dartlang.org"
source: hosted
version: "2.4.0"
platform:
platform:
dependency: transitive
dependency: transitive
description:
description:
...
@@ -275,13 +254,6 @@ packages:
...
@@ -275,13 +254,6 @@ packages:
url: "https://pub.dartlang.org"
url: "https://pub.dartlang.org"
source: hosted
source: hosted
version: "1.4.4"
version: "1.4.4"
quiver:
dependency: transitive
description:
name: quiver
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.3"
rflutter_alert:
rflutter_alert:
dependency: "direct main"
dependency: "direct main"
description:
description:
...
@@ -412,7 +384,7 @@ packages:
...
@@ -412,7 +384,7 @@ packages:
name: url_launcher_web
name: url_launcher_web
url: "https://pub.dartlang.org"
url: "https://pub.dartlang.org"
source: hosted
source: hosted
version: "0.1.2"
version: "0.1.2
+1
"
vector_math:
vector_math:
dependency: transitive
dependency: transitive
description:
description:
...
@@ -427,13 +399,6 @@ packages:
...
@@ -427,13 +399,6 @@ packages:
url: "https://pub.dartlang.org"
url: "https://pub.dartlang.org"
source: hosted
source: hosted
version: "0.1.0"
version: "0.1.0"
xml:
dependency: transitive
description:
name: xml
url: "https://pub.dartlang.org"
source: hosted
version: "3.6.1"
sdks:
sdks:
dart: ">=2.9.0-14.0.dev <3.0.0"
dart: ">=2.9.0-14.0.dev <3.0.0"
flutter: ">=1.12.13+hotfix.5 <2.0.0"
flutter: ">=1.12.13+hotfix.5 <2.0.0"
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