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
f7ae63e3
Commit
f7ae63e3
authored
Jul 30, 2018
by
Jansa Jose
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'anju' into jansa
parents
e2df105e
7d5751d6
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
104 additions
and
22 deletions
+104
-22
Webservice_model.php
admin/application/models/Webservice_model.php
+24
-1
Searchdoctor.php
application/controllers/Searchdoctor.php
+25
-0
Search_doctor_model.php
application/models/Search_doctor_model.php
+19
-0
search_doctor_confirm_booking.php
application/views/search_doctor_confirm_booking.php
+5
-2
custom.js
assets/js/custom.js
+31
-19
No files found.
admin/application/models/Webservice_model.php
View file @
f7ae63e3
...
...
@@ -567,7 +567,29 @@ class Webservice_model extends CI_Model {
$this
->
db
->
join
(
'tbl_specialization'
,
'tbl_specialization.id = tbl_doctors. specialization'
);
$query_userdata
=
$this
->
db
->
get_where
(
"tbl_doctors"
,
array
(
"email"
=>
$data
));
if
(
$query_userdata
->
num_rows
()
>
0
){
$return_array
=
array
(
'status'
=>
'success'
,
'userdata'
=>
$query_userdata
->
row_array
());
$doc_result
=
$query_userdata
->
row_array
();
$this
->
db
->
select
(
"CAST(AES_DECRYPT(`tbl_doctors`.`dob`,'Ptf/PWNWrULQT72syxfaaBRTS9JbiKrj9dfuVEvT3rA') as CHAR) as dob_new"
);
$this
->
db
->
where
(
'id'
,
$doc_result
[
'id'
]);
$querydate
=
$this
->
db
->
get
(
'tbl_doctors'
)
->
row
();
$query
=
$doc_result
;
$query
[
'dob'
]
=
$query_date
->
dob_new
;
$query
[
'cep'
]
=
decrypt_data
(
$query
[
'zip_code'
]);
$query
[
'complement'
]
=
decrypt_data
(
$query
[
'landmark'
]);
$query
[
'about'
]
=
decrypt_data
(
$query
[
'biodata'
]);
$query
[
'gender'
]
=
decrypt_data
(
$query
[
'gender'
]);
$query
[
'name'
]
=
decrypt_data
(
$query
[
'name'
]);
$query
[
'price'
]
=
decrypt_data
(
$query
[
'price'
]);
$query
[
'domiciliary_status'
]
=
decrypt_data
(
$query
[
'domiciliary_status'
]);
$query
[
'rg'
]
=
decrypt_data
(
$query
[
'rg'
]);
$query
[
'crm'
]
=
decrypt_data
(
$query
[
'crm'
]);
$query
[
'street_address'
]
=
decrypt_data
(
$query
[
'street_address'
]);
$query
[
'locality'
]
=
decrypt_data
(
$query
[
'locality'
]);
$query
[
'number'
]
=
decrypt_data
(
$query
[
'number'
]);
$return_array
=
array
(
'status'
=>
'success'
,
'userdata'
=>
$query
);
}
else
{
$return_array
=
array
(
'status'
=>
'fail'
);
...
...
@@ -1696,6 +1718,7 @@ class Webservice_model extends CI_Model {
if
(
count
(
$query
)
>
0
){
foreach
(
$query
as
$key
=>
$value
)
{
$query
[
$key
]
->
patient_name
=
decrypt_data
(
$value
->
patient_name
);
//$query[$key]->doctor_name = decrypt_data($value->doctor_name);
}
return
$query
;
}
else
{
...
...
application/controllers/Searchdoctor.php
View file @
f7ae63e3
...
...
@@ -668,6 +668,31 @@ class Searchdoctor extends CI_Controller {
}
public
function
markpayment
(){
$data
=
$_POST
;
$result
=
$this
->
Search_doctor_model
->
markpayment
(
$data
);
//print_r($check_result);die();
print
json_encode
(
$result
);
}
public
function
markpayment_viacredit
(){
$data
=
$_POST
;
$result
=
$this
->
Search_doctor_model
->
markpayment_viacredit
(
$data
);
//print_r($check_result);die();
print
json_encode
(
$result
);
}
/*FUNCTION : MARK BOOKING FOR A DOCTOR - DOCTOR SEARCH*/
...
...
application/models/Search_doctor_model.php
View file @
f7ae63e3
...
...
@@ -4,6 +4,25 @@
function
__construct
()
{
parent
::
__construct
();
}
public
function
markpayment
(
$data
){
$id
=
$data
[
'book_id'
];
$datas
=
array
(
'payment_status'
=>
$data
[
'payment_status'
],
'payment_type'
=>
$data
[
'payment_type'
]);
$this
->
db
->
update
(
'tbl_booking'
,
$datas
,
array
(
'id'
=>
$id
));
return
true
;
}
public
function
markpayment_viacredit
(
$data
){
$id
=
$data
[
'book_id'
];
$datas
=
array
(
'payment_status'
=>
$data
[
'payment_status'
],
'payment_type'
=>
$data
[
'payment_type'
]);
$this
->
db
->
update
(
'tbl_booking'
,
$datas
,
array
(
'id'
=>
$id
));
return
true
;
}
public
function
doctor_search
(
$post_data
)
{
...
...
application/views/search_doctor_confirm_booking.php
View file @
f7ae63e3
...
...
@@ -58,6 +58,7 @@ if($this->session->userdata('language') == 'en'){
<input
type=
"hidden"
name=
"confirm-book-clinic"
id=
"confirm_book_clinic"
value=
"
<?php
echo
$doctor_data
[
'clinic_id'
]
?>
"
>
<input
type=
"hidden"
name=
"confirm-book-doctor"
id=
"confirm_book_doctor"
value=
"
<?php
echo
$doctor_data
[
'doctorid'
]
?>
"
>
<input
type=
"hidden"
name=
"book-status"
id=
"book_status"
value=
"1"
drprice=
"
<?php
echo
$doctor_data
[
'dr_price'
];
?>
"
>
<input
type=
"hidden"
id=
"entered_book_id"
value=
""
>
<input
type=
"hidden"
name=
"promocode-status"
id=
"promocode_status"
value=
"0"
>
<input
type=
"hidden"
name=
"promocode-name"
id=
"promocode_name"
value=
"0"
>
...
...
@@ -299,8 +300,10 @@ if($this->session->userdata('language') == 'en'){
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
>
×
</button>
<div
class=
"ip_custom_modal_content"
>
<div
class=
"ip_main_tab_content textCenter"
>
<button
class=
"ip_modal_gen_btn ip_gen_btn1"
id=
"money_cash"
>
<?php
load_language
(
'money'
);
?>
</button>
<button
class=
"ip_modal_gen_btn ip_gen_btn2"
id=
"credit_card_cash"
>
<?php
load_language
(
'credit_card'
);
?>
</button>
<button
class=
"ip_modal_gen_btn ip_gen_btn1"
id=
"money_cash"
value=
"1"
>
<?php
load_language
(
'money'
);
?>
</button>
<input
type=
"hidden"
value=
"1"
name=
"bkid"
>
<button
class=
"ip_modal_gen_btn ip_gen_btn2"
id=
"credit_card_cash"
value=
"2"
>
<?php
load_language
(
'credit_card'
);
?>
</button>
<input
type=
"hidden"
value=
"2"
name=
"bkidd"
>
</div>
</div>
</div>
...
...
assets/js/custom.js
View file @
f7ae63e3
...
...
@@ -1700,7 +1700,8 @@ $('#confirm_booking_continue_btn').click(function()
{
$
(
'#book-date-show'
).
html
(
'On '
+
items
.
booking_date
+
' '
);
$
(
'#book-time-show'
).
html
(
' at '
+
items
.
booking_slot
);
$
(
'#book_status'
).
attr
(
'book-id'
,
booking_id
);
$
(
'#book_status'
).
attr
(
'book-id'
,
booking_id
);
// $('.confirm-tab-1').removeClass('active');
// $('#btnTrigger-payment').click();
// $('.confirm-tab-3').addClass('active');
...
...
@@ -1734,21 +1735,21 @@ $('#confirm_booking_continue_btn').click(function()
})
$
(
'#money_cash'
).
click
(
function
(){
var
entered_book_id
=
document
.
getElementById
(
"book_status"
).
getAttribute
(
"book-id"
);
console
.
log
(
entered_book_id
);
$
(
'#select_cash_mode'
).
modal
(
'hide'
);
// data = $('#confirm_book_form').serializeArray();
// data.push({'name':'offset','value':JSON.stringify(offset)})
// var result = post_ajax(base_url+'Searchdoctor/markbooking',data);
// var items = JSON.parse(result);
// var booking_id = items.booking_id;
// //console.log(items);
// var payment_required = items.payment_required;
// if(payment_required) //Free Consultation -> goto Confirmation page
// {
//$('#book-date-show').html('On '+items.booking_date+' ');
//$('#book-time-show').html(' at '+items.booking_slot);
$
(
'.confirm-tab-1'
).
removeClass
(
'active'
);
$
(
'#btnTrigger-confirmation'
).
click
();
$
(
'.confirm-tab-4'
).
addClass
(
'active'
);
var
data
=
{
'book_id'
:
entered_book_id
,
'payment_status'
:
'1'
,
'payment_type'
:
'1'
};
var
result
=
post_ajax
(
base_url
+
'Searchdoctor/markpayment'
,
data
);
var
items
=
JSON
.
parse
(
result
);
console
.
log
(
items
);
if
(
items
==
'true'
){
$
(
'.confirm-tab-1'
).
removeClass
(
'active'
);
$
(
'#btnTrigger-confirmation'
).
click
();
$
(
'.confirm-tab-4'
).
addClass
(
'active'
);
}
// }
// else //Paid Consulation -> goto Payment Page
// {
...
...
@@ -1760,10 +1761,19 @@ $('#money_cash').click(function(){
})
$
(
'#credit_card_cash'
).
click
(
function
(){
$
(
'#select_cash_mode'
).
modal
(
'hide'
);
$
(
'.confirm-tab-1'
).
removeClass
(
'active'
);
$
(
'#btnTrigger-payment'
).
click
();
$
(
'.confirm-tab-3'
).
addClass
(
'active'
);
var
entered_book_id
=
document
.
getElementById
(
"book_status"
).
getAttribute
(
"book-id"
);
console
.
log
(
entered_book_id
);
var
data
=
{
'book_id'
:
entered_book_id
,
'payment_status'
:
'0'
,
'payment_type'
:
'2'
};
var
result
=
post_ajax
(
base_url
+
'Searchdoctor/markpayment_viacredit'
,
data
);
var
items
=
JSON
.
parse
(
result
);
console
.
log
(
items
);
if
(
items
==
'true'
){
$
(
'#select_cash_mode'
).
modal
(
'hide'
);
$
(
'.confirm-tab-1'
).
removeClass
(
'active'
);
$
(
'#btnTrigger-payment'
).
click
();
$
(
'.confirm-tab-3'
).
addClass
(
'active'
);
}
})
$
(
'#enter_waiting_list_btn'
).
click
(
function
()
...
...
@@ -1808,6 +1818,7 @@ $('#enter_waiting_list_btn').click(function()
else
//Paid Consulation -> goto Payment Page
{
$
(
'#book_status'
).
attr
(
'book-id'
,
booking_id
);
$
(
'#entered_book_id'
).
val
(
booking_id
);
$
(
'.confirm-tab-1'
).
removeClass
(
'active'
);
$
(
'#btnTrigger-payment'
).
click
();
$
(
'.confirm-tab-3'
).
addClass
(
'active'
);
...
...
@@ -1876,6 +1887,7 @@ $('#confirm-book-login_submit').click(function()
else
//Paid Consulation -> goto Payment Page
{
$
(
'#book_status'
).
attr
(
'book-id'
,
booking_id
);
$
(
'#entered_book_id'
).
val
(
booking_id
);
$
(
'.confirm-tab-2'
).
removeClass
(
'active'
);
$
(
'#btnTrigger-payment'
).
click
();
$
(
'.confirm-tab-3'
).
addClass
(
'active'
);
...
...
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