Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
I
IPok_Web
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
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
IPok
IPok_Web
Commits
6d32c6e5
Commit
6d32c6e5
authored
Aug 09, 2018
by
Jansa Jose
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
price
parent
35bf4aed
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
Webservice_model.php
admin/application/models/Webservice_model.php
+4
-2
No files found.
admin/application/models/Webservice_model.php
View file @
6d32c6e5
...
...
@@ -2258,8 +2258,8 @@ CASE when tbl_doctors.gender='0' then 'MALE' when tbl_doctors.gender='1' then 'F
tbl_doctors.id as doctor_id,
tbl_doctors.online_status as status,tbl_clinic_doctors.clinic_id,
tbl_doctors.profile_pic as doctor_image,
tbl_specialization.specialization_name as doctor_speciality,
ROUND(( 6371 * acos( cos( radians(
{
$lat
}
) ) * cos( radians( `tbl_clinic`.`location_lattitude` ) ) * cos( radians( `tbl_clinic`.`location_longitude` ) - radians(
{
$lng
}
) ) + sin( radians(
{
$lat
}
) ) * sin( radians( `tbl_clinic`.`location_lattitude` ) ) ) )) AS distance"
);
tbl_specialization.specialization_name as doctor_speciality,
case when tbl_clinic_doctors.clinic_id != '0' then
ROUND(( 6371 * acos( cos( radians(
{
$lat
}
) ) * cos( radians( `tbl_clinic`.`location_lattitude` ) ) * cos( radians( `tbl_clinic`.`location_longitude` ) - radians(
{
$lng
}
) ) + sin( radians(
{
$lat
}
) ) * sin( radians( `tbl_clinic`.`location_lattitude` ) ) ) ))
else ROUND(( 6371 * acos( cos( radians(
{
$lat
}
) ) * cos( radians( `tbl_doctors`.`default_latitude` ) ) * cos( radians( `tbl_doctors`.`default_longitude` ) - radians(
{
$lng
}
) ) + sin( radians(
{
$lat
}
) ) * sin( radians( `tbl_doctors`.`default_latitude` ) ) ) )) end
AS distance"
);
$this
->
db
->
from
(
"tbl_doctors"
);
$this
->
db
->
join
(
'tbl_clinic_doctors'
,
'tbl_doctors.id = tbl_clinic_doctors.doctor_id'
,
'INNER'
);
...
...
@@ -2268,6 +2268,8 @@ CASE when tbl_doctors.gender='0' then 'MALE' when tbl_doctors.gender='1' then 'F
$this
->
db
->
where
(
'tbl_doctors.id'
,
$value
);
$res
=
$this
->
db
->
get
()
->
result
();
foreach
(
$res
as
$key
=>
$values
)
{
$new_fee
=
$values
->
fee
-
(
$values
->
fee
*
$query
->
amount
/
100
);
$values
->
fee
=
$new_fee
;
$new_array
[]
=
$values
;
}
$result
=
array
(
"status"
=>
"success"
,
"data"
=>
$new_array
);
...
...
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