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
9b3305fc
Commit
9b3305fc
authored
Jul 30, 2018
by
Anju M S
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change booking
parent
66868e4b
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
80 additions
and
21 deletions
+80
-21
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.
application/controllers/Searchdoctor.php
View file @
9b3305fc
...
@@ -668,6 +668,31 @@ class Searchdoctor extends CI_Controller {
...
@@ -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*/
/*FUNCTION : MARK BOOKING FOR A DOCTOR - DOCTOR SEARCH*/
...
...
application/models/Search_doctor_model.php
View file @
9b3305fc
...
@@ -4,6 +4,25 @@
...
@@ -4,6 +4,25 @@
function
__construct
()
{
function
__construct
()
{
parent
::
__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
)
public
function
doctor_search
(
$post_data
)
{
{
...
...
application/views/search_doctor_confirm_booking.php
View file @
9b3305fc
...
@@ -58,6 +58,7 @@ if($this->session->userdata('language') == 'en'){
...
@@ -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-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=
"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"
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-status"
id=
"promocode_status"
value=
"0"
>
<input
type=
"hidden"
name=
"promocode-name"
id=
"promocode_name"
value=
"0"
>
<input
type=
"hidden"
name=
"promocode-name"
id=
"promocode_name"
value=
"0"
>
...
@@ -299,8 +300,10 @@ if($this->session->userdata('language') == 'en'){
...
@@ -299,8 +300,10 @@ if($this->session->userdata('language') == 'en'){
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
>
×
</button>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
>
×
</button>
<div
class=
"ip_custom_modal_content"
>
<div
class=
"ip_custom_modal_content"
>
<div
class=
"ip_main_tab_content textCenter"
>
<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_btn1"
id=
"money_cash"
value=
"1"
>
<?php
load_language
(
'money'
);
?>
</button>
<button
class=
"ip_modal_gen_btn ip_gen_btn2"
id=
"credit_card_cash"
>
<?php
load_language
(
'credit_card'
);
?>
</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>
</div>
</div>
</div>
...
...
assets/js/custom.js
View file @
9b3305fc
...
@@ -1700,7 +1700,8 @@ $('#confirm_booking_continue_btn').click(function()
...
@@ -1700,7 +1700,8 @@ $('#confirm_booking_continue_btn').click(function()
{
{
$
(
'#book-date-show'
).
html
(
'On '
+
items
.
booking_date
+
' '
);
$
(
'#book-date-show'
).
html
(
'On '
+
items
.
booking_date
+
' '
);
$
(
'#book-time-show'
).
html
(
' at '
+
items
.
booking_slot
);
$
(
'#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');
// $('.confirm-tab-1').removeClass('active');
// $('#btnTrigger-payment').click();
// $('#btnTrigger-payment').click();
// $('.confirm-tab-3').addClass('active');
// $('.confirm-tab-3').addClass('active');
...
@@ -1734,21 +1735,21 @@ $('#confirm_booking_continue_btn').click(function()
...
@@ -1734,21 +1735,21 @@ $('#confirm_booking_continue_btn').click(function()
})
})
$
(
'#money_cash'
).
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'
);
$
(
'#select_cash_mode'
).
modal
(
'hide'
);
// data = $('#confirm_book_form').serializeArray();
// data.push({'name':'offset','value':JSON.stringify(offset)})
var
data
=
{
'book_id'
:
entered_book_id
,
'payment_status'
:
'1'
,
'payment_type'
:
'1'
};
// var result = post_ajax(base_url+'Searchdoctor/markbooking',data);
var
result
=
post_ajax
(
base_url
+
'Searchdoctor/markpayment'
,
data
);
// var items = JSON.parse(result);
var
items
=
JSON
.
parse
(
result
);
// var booking_id = items.booking_id;
console
.
log
(
items
);
// //console.log(items);
if
(
items
==
'true'
){
// var payment_required = items.payment_required;
$
(
'.confirm-tab-1'
).
removeClass
(
'active'
);
// if(payment_required) //Free Consultation -> goto Confirmation page
$
(
'#btnTrigger-confirmation'
).
click
();
// {
$
(
'.confirm-tab-4'
).
addClass
(
'active'
);
//$('#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'
);
// }
// }
// else //Paid Consulation -> goto Payment Page
// else //Paid Consulation -> goto Payment Page
// {
// {
...
@@ -1760,10 +1761,19 @@ $('#money_cash').click(function(){
...
@@ -1760,10 +1761,19 @@ $('#money_cash').click(function(){
})
})
$
(
'#credit_card_cash'
).
click
(
function
(){
$
(
'#credit_card_cash'
).
click
(
function
(){
$
(
'#select_cash_mode'
).
modal
(
'hide'
);
$
(
'.confirm-tab-1'
).
removeClass
(
'active'
);
var
entered_book_id
=
document
.
getElementById
(
"book_status"
).
getAttribute
(
"book-id"
);
$
(
'#btnTrigger-payment'
).
click
();
console
.
log
(
entered_book_id
);
$
(
'.confirm-tab-3'
).
addClass
(
'active'
);
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
()
$
(
'#enter_waiting_list_btn'
).
click
(
function
()
...
@@ -1808,6 +1818,7 @@ $('#enter_waiting_list_btn').click(function()
...
@@ -1808,6 +1818,7 @@ $('#enter_waiting_list_btn').click(function()
else
//Paid Consulation -> goto Payment Page
else
//Paid Consulation -> goto Payment Page
{
{
$
(
'#book_status'
).
attr
(
'book-id'
,
booking_id
);
$
(
'#book_status'
).
attr
(
'book-id'
,
booking_id
);
$
(
'#entered_book_id'
).
val
(
booking_id
);
$
(
'.confirm-tab-1'
).
removeClass
(
'active'
);
$
(
'.confirm-tab-1'
).
removeClass
(
'active'
);
$
(
'#btnTrigger-payment'
).
click
();
$
(
'#btnTrigger-payment'
).
click
();
$
(
'.confirm-tab-3'
).
addClass
(
'active'
);
$
(
'.confirm-tab-3'
).
addClass
(
'active'
);
...
@@ -1876,6 +1887,7 @@ $('#confirm-book-login_submit').click(function()
...
@@ -1876,6 +1887,7 @@ $('#confirm-book-login_submit').click(function()
else
//Paid Consulation -> goto Payment Page
else
//Paid Consulation -> goto Payment Page
{
{
$
(
'#book_status'
).
attr
(
'book-id'
,
booking_id
);
$
(
'#book_status'
).
attr
(
'book-id'
,
booking_id
);
$
(
'#entered_book_id'
).
val
(
booking_id
);
$
(
'.confirm-tab-2'
).
removeClass
(
'active'
);
$
(
'.confirm-tab-2'
).
removeClass
(
'active'
);
$
(
'#btnTrigger-payment'
).
click
();
$
(
'#btnTrigger-payment'
).
click
();
$
(
'.confirm-tab-3'
).
addClass
(
'active'
);
$
(
'.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