Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
getmerider
Project
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
amal
getmerider
Commits
9db80bc1
Commit
9db80bc1
authored
Sep 04, 2019
by
Adarsh K
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
awaiting customer approval
parent
c026171d
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
38 additions
and
5 deletions
+38
-5
config.xml
config.xml
+2
-0
app.component.ts
src/app/app.component.ts
+2
-1
riderlounge.page.html
src/app/riderlounge/riderlounge.page.html
+19
-0
riderlounge.page.ts
src/app/riderlounge/riderlounge.page.ts
+8
-4
myorder.service.ts
src/config/myorder.service.ts
+7
-0
No files found.
config.xml
View file @
9db80bc1
...
@@ -14,6 +14,8 @@
...
@@ -14,6 +14,8 @@
<preference
name=
"ScrollEnabled"
value=
"false"
/>
<preference
name=
"ScrollEnabled"
value=
"false"
/>
<preference
name=
"android-minSdkVersion"
value=
"19"
/>
<preference
name=
"android-minSdkVersion"
value=
"19"
/>
<preference
name=
"BackupWebStorage"
value=
"none"
/>
<preference
name=
"BackupWebStorage"
value=
"none"
/>
<preference
name=
"orientation"
value=
"portrait"
/>
<preference
name=
"ShowSplashScreenSpinner"
value=
"false"
/>
<preference
name=
"SplashMaintainAspectRatio"
value=
"true"
/>
<preference
name=
"SplashMaintainAspectRatio"
value=
"true"
/>
<preference
name=
"FadeSplashScreenDuration"
value=
"300"
/>
<preference
name=
"FadeSplashScreenDuration"
value=
"300"
/>
<preference
name=
"SplashShowOnlyFirstTime"
value=
"false"
/>
<preference
name=
"SplashShowOnlyFirstTime"
value=
"false"
/>
...
...
src/app/app.component.ts
View file @
9db80bc1
...
@@ -21,7 +21,8 @@ export class AppComponent {
...
@@ -21,7 +21,8 @@ export class AppComponent {
this
.
platform
.
ready
().
then
(()
=>
{
this
.
platform
.
ready
().
then
(()
=>
{
this
.
statusBar
.
styleDefault
();
this
.
statusBar
.
styleDefault
();
this
.
splashScreen
.
hide
();
this
.
splashScreen
.
hide
();
this
.
statusBar
.
overlaysWebView
(
false
);
this
.
statusBar
.
overlaysWebView
(
true
);
this
.
statusBar
.
hide
();
});
});
}
}
...
...
src/app/riderlounge/riderlounge.page.html
View file @
9db80bc1
...
@@ -143,6 +143,25 @@
...
@@ -143,6 +143,25 @@
</div>
</div>
</div>
</div>
</ion-slide>
</ion-slide>
<ion-slide>
<div
class=
"order_acceptance"
>
<div
class=
"order_acceptance_inner"
>
<div
class=
"order_place pt0"
>
<div
class=
"order_place_image"
></div>
<div
class=
"order_place_detail"
style=
"width: calc(100% - 90px);"
>
<h5>
John Doe
</h5>
<p>
{{order.deliveryAddress}}
</p>
</div>
<div
class=
"toggle_btn floatRight"
(
click
)="
goToPage
('
ridedetails
')"
></div>
<div
class=
"clear"
></div>
</div>
<hr>
Awaiting for customer approval
<div
class=
"clear"
></div>
</div>
</div>
</ion-slide>
</ion-slides>
</ion-slides>
</div>
</div>
</div>
</div>
...
...
src/app/riderlounge/riderlounge.page.ts
View file @
9db80bc1
...
@@ -85,11 +85,15 @@ export class RiderloungePage implements OnInit {
...
@@ -85,11 +85,15 @@ export class RiderloungePage implements OnInit {
next
(
status
:
number
)
{
next
(
status
:
number
)
{
this
.
myorder
.
rideStatus
(
status
).
then
((
data
)
=>
{
this
.
myorder
.
rideStatus
(
status
).
then
((
data
)
=>
{
if
(
status
===
7
)
{
if
(
status
===
7
)
{
this
.
myorder
.
rideChange
(
this
.
myorder
.
selItem
.
orderId
,
0
);
this
.
myorder
.
getStatus
(
this
.
myorder
.
selItem
.
orderId
).
subscribe
((
res
)
=>
{
this
.
goToPage
(
'complete'
);
console
.
log
(
res
);
}
else
{
if
(
res
[
0
].
orderStatus
===
9
)
{
this
.
slides
.
slideNext
();
this
.
myorder
.
rideChange
(
this
.
myorder
.
selItem
.
orderId
,
0
);
this
.
goToPage
(
'complete'
);
}
});
}
}
this
.
slides
.
slideNext
();
this
.
myorder
.
selItem
.
orderStatus
=
status
;
this
.
myorder
.
selItem
.
orderStatus
=
status
;
});
});
}
}
...
...
src/config/myorder.service.ts
View file @
9db80bc1
...
@@ -3,6 +3,7 @@ import { AngularFirestore, AngularFirestoreDocument, AngularFirestoreCollection
...
@@ -3,6 +3,7 @@ import { AngularFirestore, AngularFirestoreDocument, AngularFirestoreCollection
import
{
Myorder
}
from
'./services/myorder'
;
import
{
Myorder
}
from
'./services/myorder'
;
import
{
ServiceService
}
from
'./../config/service.service'
;
import
{
ServiceService
}
from
'./../config/service.service'
;
import
*
as
firebase
from
'firebase'
;
import
*
as
firebase
from
'firebase'
;
import
{
Observable
,
Subject
}
from
'rxjs'
;
@
Injectable
({
@
Injectable
({
providedIn
:
'root'
providedIn
:
'root'
...
@@ -17,6 +18,7 @@ export class MyordersService {
...
@@ -17,6 +18,7 @@ export class MyordersService {
public
afs
:
AngularFirestore
,
public
afs
:
AngularFirestore
,
public
service
:
ServiceService
public
service
:
ServiceService
)
{
)
{
this
.
riderId
=
'LVIMCEdUOGMzYxISL5OkMUPD35Q2'
;
const
users
=
this
.
service
.
get
(
'user'
).
then
((
data
)
=>
{
const
users
=
this
.
service
.
get
(
'user'
).
then
((
data
)
=>
{
if
(
data
)
{
if
(
data
)
{
data
=
JSON
.
parse
(
data
);
data
=
JSON
.
parse
(
data
);
...
@@ -97,6 +99,11 @@ export class MyordersService {
...
@@ -97,6 +99,11 @@ export class MyordersService {
}
}
}
}
public
getStatus
(
orderId
):
Observable
<
any
>
{
const
orderRef
:
AngularFirestoreCollection
<
any
>
=
this
.
afs
.
collection
(
'orders'
,
ref
=>
ref
.
where
(
'orderId'
,
'=='
,
orderId
));
return
orderRef
.
valueChanges
();
}
public
async
rideReject
(
riderId
:
string
)
{
public
async
rideReject
(
riderId
:
string
)
{
this
.
afs
.
collection
(
'orders'
).
doc
(
riderId
).
update
({
riderId
:
''
}).
then
(()
=>
{
this
.
afs
.
collection
(
'orders'
).
doc
(
riderId
).
update
({
riderId
:
''
}).
then
(()
=>
{
console
.
log
(
'Booking Rejected'
);
console
.
log
(
'Booking Rejected'
);
...
...
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