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
96248100
Commit
96248100
authored
Mar 06, 2020
by
Tobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
contact changes
parent
d3c94f1c
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
10 deletions
+13
-10
Event.php
application/controllers/Event.php
+8
-8
Api_model.php
application/models/Api_model.php
+1
-1
Webservice_model.php
application/models/Webservice_model.php
+4
-1
No files found.
application/controllers/Event.php
View file @
96248100
...
...
@@ -150,24 +150,24 @@ class Event extends CI_Controller {
$event_id
=
$this
->
Event_model
->
createEvent
(
$eventData
,
$languageArr
);
if
(
!
empty
(
$event_id
)){
$
insertEventDat
e
=
array
();
$
evtDateTim
e
=
array
();
if
(
isset
(
$_POST
[
'schedule_type'
])
&&
$_POST
[
'schedule_type'
]
==
0
){
$date
=
strtotime
(
$_POST
[
'event_start_date'
]);
$date
=
date
(
'Y-m-d'
,
$date
);
foreach
(
$_POST
[
'event_time'
]
AS
$time
)
{
$
insertEventDat
e
[]
=
array
(
'event_id'
=>
$event_id
,
'date'
=>
$date
,
'time'
=>
$time
);
$
evtDateTim
e
[]
=
array
(
'event_id'
=>
$event_id
,
'date'
=>
$date
,
'time'
=>
$time
);
}
}
else
{
$cdate
=
strtotime
(
$_POST
[
'event_start_date'
]);
while
(
$cdate
<=
strtotime
(
$_POST
[
'event_end_date'
]))
{
$cdate
=
date
(
'Y-m-d'
,
$cdate
);
foreach
(
$_POST
[
'event_time'
]
AS
$time
)
{
$
insertEventDate
[]
=
array
(
'event_id'
=>
$event_id
,
'date'
=>
$cdate
,
'time'
=>
$time
);
$
evtDateTime
[]
=
array
(
'event_id'
=>
$event_id
,
'date'
=>
$cdate
,
'time'
=>
$time
,
'status'
=>
1
);
}
$cdate
=
strtotime
(
$cdate
.
' +1 day'
);
}
}
$status
=
$this
->
Event_model
->
createEventDateTime
(
$
insertEventDat
e
);
$status
=
$this
->
Event_model
->
createEventDateTime
(
$
evtDateTim
e
);
$insertTag
=
array
();
foreach
(
$_POST
[
'tags'
]
AS
$tag
)
{
...
...
@@ -332,24 +332,24 @@ class Event extends CI_Controller {
$status
=
$this
->
Event_model
->
updateEvent
(
$event_id
,
$eventData
,
$languageArr
);
if
(
$status
){
$
insertEventDat
e
=
array
();
$
evtDateTim
e
=
array
();
if
(
isset
(
$_POST
[
'schedule_type'
])
&&
$_POST
[
'schedule_type'
]
==
0
){
$date
=
strtotime
(
$_POST
[
'event_start_date'
]);
$date
=
date
(
'Y-m-d'
,
$date
);
foreach
(
$_POST
[
'event_time'
]
AS
$time
)
{
$
insertEventDat
e
[]
=
array
(
'event_id'
=>
$event_id
,
'date'
=>
$date
,
'time'
=>
$time
);
$
evtDateTim
e
[]
=
array
(
'event_id'
=>
$event_id
,
'date'
=>
$date
,
'time'
=>
$time
);
}
}
else
{
$cdate
=
strtotime
(
$_POST
[
'event_start_date'
]);
while
(
$cdate
<=
strtotime
(
$_POST
[
'event_end_date'
]))
{
$cdate
=
date
(
'Y-m-d'
,
$cdate
);
foreach
(
$_POST
[
'event_time'
]
AS
$time
)
{
$
insertEventDate
[]
=
array
(
'event_id'
=>
$event_id
,
'date'
=>
$cdate
,
'time'
=>
$time
);
$
evtDateTime
[]
=
array
(
'event_id'
=>
$event_id
,
'date'
=>
$cdate
,
'time'
=>
$time
,
'status'
=>
1
);
}
$cdate
=
strtotime
(
$cdate
.
' +1 day'
);
}
}
$status
=
$this
->
Event_model
->
updateEventDateTime
(
$event_id
,
$
insertEventDat
e
);
$status
=
$this
->
Event_model
->
updateEventDateTime
(
$event_id
,
$
evtDateTim
e
);
$insertTag
=
array
();
foreach
(
$_POST
[
'tags'
]
AS
$tag
)
{
...
...
application/models/Api_model.php
View file @
96248100
...
...
@@ -785,7 +785,7 @@ class Api_model extends CI_Model {
INNER JOIN customer AS CUST ON (CUST.customer_id=BK.customer_id)
INNER JOIN event_date_time AS EDATE ON (EDATE.id=BK.event_date_id)
INNER JOIN translator_event AS TEVT ON (TEVT.event_id=EVT.event_id)
WHERE EVT.status='1' AND BK.status IN ('1','6') AND
WHERE EVT.status='1' AND BK.status IN ('1','6') AND
EDATE.status='1' AND
TEVT.language_code='EN' AND BK.bookId='"
.
$post_data
[
'bookId'
]
.
"'"
;
$bkData
=
$this
->
db
->
query
(
$sql
)
->
row_array
();
...
...
application/models/Webservice_model.php
View file @
96248100
...
...
@@ -1198,7 +1198,7 @@ class Webservice_model extends CI_Model {
INNER JOIN customer AS CUST ON (CUST.customer_id=BK.customer_id)
INNER JOIN event_date_time AS EDATE ON (EDATE.id=BK.event_date_id)
WHERE BK.bookId='
$bookId
' AND EVT.status='1' AND
BK.status IN ('1','6') AND
BK.status IN ('1','6') AND
EDATE.status='1' AND
(TEVT.language_code='
$lang
' OR TEVT.language_code='EN')"
;
$bkData
=
$this
->
db
->
query
(
$sql
)
->
row_array
();
...
...
@@ -2027,6 +2027,9 @@ class Webservice_model extends CI_Model {
$chatUsers
[]
=
$result
;
}
}
// BackUp Contacts
$this
->
db
->
update
(
'customer'
,
array
(
'contact_details'
=>
json_encode
(
$data
[
'contacts'
])),
array
(
'customer_id'
=>
$user_id
));
$respArr
=
array
(
'status'
=>
1
,
'data'
=>
$chatUsers
);
return
$respArr
;
}
...
...
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