Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nemt_backend
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
Tobin
nemt_backend
Commits
fb2d85e1
Commit
fb2d85e1
authored
Oct 23, 2018
by
Tobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
daily commit
parent
25040841
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
454 additions
and
234 deletions
+454
-234
Driver.php
application/controllers/Driver.php
+15
-1
Ride.php
application/controllers/Ride.php
+15
-2
Driver_model.php
application/models/Driver_model.php
+1
-0
Ride_model.php
application/models/Ride_model.php
+3
-1
driver_list.php
application/views/Driver/driver_list.php
+121
-8
view.php
application/views/Driver/view.php
+8
-8
generate.php
application/views/Report/generate.php
+2
-22
assign_driver.php
application/views/Ride/assign_driver.php
+42
-68
view_rides.php
application/views/Ride/view_rides.php
+99
-72
viewSettings.php
application/views/Settings/viewSettings.php
+10
-9
footer-script.php
application/views/Templates/footer-script.php
+32
-23
footer.php
application/views/Templates/footer.php
+28
-7
header-script.php
application/views/Templates/header-script.php
+5
-0
left-menu.php
application/views/Templates/left-menu.php
+6
-4
custom-style.css
assets/css/custom-style.css
+23
-0
loader.gif
assets/images/loader.gif
+0
-0
nemt_custom.js
assets/js/nemt_custom.js
+42
-7
index.php
index.php
+2
-2
No files found.
application/controllers/Driver.php
View file @
fb2d85e1
...
@@ -253,6 +253,19 @@ class Driver extends CI_Controller {
...
@@ -253,6 +253,19 @@ class Driver extends CI_Controller {
$this
->
session
->
set_flashdata
(
'message'
,
$flashMsg
);
$this
->
session
->
set_flashdata
(
'message'
,
$flashMsg
);
redirect
(
base_url
(
'Driver/edit/'
.
encode_param
(
$driver_id
)));
redirect
(
base_url
(
'Driver/edit/'
.
encode_param
(
$driver_id
)));
}
}
function
getDriverData
(){
$return_arr
=
array
(
'status'
=>
'0'
);
if
(
!
isset
(
$_POST
)
||
empty
(
$_POST
)
||
!
isset
(
$_POST
[
'driver_id'
])
||
empty
(
$_POST
[
'driver_id'
])){
echo
json_encode
(
$return_arr
);
exit
;
}
$driver_id
=
decode_param
(
$_POST
[
'driver_id'
]);
$driver_data
=
$this
->
Driver_model
->
getDriver
(
$driver_id
);
if
(
!
empty
(
$driver_data
)){
$return_arr
[
'status'
]
=
1
;
$return_arr
[
'driver_data'
]
=
$driver_data
;
}
echo
json_encode
(
$return_arr
);
exit
;
}
}
}
?>
?>
\ No newline at end of file
application/controllers/Ride.php
View file @
fb2d85e1
...
@@ -188,6 +188,15 @@ class Ride extends CI_Controller {
...
@@ -188,6 +188,15 @@ class Ride extends CI_Controller {
$data
[
'Attendant_Flag'
]
=
(
isset
(
$_POST
[
'attendant_flag'
]))
?
1
:
0
;
$data
[
'Attendant_Flag'
]
=
(
isset
(
$_POST
[
'attendant_flag'
]))
?
1
:
0
;
$data
[
'Wheelchair_Flag'
]
=
(
isset
(
$_POST
[
'wheelchair_flag'
]))
?
1
:
0
;
$data
[
'Wheelchair_Flag'
]
=
(
isset
(
$_POST
[
'wheelchair_flag'
]))
?
1
:
0
;
$data
[
'Crutches_/_Walker_/_Cane_Flag'
]
=
(
isset
(
$_POST
[
'c_w_c_flag'
]))
?
1
:
0
;
$data
[
'Crutches_/_Walker_/_Cane_Flag'
]
=
(
isset
(
$_POST
[
'c_w_c_flag'
]))
?
1
:
0
;
$data
[
'Members_Date_of_Birth'
]
=
$data
[
'Members_Phone_Number'
]
=
$data
[
'Members_Alt_Phone'
]
=
$data
[
'Trip_Number'
]
=
$data
[
'Pickup_Zip_Code'
]
=
$data
[
'Trip_Status'
]
=
$data
[
'Pickup_City'
]
=
$data
[
'Number_of_Car_Seats_Required'
]
=
$data
[
'Number_of_Additional_Passengers'
]
=
$data
[
'Copay'
]
=
$data
[
'Additional_Passengers_With_Appointments'
]
=
$data
[
'Trip_Mileage'
]
=
$data
[
'Delivery_City'
]
=
$data
[
'Pickup_State'
]
=
$data
[
'Delivery_Zip_Code'
]
=
$data
[
'Delivery_Name'
]
=
$data
[
'Trip_Status_Date'
]
=
$data
[
'Delivery_State'
]
=
$data
[
'Appointment_Day_of_Week'
]
=
$data
[
'Delivery_Phone_Number'
]
=
$data
[
'Special_Needs'
]
=
$data
[
'Inst_\/_Directions'
]
=
$data
[
'Return_Time'
]
=
$data
[
'Trip_Bid_Status'
]
=
$data
[
'Date_Trip_Bid_Status_Was_Changed'
]
=
$data
[
'Confirmation_Number'
]
=
''
;
$_POST
[
'patient_name'
]
=
$_POST
[
'first_name'
]
.
' '
.
$_POST
[
'last_name'
];
$_POST
[
'patient_name'
]
=
$_POST
[
'first_name'
]
.
' '
.
$_POST
[
'last_name'
];
$date_time
=
(
!
empty
(
$_POST
[
'appointment_date'
]))
?
$_POST
[
'appointment_date'
]
:
''
;
$date_time
=
(
!
empty
(
$_POST
[
'appointment_date'
]))
?
$_POST
[
'appointment_date'
]
:
''
;
...
@@ -214,16 +223,20 @@ class Ride extends CI_Controller {
...
@@ -214,16 +223,20 @@ class Ride extends CI_Controller {
}
}
function
view_rides
(){
function
view_rides
(){
$this
->
load
->
model
(
'Broker_model'
);
$template
[
'page'
]
=
'Ride/view_rides'
;
$template
[
'page'
]
=
'Ride/view_rides'
;
$template
[
'menu'
]
=
"Ride Management"
;
$template
[
'menu'
]
=
"Ride Management"
;
$template
[
'sub_menu'
]
=
"View Rides"
;
$template
[
'sub_menu'
]
=
"View Rides"
;
$template
[
'page_desc'
]
=
"View Rides Details"
;
$template
[
'page_desc'
]
=
"View Rides Details"
;
$template
[
'broker_id'
]
=
(
isset
(
$_POST
[
'broker_id'
]))
?
$_POST
[
'broker_id'
]
:
''
;
$template
[
'page_title'
]
=
"View Rides"
;
$template
[
'page_title'
]
=
"View Rides"
;
$company_id
=
(
$this
->
session
->
userdata
[
'user_type'
]
!=
1
)
?
$this
->
session
->
userdata
[
'id'
]
:
''
;
$company_id
=
(
$this
->
session
->
userdata
[
'user_type'
]
!=
1
)
?
$this
->
session
->
userdata
[
'id'
]
:
''
;
$template
[
'ride_data'
]
=
$this
->
Ride_model
->
getRideData
(
''
,
$company_id
);
$template
[
'ride_data'
]
=
$this
->
Ride_model
->
getRideData
(
''
,
$company_id
,
$template
[
'broker_id'
]);
$template
[
'broker_data'
]
=
$this
->
Broker_model
->
getBroker
();
$this
->
load
->
view
(
'template'
,
$template
);
$this
->
load
->
view
(
'template'
,
$template
);
}
}
...
@@ -285,7 +298,7 @@ class Ride extends CI_Controller {
...
@@ -285,7 +298,7 @@ class Ride extends CI_Controller {
$locData
=
file_get_contents
(
"https://maps.google.com/maps/api/geocode/json?address="
.
$locData
=
file_get_contents
(
"https://maps.google.com/maps/api/geocode/json?address="
.
urlencode
(
$ride_data
->
pickup_location
)
.
urlencode
(
$ride_data
->
pickup_location
)
.
"&sensor=false&
region=
$region
&
key=AIzaSyC9JX3BZZfx2S6GQieC_PqjuJdUbZ7_wyM"
);
"&sensor=false&key=AIzaSyC9JX3BZZfx2S6GQieC_PqjuJdUbZ7_wyM"
);
$loc_data
=
json_decode
(
$locData
);
$loc_data
=
json_decode
(
$locData
);
if
(
empty
(
$loc_data
)){
if
(
empty
(
$loc_data
)){
...
...
application/models/Driver_model.php
View file @
fb2d85e1
...
@@ -22,6 +22,7 @@ class Driver_model extends CI_Model {
...
@@ -22,6 +22,7 @@ class Driver_model extends CI_Model {
}
}
function
getDriver
(
$driver_id
=
''
){
function
getDriver
(
$driver_id
=
''
){
$cond
=
''
;
$user_id
=
$this
->
session
->
userdata
(
'id'
);
$user_id
=
$this
->
session
->
userdata
(
'id'
);
if
(
$this
->
session
->
userdata
(
'user_type'
)
!=
1
){
if
(
$this
->
session
->
userdata
(
'user_type'
)
!=
1
){
$cond
=
" AND CMP.company_id = '
$user_id
'"
;
$cond
=
" AND CMP.company_id = '
$user_id
'"
;
...
...
application/models/Ride_model.php
View file @
fb2d85e1
...
@@ -42,9 +42,11 @@ class Ride_model extends CI_Model {
...
@@ -42,9 +42,11 @@ class Ride_model extends CI_Model {
return
(
$status
)
?
1
:
0
;
return
(
$status
)
?
1
:
0
;
}
}
function
getRideData
(
$ride_id
=
''
,
$company_id
=
''
){
function
getRideData
(
$ride_id
=
''
,
$company_id
=
''
,
$broker_id
=
''
){
$cond
=
(
!
empty
(
$ride_id
))
?
" AND TD.transport_id = '
$ride_id
'"
:
""
;
$cond
=
(
!
empty
(
$ride_id
))
?
" AND TD.transport_id = '
$ride_id
'"
:
""
;
$cond
.=
(
$broker_id
!=
''
)
?
" AND TD.broker_id = '
$broker_id
'"
:
""
;
$cond
.=
(
!
empty
(
$company_id
))
?
" AND TD.company_id = '
$company_id
'"
:
""
;
$cond
.=
(
!
empty
(
$company_id
))
?
" AND TD.company_id = '
$company_id
'"
:
""
;
$sql
=
"SELECT TD.*,BK.broker_name,AR.reason,VH.vehicle_id,VH.vehicle_type,TT.trip_type,TS.trip_status
$sql
=
"SELECT TD.*,BK.broker_name,AR.reason,VH.vehicle_id,VH.vehicle_type,TT.trip_type,TS.trip_status
FROM transport_details AS TD
FROM transport_details AS TD
LEFT JOIN brokers AS BK ON (TD.broker_id = BK.broker_id)
LEFT JOIN brokers AS BK ON (TD.broker_id = BK.broker_id)
...
...
application/views/Driver/driver_list.php
View file @
fb2d85e1
<?php
$loc
=
''
;
$mapLocData
=
array
();
?>
<div
class=
"content-wrapper"
>
<div
class=
"content-wrapper"
>
<!-- Content Header (Page header) -->
<!-- Content Header (Page header) -->
<section
class=
"content-header"
>
<section
class=
"content-header"
>
...
@@ -24,12 +28,12 @@
...
@@ -24,12 +28,12 @@
<?php
}
?>
<?php
}
?>
</div>
</div>
<div
class=
"col-xs-12"
>
<div
class=
"col-xs-12"
>
<div
class=
"box"
>
<div
class=
"box
box-warning
"
>
<div
class=
"box-header
"
>
<div
"
class=
"col-12
"
>
<h3
class=
"box-title"
>
View User Details
</h3
>
<div
id=
"map-canvas"
style=
"width: 100%; height: 300px;"
></div
>
</div>
</div>
<div
class=
"box-body"
>
<div
class=
"box-body"
>
<table
id=
""
class=
"table table-bordered table-striped datatable "
>
<table
id=
"
driverTable
"
class=
"table table-bordered table-striped datatable "
>
<thead>
<thead>
<tr>
<tr>
<th
class=
"hidden"
>
ID
</th>
<th
class=
"hidden"
>
ID
</th>
...
@@ -54,8 +58,7 @@
...
@@ -54,8 +58,7 @@
<td
class=
"center"
>
<?=
$driver
->
company_name
?>
</th>
<td
class=
"center"
>
<?=
$driver
->
company_name
?>
</th>
<td
class=
"center"
>
<?=
(
$driver
->
status
==
'1'
)
?
'Active'
:
'Inactive'
?>
</td>
<td
class=
"center"
>
<?=
(
$driver
->
status
==
'1'
)
?
'Active'
:
'Inactive'
?>
</td>
<td
class=
"center"
>
<td
class=
"center"
>
<a
class=
"btn btn-sm btn-primary"
<a
class=
"btn btn-sm btn-primary"
id=
"viewDriver"
driver_id=
"
<?=
encode_param
(
$driver
->
driver_id
)
?>
"
>
href=
"
<?=
base_url
(
'Driver/view/'
.
encode_param
(
$driver
->
driver_id
))
?>
"
>
<i
class=
"fa fa-fw fa-edit"
></i>
View
<i
class=
"fa fa-fw fa-edit"
></i>
View
</a>
</a>
<a
class=
"btn btn-sm btn-danger"
<a
class=
"btn btn-sm btn-danger"
...
@@ -78,7 +81,14 @@
...
@@ -78,7 +81,14 @@
<?php
}
?>
<?php
}
?>
</td>
</td>
</tr>
</tr>
<?php
}
<?php
$drvLatLng
=
(
!
empty
(
$driver
->
lat_driver
)
&&
!
empty
(
$driver
->
lng_driver
))
?
$driver
->
lat_driver
.
','
.
$driver
->
lng_driver
:
''
;
$mapLocData
[]
=
array
(
'DisplayText'
=>
$driver
->
first_name
.
' '
.
$driver
->
last_name
,
'MarkerId'
=>
base_url
(
'assets/images/mapCarIconPref.png'
),
'LatitudeLongitude'
=>
$drvLatLng
,
'driver_id'
=>
encode_param
(
$driver
->
driver_id
));
}
}
?>
}
?>
</tbody>
</tbody>
</table>
</table>
...
@@ -86,3 +96,105 @@
...
@@ -86,3 +96,105 @@
</div>
</div>
</section>
</section>
</div>
</div>
<script
type=
"text/javascript"
>
var
map
,
geocoder
,
marker
,
people
=
new
Array
(),
latlng
,
infowindow
;
jQuery
(
document
).
ready
(
function
()
{
ViewCustInGoogleMap
();
});
function
ViewCustInGoogleMap
()
{
var
mapOptions
=
{
center
:
new
google
.
maps
.
LatLng
(
<?=
$drvLatLng
?>
),
zoom
:
7
,
mapTypeId
:
google
.
maps
.
MapTypeId
.
ROADMAP
};
map
=
new
google
.
maps
.
Map
(
document
.
getElementById
(
"map-canvas"
),
mapOptions
);
var
data
=
'
<?=
json_encode
(
$mapLocData
)
?>
'
;
people
=
JSON
.
parse
(
data
);
for
(
var
i
=
0
;
i
<
people
.
length
;
i
++
)
{
setMarker
(
people
[
i
]);
}
}
function
setMarker
(
people
)
{
geocoder
=
new
google
.
maps
.
Geocoder
();
infowindow
=
new
google
.
maps
.
InfoWindow
();
if
(
people
[
"LatitudeLongitude"
]
!=
''
)
{
var
latlngStr
=
people
[
"LatitudeLongitude"
].
split
(
","
);
var
lat
=
parseFloat
(
latlngStr
[
0
]);
var
lng
=
parseFloat
(
latlngStr
[
1
]);
latlng
=
new
google
.
maps
.
LatLng
(
lat
,
lng
);
marker
=
new
google
.
maps
.
Marker
({
position
:
latlng
,
map
:
map
,
draggable
:
false
,
html
:
people
[
"DisplayText"
],
icon
:
people
[
"MarkerId"
]
});
google
.
maps
.
event
.
addListener
(
marker
,
'click'
,
function
(
event
)
{
infowindow
.
setContent
(
this
.
html
);
infowindow
.
setPosition
(
event
.
latLng
);
infowindow
.
open
(
map
,
this
);
markCalBak
(
people
[
"driver_id"
]);
});
}
}
jQuery
(
'[id="viewDriver"]'
).
on
(
'click'
,
function
()
{
markCalBak
(
jQuery
(
this
).
attr
(
'driver_id'
));
});
function
markCalBak
(
driver_id
){
if
(
driver_id
==
''
||
driver_id
==
undefined
||
driver_id
==
'undefined'
||
driver_id
==
null
||
driver_id
==
'null'
){
return
true
;
}
modalTrigger
(
'Ride Details'
,
''
);
addModalLoader
();
jQuery
.
ajax
({
url
:
base_url
+
"Driver/getDriverData"
,
type
:
'POST'
,
data
:
{
'driver_id'
:
driver_id
},
success
:
function
(
resp
){
if
(
resp
==
''
||
resp
==
undefined
||
resp
==
'undefined'
||
resp
==
null
||
resp
==
'null'
){
remModalLoader
();
jQuery
(
'[id="modal_content"]'
).
html
(
'Something went wrong, please try again later...!'
);
return
false
;
}
var
resp_data
=
jQuery
.
parseJSON
(
resp
);
if
(
resp_data
[
'status'
]
==
'0'
){
remModalLoader
();
jQuery
(
'[id="modal_content"]'
).
html
(
'Something went wrong, please try again later...!'
);
return
false
;
}
var
driver_data
=
resp_data
[
'driver_data'
];
var
html
=
' <div class="col-xs-12"><div class="col-md-2"> <div class="form-group has-feedback"> <img id="driverProfileImg" src="'
+
base_url
+
driver_data
[
'profile_image'
]
+
'" height="100" width="100" /> </div> </div> <div class="col-md-6"> <div class="form-group has-feedback"> <span style="padding-right: 52px;">Name </span> : <label style="padding-left: 10px;" for="exampleInputEmail1">'
+
driver_data
[
'first_name'
]
+
' '
+
driver_data
[
'last_name'
]
+
'</label> </div> <div class="form-group has-feedback"> <span style="padding-right: 38px;">Email ID </span> : <label style="padding-left: 10px;" for="exampleInputEmail1"> '
+
driver_data
[
'email_id'
]
+
'</label> </div> <div class="form-group has-feedback"> <span style="padding-right: 49px;">Phone </span> : <label style="padding-left: 10px;" for="exampleInputEmail1">'
+
driver_data
[
'email_id'
]
+
' </label> </div> <div class="form-group has-feedback"> <span style="padding-right: 31px;">Company </span> : <label style="padding-left: 10px;" for="exampleInputEmail1"> '
+
driver_data
[
'company_name'
]
+
'</label> </div> <div class="form-group has-feedback"> <span style="padding-right: 45px;">Vechile </span> : <label style="padding-left: 10px;" for="exampleInputEmail1"> '
+
driver_data
[
'vehicle_type'
]
+
' </label> </div> </div> <div class="col-md-4"> <div class="form-group has-feedback"> <div class="col-md-12" style="height: 200px;"> <img id="driverLicenceImg" src="'
+
base_url
+
driver_data
[
'licence'
]
+
'" height="100%" /> </div> </div> </div> </div>'
;
remModalLoader
();
jQuery
(
'[id="modal_content"]'
).
html
(
html
);
jQuery
(
'[id="driverLicenceImg"]'
).
error
(
function
()
{
jQuery
(
'[id="driverLicenceImg"]'
).
attr
(
'src'
,
base_url
+
'assets/images/no_image.png'
);
});
jQuery
(
'[id="driverProfileImg"]'
).
error
(
function
()
{
jQuery
(
'[id="driverProfileImg"]'
).
attr
(
'src'
,
base_url
+
'assets/images/user_avatar.jpg'
);
});
},
fail
:
function
(
xhr
,
textStatus
,
errorThrown
){
remModalLoader
();
jQuery
(
'[id="modal_content"]'
).
html
(
'Something went wrong, please try again later...!'
);
},
error
:
function
(
ajaxContext
)
{
remModalLoader
();
jQuery
(
'[id="modal_content"]'
).
html
(
'Something went wrong, please try again later...!'
);
}
});
}
</script>
\ No newline at end of file
application/views/Driver/view.php
View file @
fb2d85e1
...
@@ -37,7 +37,7 @@
...
@@ -37,7 +37,7 @@
<img
src=
"
<?=
base_url
(
$driver_data
->
profile_image
)
?>
"
onerror=
"this.src='
<?=
base_url
(
"assets/images/user_avatar.jpg"
)
?>
';"
height=
"100"
width=
"100"
/>
<img
src=
"
<?=
base_url
(
$driver_data
->
profile_image
)
?>
"
onerror=
"this.src='
<?=
base_url
(
"assets/images/user_avatar.jpg"
)
?>
';"
height=
"100"
width=
"100"
/>
</div>
</div>
</div>
</div>
<div
class=
"col-md-
10
"
>
<div
class=
"col-md-
4
"
>
<div
class=
"form-group has-feedback"
>
<div
class=
"form-group has-feedback"
>
<span
style=
"padding-right: 52px;"
>
Name
</span>
:
<span
style=
"padding-right: 52px;"
>
Name
</span>
:
<label
style=
"padding-left: 10px;"
for=
"exampleInputEmail1"
>
<label
style=
"padding-left: 10px;"
for=
"exampleInputEmail1"
>
...
@@ -69,18 +69,18 @@
...
@@ -69,18 +69,18 @@
</label>
</label>
</div>
</div>
</div>
</div>
</div>
<div
class=
"col-md-5"
>
<div
class=
"col-md-12"
>
<div
class=
"form-group has-feedback"
>
<div
class=
"form-group has-feedback"
>
<br><br>
<div
class=
"col-md-5"
>
<div
class=
"col-md-2"
>
<span
style=
"padding-right: 40px;"
>
Licence Proof :
</span>
<span
style=
"padding-right: 40px;"
>
Licence Proof :
</span>
</div>
</div>
<div
class=
"col-md-
10 relative"
>
<div
class=
"col-md-
7"
style=
"height: 200px;"
>
<img
id=
"licence_img"
src=
"
<?=
base_url
(
$driver_data
->
licence
)
?>
"
onerror=
"this.src='
<?=
base_url
(
"assets/images/no_image.png"
)
?>
';"
height=
"
800"
width=
"800
"
/>
<img
id=
"licence_img"
src=
"
<?=
base_url
(
$driver_data
->
licence
)
?>
"
onerror=
"this.src='
<?=
base_url
(
"assets/images/no_image.png"
)
?>
';"
height=
"
100%
"
/>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</section>
</div>
</div>
application/views/Report/generate.php
View file @
fb2d85e1
...
@@ -267,25 +267,4 @@
...
@@ -267,25 +267,4 @@
</div>
</div>
</div>
</div>
</section>
</section>
</div>
</div>
\ No newline at end of file
<!-- REPORT LIST VIEW MODAL -->
<div
class=
"modal fade"
id=
"report_list_modal"
role=
"dialog"
>
<div
class=
"modal-dialog modal-lg"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
>
×
</button>
<h4
class=
"modal-title"
>
Modal Header
</h4>
</div>
<div
class=
"modal-body col-md-12"
id=
"report_list_content"
style=
"border-bottom:1px solid #e5e5e5;
"
>
<!-- REPORT LIST VIEW CONTENT -->
</div>
<div
class=
"modal-footer"
>
<div>
</div>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
Close
</button>
</div>
</div>
</div>
</div>
application/views/Ride/assign_driver.php
View file @
fb2d85e1
...
@@ -28,7 +28,7 @@
...
@@ -28,7 +28,7 @@
<?php
}
?>
<?php
}
?>
</div>
</div>
<div
class=
"col-xs-12"
>
<div
class=
"col-xs-12"
>
<div
class=
"box"
>
<div
class=
"box
box-warning
"
>
<div
class=
"box-header"
>
<div
class=
"box-header"
>
<h3
class=
"box-title"
>
Select Driver
</h3>
<h3
class=
"box-title"
>
Select Driver
</h3>
</div>
</div>
...
@@ -83,10 +83,13 @@
...
@@ -83,10 +83,13 @@
</td>
</td>
</tr>
</tr>
<?php
<?php
$drvLatLng
=
(
!
empty
(
$driver
[
'lat_driver'
])
&&
!
empty
(
$driver
[
'lng_driver'
]))
?
$driver
[
'lat_driver'
]
.
','
.
$driver
[
'lng_driver'
]
:
''
;
$markIcon
=
(
$prefDriver
==
$driver
[
'driver_id'
])
?
'mapCarIconPref'
:
'mapCarIcon'
;
$markIcon
=
(
$prefDriver
==
$driver
[
'driver_id'
])
?
'mapCarIconPref'
:
'mapCarIcon'
;
$mapLocData
[]
=
array
(
'DisplayText'
=>
$driver
[
'first_name'
]
.
' '
.
$driver
[
'last_name'
],
$mapLocData
[]
=
array
(
'DisplayText'
=>
$driver
[
'first_name'
]
.
' '
.
$driver
[
'last_name'
],
'MarkerId'
=>
base_url
(
'assets/images/'
.
$markIcon
.
'.png'
),
'MarkerId'
=>
base_url
(
'assets/images/'
.
$markIcon
.
'.png'
),
'LatitudeLongitude'
=>
$dr
iver
[
'lat_driver'
]
.
','
.
$driver
[
'lng_driver'
]
);
'LatitudeLongitude'
=>
$dr
vLatLng
);
}
}
}
?>
}
?>
</tbody>
</tbody>
...
@@ -99,80 +102,50 @@
...
@@ -99,80 +102,50 @@
</section>
</section>
</div>
</div>
<script
type=
"text/javascript"
>
<script
type=
"text/javascript"
>
var
map
;
var
map
,
geocoder
,
marker
,
people
=
new
Array
(),
latlng
,
infowindow
;
var
geocoder
;
var
marker
;
var
people
=
new
Array
();
var
latlng
;
var
infowindow
;
$
(
document
).
ready
(
function
()
{
jQuery
(
document
).
ready
(
function
()
{
ViewCustInGoogleMap
();
ViewCustInGoogleMap
();
});
});
function
ViewCustInGoogleMap
()
{
function
ViewCustInGoogleMap
()
{
var
mapOptions
=
{
center
:
new
google
.
maps
.
LatLng
(
<?=
$loc
?>
),
zoom
:
10
,
mapTypeId
:
google
.
maps
.
MapTypeId
.
ROADMAP
};
map
=
new
google
.
maps
.
Map
(
document
.
getElementById
(
"map-canvas"
),
mapOptions
);
var
mapOptions
=
{
var
data
=
'
<?=
json_encode
(
$mapLocData
)
?>
'
;
center
:
new
google
.
maps
.
LatLng
(
<?=
$loc
?>
),
people
=
JSON
.
parse
(
data
);
zoom
:
10
,
mapTypeId
:
google
.
maps
.
MapTypeId
.
ROADMAP
};
map
=
new
google
.
maps
.
Map
(
document
.
getElementById
(
"map-canvas"
),
mapOptions
);
var
data
=
'
<?=
json_encode
(
$mapLocData
)
?>
'
;
people
=
JSON
.
parse
(
data
);
for
(
var
i
=
0
;
i
<
people
.
length
;
i
++
)
{
setMarker
(
people
[
i
]);
}
for
(
var
i
=
0
;
i
<
people
.
length
;
i
++
)
{
setMarker
(
people
[
i
]);
}
}
}
function
setMarker
(
people
)
{
function
setMarker
(
people
)
{
geocoder
=
new
google
.
maps
.
Geocoder
();
geocoder
=
new
google
.
maps
.
Geocoder
();
infowindow
=
new
google
.
maps
.
InfoWindow
();
infowindow
=
new
google
.
maps
.
InfoWindow
();
if
((
people
[
"LatitudeLongitude"
]
==
null
)
||
(
people
[
"LatitudeLongitude"
]
==
'null'
)
||
(
people
[
"LatitudeLongitude"
]
==
''
))
{
if
(
people
[
"LatitudeLongitude"
]
!=
''
)
{
geocoder
.
geocode
({
'address'
:
people
[
"Address"
]
},
function
(
results
,
status
)
{
var
latlngStr
=
people
[
"LatitudeLongitude"
].
split
(
","
);
if
(
status
==
google
.
maps
.
GeocoderStatus
.
OK
)
{
var
lat
=
parseFloat
(
latlngStr
[
0
]);
latlng
=
new
google
.
maps
.
LatLng
(
results
[
0
].
geometry
.
location
.
lat
(),
results
[
0
].
geometry
.
location
.
lng
());
var
lng
=
parseFloat
(
latlngStr
[
1
]);
marker
=
new
google
.
maps
.
Marker
({
latlng
=
new
google
.
maps
.
LatLng
(
lat
,
lng
);
position
:
latlng
,
marker
=
new
google
.
maps
.
Marker
({
map
:
map
,
position
:
latlng
,
draggable
:
false
,
map
:
map
,
html
:
people
[
"DisplayText"
],
draggable
:
false
,
icon
:
people
[
"MarkerId"
]
html
:
people
[
"DisplayText"
],
});
icon
:
people
[
"MarkerId"
]
//marker.setPosition(latlng);
});
//map.setCenter(latlng);
google
.
maps
.
event
.
addListener
(
marker
,
'click'
,
function
(
event
)
{
google
.
maps
.
event
.
addListener
(
marker
,
'click'
,
function
(
event
)
{
infowindow
.
setContent
(
this
.
html
);
infowindow
.
setContent
(
this
.
html
);
infowindow
.
setPosition
(
event
.
latLng
);
infowindow
.
setPosition
(
event
.
latLng
);
infowindow
.
open
(
map
,
this
);
infowindow
.
open
(
map
,
this
);
});
});
}
}
});
}
else
{
var
latlngStr
=
people
[
"LatitudeLongitude"
].
split
(
","
);
var
lat
=
parseFloat
(
latlngStr
[
0
]);
var
lng
=
parseFloat
(
latlngStr
[
1
]);
latlng
=
new
google
.
maps
.
LatLng
(
lat
,
lng
);
marker
=
new
google
.
maps
.
Marker
({
position
:
latlng
,
map
:
map
,
draggable
:
false
,
// cant drag it
html
:
people
[
"DisplayText"
],
// Content display on marker click
icon
:
people
[
"MarkerId"
]
// Give ur own image
});
//marker.setPosition(latlng);
//map.setCenter(latlng);
google
.
maps
.
event
.
addListener
(
marker
,
'click'
,
function
(
event
)
{
infowindow
.
setContent
(
this
.
html
);
infowindow
.
setPosition
(
event
.
latLng
);
infowindow
.
open
(
map
,
this
);
});
}
}
}
</script>
</script>
\ No newline at end of file
application/views/Ride/view_rides.php
View file @
fb2d85e1
<?php
$headerArr
=
array
(
"Medicaid_Number"
,
"Members_Last_Name"
,
"Members_First_Name"
,
"Members_Date_of_Birth"
,
"Members_Age"
,
"Members_Phone_Number"
,
"Members_Alt_Phone"
,
"Trip_Number"
,
"Appointment_Date"
,
"Appointment_Day_of_Week"
,
"Appointment_Time"
,
"Trip_Reason_Code"
,
"Trip_Status"
,
"Vehicle_Type"
,
"Trip_Type"
,
"Wheelchair_Flag"
,
"Crutches_\/_Walker_\/_Cane_Flag"
,
"Number_of_Car_Seats_Required"
,
"Pregnant_Flag"
,
"Number_of_Additional_Passengers"
,
"Additional_Passengers_With_Appointments"
,
"Trip_Mileage"
,
"Trip_Cost"
,
"Pickup_Address"
,
"Pickup_City"
,
"Pickup_State"
,
"Pickup_Zip_Code"
,
"Delivery_Name"
,
"Delivery_Address"
,
"Delivery_City"
,
"Delivery_State"
,
"Delivery_Zip_Code"
,
"Delivery_Phone_Number"
,
"Special_Needs"
,
"Inst_\/_Directions"
,
"Return_Time"
,
"Attendant_Flag"
,
"Trip_Bid_Status"
,
"Date_Trip_Bid_Status_Was_Changed"
,
"Confirmation_Number"
,
"Copay"
,
"Trip_Status_Date"
);
?>
<div
class=
"content-wrapper"
>
<div
class=
"content-wrapper"
>
<!-- Content Header (Page header) -->
<!-- Content Header (Page header) -->
<section
class=
"content-header"
>
<section
class=
"content-header"
>
...
@@ -23,78 +27,102 @@
...
@@ -23,78 +27,102 @@
</div>
</div>
<?php
}
?>
<?php
}
?>
</div>
</div>
<div
class=
"col-md-12"
>
<div
class=
"box box-warning"
>
<div
class=
"box-header with-border"
>
<h3
class=
"box-title"
>
Ride Management
</h3>
</div>
<div
class=
"box-body"
>
<form
role=
"form"
id=
"getBrokerRides"
action=
"
<?=
base_url
(
'Ride/view_rides'
)
?>
"
method=
"post"
class=
"validate"
data-parsley-validate=
""
enctype=
"multipart/form-data"
>
<div
class=
"col-md-12"
>
<div
class=
"form-group"
>
<label>
Select Broker
</label>
<select
name=
"broker_id"
class=
"form-control"
onchange=
"getBrokerRides()"
>
<option
selected
value=
""
>
All Rides
</option>
<?php
if
(
!
empty
(
$broker_data
)){
foreach
(
$broker_data
as
$broker
)
{
$chkFlg
=
(
$broker_id
==
$broker
->
broker_id
)
?
'selected'
:
''
;
echo
'<option value="'
.
$broker
->
broker_id
.
'" '
.
$chkFlg
.
'>
'
.
$broker
->
broker_name
.
'</option>'
;
}
}
?>
<option
value=
"0"
<?=
(
$broker_id
==
0
)
?
'selected'
:
''
?>
>
Phone Bookings
</option>
</select>
</div>
</div>
</form>
</div>
</div>
</div>
<div
class=
"col-xs-12"
>
<div
class=
"col-xs-12"
>
<div
class=
"box"
>
<div
class=
"box"
>
<div
class=
"box-header"
>
<div
class=
"box-body"
>
<h3
class=
"box-title"
>
View User Details
</h3>
<table
class=
"table table-bordered table-striped datatable "
>
</div>
<thead>
<div
class=
"box-body"
>
<tr>
<table
id=
""
class=
"table table-bordered table-striped datatable "
>
<th
class=
"hidden"
>
ID
</th>
<thead>
<th
width=
"100px"
></th>
<tr>
<?php
<th
class=
"hidden"
>
ID
</th>
foreach
(
$headerArr
AS
$head
)
{
<th
width=
"150px;"
>
Patient Name
</th>
echo
'<th width="100%;">'
.
str_replace
(
'_'
,
' '
,
$head
)
.
'</th> '
;
<th
width=
"50px;"
>
Age
</th>
<th
width=
"100px;"
>
Phone
</th>
<th
width=
"150px;"
>
Appointment Date
</th>
<th
width=
"150px;"
>
Status
</th>
<th
width=
"150px;"
>
Data Source
</th>
<th
width=
"320px;"
>
Action
</th>
</tr>
</thead>
<tbody>
<?php
if
(
!
empty
(
$ride_data
)){
foreach
(
$ride_data
as
$ride
)
{
?>
<tr>
<th
class=
"hidden"
>
<?=
$ride
->
transport_id
?>
</th>
<td
class=
"center"
>
<?=
$ride
->
patient_name
?>
</th>
<td
class=
"center"
>
<?=
$ride
->
age
?>
</th>
<td
class=
"center"
>
<?=
$ride
->
phone
?>
</th>
<td
class=
"center"
>
<?=
date
(
'd-M-Y G:i'
,
$ride
->
appointment_time
)
?>
</th>
<td
class=
"center"
>
<?php
if
(
strtotime
(
date
(
'd-M-Y G:i'
))
>
$ride
->
appointment_time
&&
(
$ride
->
status
==
1
||
$ride
->
status
==
0
)){
echo
'Ride Expired'
;
}
else
{
switch
(
$ride
->
status
){
case
0
:
echo
'Inactive'
;
break
;
case
1
:
echo
'Yet to assign Driver'
;
break
;
case
3
:
echo
'Waiting For Driver Approval'
;
break
;
case
4
:
echo
'Driver Accepted'
;
break
;
case
5
:
echo
'Processing'
;
break
;
case
6
:
echo
'Ride Completed'
;
break
;
case
7
:
echo
'Driver Canceled'
;
break
;
case
8
:
echo
'Driver Manually Assigned'
;
break
;
}
}
}
?>
?>
<th
width=
"150px;"
>
Data Source
</th>
</td>
</tr>
<td
class=
"center"
>
<?=
(
!
empty
(
$ride
->
broker_name
)
?
$ride
->
broker_name
:
'Phone Booking'
)
?>
</th>
</thead>
<td
class=
"center"
>
<tbody>
<a
class=
"btn btn-sm btn-primary"
<?php
href=
"
<?=
base_url
(
'Ride/view/'
.
encode_param
(
$ride
->
transport_id
))
?>
"
>
$report_data
=
array
();
<i
class=
"fa fa-fw fa-edit"
></i>
View
if
(
!
empty
(
$ride_data
)){
</a>
foreach
(
$ride_data
as
$ride
)
{
<a
class=
"btn btn-sm btn-danger"
$json_ride
=
json_decode
(
$ride
->
data
,
true
);
href=
"
<?=
base_url
(
"Ride/changeStatus/"
.
encode_param
(
$ride
->
transport_id
))
.
"/2"
?>
"
if
(
empty
(
$json_ride
)){
onClick=
"return doconfirm()"
>
continue
;
<i
class=
"fa fa-fw fa-trash"
></i>
Delete
}
</a>
?>
<?php
if
(
$this
->
session
->
userdata
[
'user_type'
]
!=
1
&&
(
$ride
->
status
==
1
||
$ride
->
status
==
7
)
&&
strtotime
(
date
(
'd-M-Y G:i'
))
<
$ride
->
appointment_time
){
?>
<tr>
<a
class=
"btn btn-sm btn-primary"
<th
class=
"hidden"
>
<?=
$ride
->
transport_id
?>
</th>
href=
"
<?=
base_url
(
'Ride/assign_driver/'
.
encode_param
(
$ride
->
transport_id
))
?>
"
>
<th
class=
"center"
>
<i
class=
"fa fa-fw fa-edit"
></i>
Assign Driver
<a
id=
"viewRideDetails"
key=
"
<?=
$ride
->
transport_id
?>
"
class=
"cpoint"
>
</a>
<i
class=
"fa fa-fw fa-eye"
></i>
<?php
}
?>
</a>
</td>
<a
href=
"
<?=
base_url
(
"Ride/changeStatus/"
.
encode_param
(
$ride
->
transport_id
))
.
"/2"
?>
"
</tr>
onClick=
"return doconfirm()"
><i
class=
"fa fa-fw fa-trash"
style=
"color:#dd4b39;"
></i></a>
<?php
}
</th>
}
?>
</tbody>
<?php
</table>
foreach
(
$json_ride
AS
$key
=>
$data
){
</div>
switch
(
$key
){
case
'Wheelchair_Flag'
:
$json_ride
[
$key
]
=
(
$data
==
1
)
?
'YES'
:
'NO'
;
break
;
case
'Attendant_Flag'
:
$json_ride
[
$key
]
=
(
$data
==
1
)
?
'YES'
:
'NO'
;
break
;
case
'Pregnant_Flag'
:
$json_ride
[
$key
]
=
(
$data
==
1
)
?
'YES'
:
'NO'
;
break
;
case
'Members_Date_of_Birth'
:
$json_ride
[
$key
]
=
(
$data
==
1
)
?
'YES'
:
'NO'
;
break
;
case
'Crutches_/_Walker_/_Cane_Flag'
:
$json_ride
[
$key
]
=
(
$data
==
1
)
?
'YES'
:
'NO'
;
break
;
case
'Trip_Reason_Code'
:
$json_ride
[
$key
]
=
$ride
->
reason
;
break
;
case
'Vehicle_Type'
:
$json_ride
[
$key
]
=
$ride
->
vehicle_type
;
break
;
case
'Trip_Type'
:
$json_ride
[
$key
]
=
$ride
->
trip_type
;
break
;
case
'Trip_Status'
:
$json_ride
[
$key
]
=
$ride
->
trip_status
;
break
;
}
echo
'<td class="center">'
.
$data
.
'</td>'
;
$report_data
[
$ride
->
transport_id
]
=
$json_ride
;
}
?>
<th
class=
"center"
>
<?=
(
!
empty
(
$ride
->
broker_name
)
?
$ride
->
broker_name
:
'Phone Booking'
)
?>
</th>
</tr>
<?php
}
}
?>
</tbody>
</table>
</div>
</div>
</div>
</div>
</section>
</div>
</div>
</section>
<script
type=
"text/javascript"
>
</div>
report_data
=
<?=
json_encode
(
$report_data
);
?>
;
\ No newline at end of file
</script>
application/views/Settings/viewSettings.php
View file @
fb2d85e1
...
@@ -39,7 +39,7 @@
...
@@ -39,7 +39,7 @@
<input
type=
"text"
name=
"title_short"
class=
"form-control required"
placeholder=
"Enter Site Title"
value=
"
<?=
$data
[
'title_short'
]
?>
"
>
<input
type=
"text"
name=
"title_short"
class=
"form-control required"
placeholder=
"Enter Site Title"
value=
"
<?=
$data
[
'title_short'
]
?>
"
>
</div>
</div>
<div
class=
"form-group col-xs-5"
>
<div
class=
"form-group col-xs-5"
>
<label
for=
"exampleInputEmail1"
>
Site Logo
</label>
<label>
Site Logo
</label>
<div
class=
"col-md-12"
>
<div
class=
"col-md-12"
>
<div
class=
"col-md-3"
>
<div
class=
"col-md-3"
>
<img
id=
"site_logo"
src=
"
<?=
base_url
(
$data
[
'site_logo'
])
?>
"
onerror=
"this.src='
<?=
base_url
(
"assets/images/no_image.png"
)
?>
';"
height=
"75"
width=
"75"
>
<img
id=
"site_logo"
src=
"
<?=
base_url
(
$data
[
'site_logo'
])
?>
"
onerror=
"this.src='
<?=
base_url
(
"assets/images/no_image.png"
)
?>
';"
height=
"75"
width=
"75"
>
...
@@ -59,16 +59,17 @@
...
@@ -59,16 +59,17 @@
<label>
Currency
</label>
<label>
Currency
</label>
<input
type=
"text"
name=
"currency"
class=
"form-control required"
placeholder=
"Enter SMTP Password"
value=
"
<?=
$data
[
'currency'
]
?>
"
>
<input
type=
"text"
name=
"currency"
class=
"form-control required"
placeholder=
"Enter SMTP Password"
value=
"
<?=
$data
[
'currency'
]
?>
"
>
</div>
</div>
<div
class=
"form-group col-xs-5"
>
<div
class=
"form-group col-xs-5"
>
<label
for=
"exampleInputEmail1"
>
Fav Icon
</label>
<label>
Favicon Icon
</label>
<div
class=
"col-md-12"
>
<div
class=
"col-md-12"
>
<div
class=
"col-md-3"
>
<div
class=
"col-md-3"
>
<img
id=
"fav_icon"
src=
"
<?=
base_url
(
$data
[
'fav_icon'
])
?>
"
onerror=
"this.src='
<?=
base_url
(
"assets/images/no_image.png"
)
?>
';"
height=
"75"
width=
"75"
/>
<img
id=
"fav_icon_image"
src=
"
<?=
base_url
(
$data
[
'fav_icon'
])
?>
"
onerror=
"this.src='
<?=
base_url
(
"assets/images/no_image.png"
)
?>
';"
height=
"75"
width=
"75"
>
</div>
</div>
<div
class=
"col-md-9"
style=
"padding-top: 25px;"
>
<div
class=
"col-md-9"
style=
"padding-top: 25px;"
>
<input
name=
"fav_icon"
type=
"file"
accept=
"image/*"
onchange=
"setImg(this,'fav_icon');"
/>
<input
name=
"fav_icon"
type=
"file"
accept=
"image/*"
onchange=
"setImg(this,'fav_icon_image');"
/>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div
class=
"row"
>
<div
class=
"row"
>
...
...
application/views/Templates/footer-script.php
View file @
fb2d85e1
...
@@ -16,33 +16,42 @@
...
@@ -16,33 +16,42 @@
<script
src=
"https://cdn.ckeditor.com/4.5.7/standard/ckeditor.js"
></script>
<script
src=
"https://cdn.ckeditor.com/4.5.7/standard/ckeditor.js"
></script>
<script
src=
"
<?php
echo
base_url
();
?>
assets/js/bootstrap-datepicker.js"
></script>
<script
src=
"
<?php
echo
base_url
();
?>
assets/js/bootstrap-datepicker.js"
></script>
<script
type=
"text/javascript"
src=
"
<?=
base_url
(
'assets/js/clockpicker.js'
)
?>
"
></script>
<script
type=
"text/javascript"
src=
"
<?=
base_url
(
'assets/js/clockpicker.js'
)
?>
"
></script>
<script>
<script>
$
(
function
()
{
jQuery
(
'.clockpicker'
).
clockpicker
();
$
(
'.datatable'
).
DataTable
({
"ordering"
:
$
(
this
).
data
(
"ordering"
),
"order"
:
[[
0
,
"asc"
]]
});
});
function
doconfirm
()
function
doconfirm
(){
{
job
=
confirm
(
"Are you sure to delete permanently?"
);
job
=
confirm
(
"Are you sure to delete permanently?"
);
if
(
job
!=
true
)
if
(
job
!=
true
)
return
false
;
return
false
;
}
}
jQuery
(
'.clockpicker'
).
clockpicker
();
<?php
</script>
$ci
=
&
get_instance
();
$controllerName
=
$ci
->
uri
->
segment
(
1
);
$actionName
=
$ci
->
uri
->
segment
(
2
);
$page
=
$controllerName
.
'-'
.
$actionName
;
<?php
switch
(
$page
)
{
$ci
=
&
get_instance
();
case
'Ride-view_rides'
:
?>
$controllerName
=
$ci
->
uri
->
segment
(
1
);
jQuery
(
function
()
{
$actionName
=
$ci
->
uri
->
segment
(
2
);
jQuery
(
'.datatable'
).
DataTable
({
$page
=
$controllerName
.
'-'
.
$actionName
;
scrollY
:
"300px"
,
scrollX
:
true
,
switch
(
$page
)
{
scrollCollapse
:
true
,
case
'Ride-import_ride'
:
paging
:
false
,
?><?php
fixedColumns
:
{
break
;
heightMatch
:
'none'
}
}
?>
});
\ No newline at end of file
});
<?php
break
;
?>
default
:
?
>
jQuery
(
function
()
{
jQuery
(
'.datatable'
).
DataTable
({
"ordering"
:
jQuery
(
this
).
data
(
"ordering"
),
"order"
:
[[
0
,
"asc"
]]
});
});
<?php
}
?>
</script>
\ No newline at end of file
application/views/Templates/footer.php
View file @
fb2d85e1
<footer
class=
"main-footer"
>
<!-- POP-UP VIEW MODAL END -->
<div
class=
"pull-right hidden-xs"
>
<div
class=
"modal fade"
id=
"popup_modal"
role=
"dialog"
>
<b>
Version
</b>
1.0
<div
class=
"modal-dialog modal-lg"
>
</div>
<div
class=
"modal-content"
>
<strong>
Copyright
©
2015-2016
<a
href=
"#"
>
Techware Solution
</a>
.
</strong>
All rights reserved.
<div
class=
"modal-header"
>
</footer>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
>
×
</button>
<h4
class=
"modal-title"
id=
"modal_header"
></h4>
</div>
<div
class=
"modal-body col-md-12"
id=
"modal_content"
style=
"border-bottom:1px solid #e5e5e5;"
>
<!-- POP-UP VIEW MODAL CONTENT -->
</div>
<div
class=
"modal-footer"
>
<div>
</div>
<button
type=
"button"
class=
"btn btn-default"
data-dismiss=
"modal"
>
Close
</button>
</div>
</div>
</div>
</div>
<!-- POP-UP VIEW MODAL END -->
<footer
class=
"main-footer"
>
<div
class=
"pull-right hidden-xs"
>
<b>
Version
</b>
1.0
</div>
<strong>
Copyright
©
2015-2016
<a
href=
"#"
>
Techware Solution
</a>
.
</strong>
All rights reserved.
</footer>
\ No newline at end of file
application/views/Templates/header-script.php
View file @
fb2d85e1
...
@@ -2,6 +2,7 @@
...
@@ -2,6 +2,7 @@
<meta
charset=
"utf-8"
>
<meta
charset=
"utf-8"
>
<meta
http-equiv=
"X-UA-Compatible"
content=
"IE=edge"
>
<meta
http-equiv=
"X-UA-Compatible"
content=
"IE=edge"
>
<title>
<?=
$this
->
session
->
userdata
[
'settings'
][
'title_short'
]
?>
</title>
<title>
<?=
$this
->
session
->
userdata
[
'settings'
][
'title_short'
]
?>
</title>
<link
href=
"
<?=
base_url
(
$this
->
session
->
userdata
[
'settings'
][
'fav_icon'
])
?>
"
type=
"image/x-icon"
/>
<meta
content=
"width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
name=
"viewport"
>
<meta
content=
"width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
name=
"viewport"
>
<link
rel=
"stylesheet"
href=
"
<?php
echo
base_url
();
?>
assets/css/bootstrap.min.css"
>
<link
rel=
"stylesheet"
href=
"
<?php
echo
base_url
();
?>
assets/css/bootstrap.min.css"
>
...
@@ -19,4 +20,8 @@
...
@@ -19,4 +20,8 @@
<link
rel=
"stylesheet"
type=
"text/css"
href=
"
<?=
base_url
(
'assets/css/clockpicker.css'
)
?>
"
>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"
<?=
base_url
(
'assets/css/clockpicker.css'
)
?>
"
>
<script
src=
"
<?php
echo
base_url
();
?>
assets/js/jQuery-2.1.4.min.js"
></script>
<script
src=
"
<?php
echo
base_url
();
?>
assets/js/jQuery-2.1.4.min.js"
></script>
<script
type=
"text/javascript"
>
report_data
=
[];
</script>
</head>
</head>
application/views/Templates/left-menu.php
View file @
fb2d85e1
...
@@ -125,15 +125,15 @@
...
@@ -125,15 +125,15 @@
</a>
</a>
<ul
class=
"treeview-menu"
>
<ul
class=
"treeview-menu"
>
<li>
<li>
<a
href=
"
<?=
base_url
(
'Ride/
import_ride
'
)
?>
"
>
<a
href=
"
<?=
base_url
(
'Ride/
view_rides
'
)
?>
"
>
<i
class=
"fa fa-circle-o text-aqua"
></i>
<i
class=
"fa fa-circle-o text-aqua"
></i>
Import
Rides
View
Rides
</a>
</a>
</li>
</li>
<li>
<li>
<a
href=
"
<?=
base_url
(
'Ride/
view_rides
'
)
?>
"
>
<a
href=
"
<?=
base_url
(
'Ride/
import_ride
'
)
?>
"
>
<i
class=
"fa fa-circle-o text-aqua"
></i>
<i
class=
"fa fa-circle-o text-aqua"
></i>
View
Rides
Import
Rides
</a>
</a>
</li>
</li>
</ul>
</ul>
...
@@ -146,10 +146,12 @@
...
@@ -146,10 +146,12 @@
<i
class=
"fa fa-wrench"
aria-hidden=
"true"
>
<i
class=
"fa fa-wrench"
aria-hidden=
"true"
>
</i><span>
Report Generation
</span></a>
</i><span>
Report Generation
</span></a>
</li>
</li>
<?php
if
(
$this
->
session
->
userdata
[
'user_type'
]
==
1
){
?>
<li><a
href=
"
<?=
base_url
(
'Settings'
)
?>
"
>
<li><a
href=
"
<?=
base_url
(
'Settings'
)
?>
"
>
<i
class=
"fa fa-wrench"
aria-hidden=
"true"
>
<i
class=
"fa fa-wrench"
aria-hidden=
"true"
>
</i><span>
Settings
</span></a>
</i><span>
Settings
</span></a>
</li>
</li>
<?php
}
?>
</ul>
</ul>
</section>
</section>
<!-- /.sidebar -->
<!-- /.sidebar -->
...
...
assets/css/custom-style.css
View file @
fb2d85e1
...
@@ -220,4 +220,26 @@
...
@@ -220,4 +220,26 @@
.hide
{
.hide
{
display
:
none
!important
;
display
:
none
!important
;
}
.loader
{
position
:
absolute
;
top
:
0px
;
right
:
0px
;
bottom
:
0px
;
left
:
0px
;
text-align
:
center
;
background-image
:
url(../images/loader.gif)
;
background-size
:
12%
;
background-position
:
center
;
background-repeat
:
no-repeat
;
background-color
:
rgba
(
211
,
211
,
211
,
0.5
);
}
.height_200
{
height
:
200px
!important
;
}
.cpoint
{
cursor
:
pointer
!important
;
}
}
\ No newline at end of file
assets/images/loader.gif
0 → 100644
View file @
fb2d85e1
60.6 KB
assets/js/nemt_custom.js
View file @
fb2d85e1
...
@@ -48,7 +48,6 @@ jQuery('[name="fieldType"]').click(function(){
...
@@ -48,7 +48,6 @@ jQuery('[name="fieldType"]').click(function(){
}
}
});
});
report_data
=
[];
jQuery
(
'[id="rGenerate"]'
).
click
(
function
(){
jQuery
(
'[id="rGenerate"]'
).
click
(
function
(){
event
.
preventDefault
();
event
.
preventDefault
();
var
fields
=
''
,
var
fields
=
''
,
...
@@ -127,16 +126,27 @@ function slideTo(id){
...
@@ -127,16 +126,27 @@ function slideTo(id){
}
}
jQuery
(
'#report_table tbody'
).
on
(
'click'
,
'a'
,
function
()
{
jQuery
(
'#report_table tbody'
).
on
(
'click'
,
'a'
,
function
()
{
var
body_html
=
rowHtml
=
''
,
var
thisObj
=
jQuery
(
this
),
thisObj
=
jQuery
(
this
),
key
=
thisObj
.
attr
(
'key'
);
key
=
thisObj
.
attr
(
'key'
);
viewOrderDetails
(
key
);
});
jQuery
(
'[id="viewRideDetails"]'
).
click
(
function
(){
console
.
log
(
'sdrfg'
);
var
thisObj
=
jQuery
(
this
),
key
=
thisObj
.
attr
(
'key'
);
viewOrderDetails
(
key
);
});
function
viewOrderDetails
(
key
){
var
body_html
=
rowHtml
=
''
;
var
colCount
=
1
;
var
colCount
=
1
;
body_html
=
'<div class="col-xs-12">'
;
body_html
=
'<div class="col-xs-12">'
;
jQuery
.
each
(
report_data
[
key
],
function
(
field
,
value
)
{
jQuery
.
each
(
report_data
[
key
],
function
(
field
,
value
)
{
value
=
(
value
==
null
||
value
==
'null'
||
value
==
undefined
||
value
==
'undefined'
)?
'--'
:
value
;
value
=
(
value
==
null
||
value
==
'null'
||
value
==
undefined
||
value
==
'undefined'
)?
'--'
:
value
;
rowHtml
+=
'<div class="col-xs-6"><div class="col-xs-12">'
+
rowHtml
+=
'<div class="col-xs-6"><div class="col-xs-12">'
+
'<div class="col-xs-6">'
+
field
.
replace
(
'_'
,
' '
)
+
'</div>'
+
'<div class="col-xs-6">'
+
field
.
replace
(
/_/g
,
' '
)
+
'</div>'
+
'<div class="col-xs-1">:</div>'
+
'<div class="col-xs-1">:</div>'
+
'<div class="col-xs-5">'
+
value
+
'</div>'
+
'<div class="col-xs-5">'
+
value
+
'</div>'
+
'</div></div>'
;
'</div></div>'
;
...
@@ -149,10 +159,34 @@ jQuery('#report_table tbody').on('click','a',function() {
...
@@ -149,10 +159,34 @@ jQuery('#report_table tbody').on('click','a',function() {
}
}
});
});
body_html
+=
'</div>'
;
body_html
+=
'</div>'
;
jQuery
(
'[id="report_list_content"]'
).
html
(
body_html
);
modalTrigger
(
'Ride Details'
,
body_html
);
jQuery
(
'[id="report_list_modal"]'
).
modal
(
'show'
);
}
});
function
getBrokerRides
(){
jQuery
(
'[id="getBrokerRides"]'
).
submit
();
}
function
getCmpyPayDetls
(){
function
getCmpyPayDetls
(){
jQuery
(
'[id="cmpyPayDetlsForm"]'
).
submit
();
jQuery
(
'[id="cmpyPayDetlsForm"]'
).
submit
();
}
function
modalTrigger
(
header
,
body_html
){
jQuery
(
'[id="modal_content"]'
).
html
(
body_html
);
jQuery
(
'[id="modal_header"]'
).
html
(
header
);
jQuery
(
'[id="popup_modal"]'
).
modal
(
'show'
);
}
function
modalHide
(){
jQuery
(
'[id="popup_modal"]'
).
modal
(
'hide'
);
}
function
addModalLoader
(){
jQuery
(
"[id='modal_content']"
).
addClass
(
'relative height_200'
);
jQuery
(
"[id='modal_content']"
).
prepend
(
"<div id='modal_loader_body' class='loader'></div>"
);
}
function
remModalLoader
(){
jQuery
(
"[id='modal_loader_body']"
).
remove
();
jQuery
(
"[id='modal_content']"
).
removeClass
(
'relative height_200'
);
}
}
\ No newline at end of file
index.php
View file @
fb2d85e1
...
@@ -56,7 +56,7 @@ ob_start();
...
@@ -56,7 +56,7 @@ ob_start();
* NOTE: If you change these, also change the error_reporting() code below
* NOTE: If you change these, also change the error_reporting() code below
*/
*/
//define('ENVIRONMENT', isset($_SERVER['CI_ENV']) ? $_SERVER['CI_ENV'] : 'development');
//define('ENVIRONMENT', isset($_SERVER['CI_ENV']) ? $_SERVER['CI_ENV'] : 'development');
define
(
'ENVIRONMENT'
,
'
production
'
);
define
(
'ENVIRONMENT'
,
'
development
'
);
/*
/*
*---------------------------------------------------------------
*---------------------------------------------------------------
...
@@ -76,7 +76,7 @@ switch (ENVIRONMENT)
...
@@ -76,7 +76,7 @@ switch (ENVIRONMENT)
case
'testing'
:
case
'testing'
:
case
'production'
:
case
'production'
:
error_reporting
(
-
1
);
error_reporting
(
-
1
);
ini_set
(
'display_errors'
,
1
);
ini_set
(
'display_errors'
,
0
);
if
(
version_compare
(
PHP_VERSION
,
'5.3'
,
'>='
))
if
(
version_compare
(
PHP_VERSION
,
'5.3'
,
'>='
))
{
{
error_reporting
(
E_ALL
&
~
E_NOTICE
&
~
E_DEPRECATED
&
~
E_STRICT
&
~
E_USER_NOTICE
&
~
E_USER_DEPRECATED
);
error_reporting
(
E_ALL
&
~
E_NOTICE
&
~
E_DEPRECATED
&
~
E_STRICT
&
~
E_USER_NOTICE
&
~
E_USER_DEPRECATED
);
...
...
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