Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
TimeOutAdmin
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
TimeOut
TimeOutAdmin
Commits
b7dba332
Commit
b7dba332
authored
Jan 31, 2020
by
Tobin
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
https://gitlab.techware.co.in/timeout/timeOut
into tobin
parents
4053179f
72eb29a6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
746 additions
and
8 deletions
+746
-8
OrganizerServices.php
application/controllers/OrganizerServices.php
+287
-1
Organizer_model.php
application/models/Organizer_model.php
+0
-0
Validation_organizer_model.php
application/models/Validation_organizer_model.php
+449
-1
Webservice_model.php
application/models/Webservice_model.php
+10
-6
No files found.
application/controllers/OrganizerServices.php
View file @
b7dba332
...
@@ -28,7 +28,7 @@ class OrganizerServices extends CI_Controller {
...
@@ -28,7 +28,7 @@ class OrganizerServices extends CI_Controller {
$this
->
load
->
model
(
'Validation_organizer_model'
);
$this
->
load
->
model
(
'Validation_organizer_model'
);
$method
=
$this
->
router
->
fetch_method
();
$method
=
$this
->
router
->
fetch_method
();
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
if
(
$method
==
'addEvent'
)
{
if
(
$method
==
'addEvent'
||
$method
==
'addCategory'
||
$method
==
'addCity'
||
$method
==
'editOrganizerCityDetails'
||
$method
==
'editOrganizerCategoryDetails'
||
$method
==
"AddVenue"
||
$method
==
'editOrganizerVenueDetails'
)
{
$data
=
$_POST
;
$data
=
$_POST
;
}
}
if
(
isset
(
apache_request_headers
()[
'Auth'
]))
{
if
(
isset
(
apache_request_headers
()[
'Auth'
]))
{
...
@@ -372,6 +372,292 @@ class OrganizerServices extends CI_Controller {
...
@@ -372,6 +372,292 @@ class OrganizerServices extends CI_Controller {
}
}
}
}
public
function
getOrganizerTagDetails
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
getOrganizerTagDetails
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
response
(
$res
[
'data'
]);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
addTag
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
addTag
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
editOrganizerTagDetails
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
editOrganizerTagDetails
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
deleteOrganizerTag
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
changeOrganizerTagStatus
(
$data
,
2
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
deActivateOrganizerTag
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
changeOrganizerTagStatus
(
$data
,
0
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
getOrganizerHostCategoryList
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
getOrganizerHostCategoryList
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
response
(
$res
[
'data'
]);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
addHostCategory
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
addHostCategory
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
deleteHostCategory
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
changeOrganizerHostStatus
(
$data
,
2
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
deActivateHostCategory
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
changeOrganizerHostStatus
(
$data
,
0
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
getOrganizerCityList
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
getOrganizerCityList
(
$data
,
0
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
response
(
$res
[
'data'
]);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
getCityDetails
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
getCityDetails
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
response
(
$res
[
'data'
]);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
editOrganizerCityDetails
(){
$data
=
$_POST
;
$res
=
$this
->
Organizer_model
->
editOrganizerCityDetails
(
$data
,
0
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
addCity
(){
$data
=
$_POST
;
$res
=
$this
->
Organizer_model
->
addCity
(
$data
,
0
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
deleteOrganizerCity
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
changeOrganizerCityStatus
(
$data
,
2
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
deActivateCity
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
changeOrganizerCityStatus
(
$data
,
0
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
getOrganizerCategoryList
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
getOrganizerCategoryList
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
response
(
$res
[
'data'
]);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
getOrganizerCategoryDetails
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
getOrganizerCategoryDetail
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
response
(
$res
[
'data'
]);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
addCategory
(){
$data
=
$_POST
;
$res
=
$this
->
Organizer_model
->
addCategory
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
editOrganizerCategoryDetails
(){
$data
=
$_POST
;
$res
=
$this
->
Organizer_model
->
editOrganizerCategoryDetails
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
getOrganizerCategoryOrderList
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
getOrganizerCategoryOrderList
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
response
(
$res
[
'data'
]);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
reorderOrganizerCategoryList
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
reorderOrganizerCategoryList
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
deleteOrganizerCategory
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
changeOrganizerCategoryStatus
(
$data
,
2
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
deActivateCategory
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
changeOrganizerCategoryStatus
(
$data
,
0
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
AddVenue
(){
$data
=
$_POST
;
$res
=
$this
->
Organizer_model
->
AddVenue
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
deleteOrganizerVenue
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
changeOrganizerVenueStatus
(
$data
,
2
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
deActivateOrganizerVenue
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
changeOrganizerVenueStatus
(
$data
,
0
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
successResponse
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
getOrganizerVenueList
(){
$data
=
(
array
)
json_decode
(
file_get_contents
(
'php://input'
));
$res
=
$this
->
Organizer_model
->
getVenueList
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
response
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
public
function
editOrganizerVenueDetails
(){
$data
=
$_POST
;
$res
=
$this
->
Organizer_model
->
editOrganizerVenueDetails
(
$data
);
if
(
$res
[
'status'
]
!=
0
){
$this
->
response
(
$res
);
}
else
{
$this
->
errorResponse
(
$res
[
'code'
],
$res
[
'message'
]);
}
}
/*================ END : Organizer API ================*/
/*================ END : Organizer API ================*/
}
}
?>
?>
application/models/Organizer_model.php
View file @
b7dba332
This diff is collapsed.
Click to expand it.
application/models/Validation_organizer_model.php
View file @
b7dba332
This diff is collapsed.
Click to expand it.
application/models/Webservice_model.php
View file @
b7dba332
...
@@ -1158,6 +1158,7 @@ class Webservice_model extends CI_Model {
...
@@ -1158,6 +1158,7 @@ class Webservice_model extends CI_Model {
$rs
=
$this
->
db
->
insert
(
'booking'
,
$post_data
);
$rs
=
$this
->
db
->
insert
(
'booking'
,
$post_data
);
$id
=
$this
->
db
->
insert_id
();
$id
=
$this
->
db
->
insert_id
();
$this
->
db
->
insert
(
'orders'
,
array
(
'booking_id'
=>
$post_data
[
'bookId'
],
'order_type'
=>
'1'
,
'created_date'
=>
date
(
'Y-m-d h:i:s'
),
'customer_id'
=>
$user_id
));
if
(
$id
){
if
(
$id
){
if
(
!
empty
(
$promocodeData
)){
if
(
!
empty
(
$promocodeData
)){
...
@@ -1491,7 +1492,7 @@ class Webservice_model extends CI_Model {
...
@@ -1491,7 +1492,7 @@ class Webservice_model extends CI_Model {
$countryData
=
$this
->
getCountryData
(
$user_id
);
$countryData
=
$this
->
getCountryData
(
$user_id
);
$lang
=
$countryData
[
'language_code'
];
$lang
=
$countryData
[
'language_code'
];
$sql
=
"SELECT booking.bookId AS booking_id,event_date_time.date,
$sql
=
"SELECT booking.bookId AS booking_id,event_date_time.date,
translator_event
.event_name,booking.qrcode AS event_image,
TRS_EVT
.event_name,booking.qrcode AS event_image,
venue.location,event_date_time.time,booking.event_id,
venue.location,event_date_time.time,booking.event_id,
booking.no_of_ticket AS ticket_count,events.has_payment,
booking.no_of_ticket AS ticket_count,events.has_payment,
booking.status AS booking_status,transaction.status AS transaction_status
booking.status AS booking_status,transaction.status AS transaction_status
...
@@ -1499,13 +1500,16 @@ class Webservice_model extends CI_Model {
...
@@ -1499,13 +1500,16 @@ class Webservice_model extends CI_Model {
INNER JOIN events ON booking.event_id = events.event_id
INNER JOIN events ON booking.event_id = events.event_id
INNER JOIN event_date_time ON booking.event_date_id = event_date_time.id
INNER JOIN event_date_time ON booking.event_date_id = event_date_time.id
INNER JOIN venue ON venue.id = events.venue_id
INNER JOIN venue ON venue.id = events.venue_id
INNER JOIN translator_event
ON translator_event
.event_id=events.event_id
INNER JOIN translator_event
AS TRS_EVT ON TRS_EVT
.event_id=events.event_id
LEFT JOIN transaction ON transaction.booking_id=booking.bookId
LEFT JOIN transaction ON transaction.booking_id=booking.bookId
WHERE (translator_event.language_code='
$lang
' OR translator_event.language_code='EN').
WHERE (TRS_EVT.language_code='
$lang
' OR TRS_EVT.language_code='EN') AND
AND booking.bookId='
$booking_id
' AND events.has_payment != '1'
booking.bookId='
$booking_id
'"
;
AND transaction.status = '1'"
;
return
$this
->
db
->
query
(
$sql
)
->
row_array
();
if
(
empty
(
$evtData
=
$this
->
db
->
query
(
$sql
)
->
row_array
())
||
(
$evtData
[
'has_payment'
]
==
'1'
&&
$evtData
[
'transaction_status'
]
!=
'1'
)){
return
;
}
return
$evtData
;
}
}
function
getHotelData
(
$booking_id
=
''
,
$user_id
=
''
){
function
getHotelData
(
$booking_id
=
''
,
$user_id
=
''
){
...
...
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