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
40f8354a
Commit
40f8354a
authored
Apr 09, 2019
by
Tobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dc
parent
c82f55e5
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
68 additions
and
21 deletions
+68
-21
CMS.php
application/controllers/CMS.php
+6
-0
Checker.php
application/controllers/Checker.php
+9
-4
Customer.php
application/controllers/Customer.php
+8
-2
Provider.php
application/controllers/Provider.php
+8
-2
Api_model.php
application/models/Api_model.php
+20
-13
notification.php
application/views/CMS/notification.php
+17
-0
No files found.
application/controllers/CMS.php
View file @
40f8354a
...
...
@@ -108,6 +108,12 @@ class CMS extends CI_Controller {
if
(
!
isset
(
$_POST
[
'registration_sms'
])
||
empty
(
$_POST
[
'registration_sms'
])){
unset
(
$_POST
[
'registration_sms'
]);
}
if
(
!
isset
(
$_POST
[
'checker_activation_mail'
])
||
empty
(
$_POST
[
'checker_activation_mail'
])){
unset
(
$_POST
[
'checker_activation_mail'
]);
}
if
(
!
isset
(
$_POST
[
'provider_activation_mail'
])
||
empty
(
$_POST
[
'provider_activation_mail'
])){
unset
(
$_POST
[
'provider_activation_mail'
]);
}
$status
=
$this
->
Cms_model
->
updateNotif
(
$_POST
);
if
(
$status
){
...
...
application/controllers/Checker.php
View file @
40f8354a
...
...
@@ -110,15 +110,20 @@ class Checker extends CI_Controller {
$subject
=
"Your Checker Account is now activated"
;
$email_id
=
$checkerData
->
username
;
$template
=
getNotifTemplate
();
$message
.=
"<html>
$message
=
"<html>
<body>
Your Checker Account for the username
<strong>"
.
$checkerData
->
username
.
"</strong> is now activated.<br>
"
.
$template
[
'checker_activation_mail'
]
.
"
<strong>"
.
$email_id
.
"</strong> is now activated.
</body>
</html>"
;
$template
=
getNotifTemplate
();
if
(
isset
(
$template
[
'checker_activation_mail'
])
&&
!
empty
(
$template
[
'checker_activation_mail'
])){
$message
=
str_replace
(
array
(
'{:user_name}'
),
array
(
$email_id
),
$template
[
'checker_activation_mail'
]);
}
$this
->
Api_model
->
send_mail
(
$subject
,
$email_id
,
$message
);
}
}
...
...
application/controllers/Customer.php
View file @
40f8354a
...
...
@@ -123,14 +123,20 @@ class Customer extends CI_Controller {
$subject
=
"Your TimeOut Account is now activated"
;
$email_id
=
$_POST
[
'email'
];
$template
=
getNotifTemplate
();
$message
.=
"<html>
$message
=
"<html>
<body>
Hi,
\n\r
Welcome to TimeOut.
\r\n
Please use username:
"
.
$_POST
[
'email'
]
.
" and Password: "
.
$temp_password
.
"
for access your account <br>
"
.
$template
[
'registration_mail'
]
.
"
</body>
</html>"
;
if
(
isset
(
$template
[
'registration_mail'
])
&&
!
empty
(
$template
[
'registration_mail'
])){
$message
=
str_replace
(
array
(
'{:email}'
,
'{:password}'
),
array
(
$email_id
,
$temp_password
),
$template
[
'registration_mail'
]);
}
$this
->
Api_model
->
send_mail
(
$subject
,
$email_id
,
$message
);
$flashMsg
=
array
(
'message'
=>
'Successfully Updated User Details..!'
,
'class'
=>
'success'
);
...
...
application/controllers/Provider.php
View file @
40f8354a
...
...
@@ -72,15 +72,21 @@ class Provider extends CI_Controller {
$email_id
=
$providerData
->
email
;
$template
=
getNotifTemplate
();
$message
.
=
"<html>
$message
=
"<html>
<body>
Your Organizer Account for the username
<strong>"
.
$providerData
->
username
.
"</strong> is now activated. Please use this link for access your account
<a href='"
.
base_url
()
.
"'>"
.
base_url
()
.
"</a><br>
"
.
$template
[
'provider_activation_mail'
]
.
"
</body>
</html>"
;
if
(
isset
(
$template
[
'provider_activation_mail'
])
&&
!
empty
(
$template
[
'provider_activation_mail'
])){
$message
=
str_replace
(
array
(
'{:user_name}'
,
'{:url}'
),
array
(
$providerData
->
username
,
base_url
()),
$template
[
'provider_activation_mail'
]);
}
$this
->
Api_model
->
send_mail
(
$subject
,
$email_id
,
$message
);
}
}
...
...
application/models/Api_model.php
View file @
40f8354a
...
...
@@ -74,15 +74,20 @@ class Api_model extends CI_Model {
$subject
=
"New account created successfully"
;
$email_id
=
$data
[
'email_id'
];
$template
=
getNotifTemplate
();
$message
=
"<html>
<body>
Hi,
\n\r
Welcome to TimeOut.
\r\n
Please use username:
"
.
$email_id
.
" and Password: "
.
$temp_password
.
"
for access your account <br>
"
.
$template
[
'registration_mail'
]
.
"
</body>
</html>"
;
$message
=
"<html>
<body>
Hi,
\n\r
Welcome to TimeOut.
\r\n
Please use username:
"
.
$email_id
.
" and Password: "
.
$temp_password
.
"
for access your account <br>
</body>
</html>"
;
$template
=
getNotifTemplate
();
if
(
isset
(
$template
[
'registration_mail'
])
&&
!
empty
(
$template
[
'registration_mail'
])){
$message
=
str_replace
(
array
(
'{:email}'
,
'{:password}'
),
array
(
$email_id
,
$temp_password
),
$template
[
'registration_mail'
]);
}
$this
->
send_mail
(
$subject
,
$email_id
,
$message
);
$this
->
db
->
select
(
'customer.name,customer.dob,customer.phone,customer.email,customer.profile_image AS image,customer.gender,users.id AS userId, customer.city'
);
...
...
@@ -139,19 +144,21 @@ class Api_model extends CI_Model {
if
(
$res_count
>
0
)
{
$unique_id
=
uniqid
()
.
time
();
$this
->
db
->
where
(
'email'
,
$data
[
'email_id'
])
->
update
(
'customer'
,
array
(
'reset_key'
=>
$unique_id
));
$subject
=
"TimeOut: Forgot Password"
;
$url
=
'https://projects.nuvento.com/forgot/?reset_key='
.
$unique_id
;
$template
=
getNotifTemplate
();
$message
=
"<html>
<body>
<p>Please use mentioned link for reset your password: "
.
$url
.
"</p>
<br>
"
.
$template
[
'forgot_mail'
]
.
"
</body>
</html>"
;
$email
=
$data
[
'email_id'
];
$template
=
getNotifTemplate
();
if
(
isset
(
$template
[
'forgot_mail'
])
&&
!
empty
(
$template
[
'forgot_mail'
])){
$message
=
str_replace
(
array
(
'{:url}'
),
array
(
$url
),
$template
[
'forgot_mail'
]);
}
$result
=
$this
->
send_mail
(
$subject
,
$email
,
$message
);
if
(
$result
){
$res
=
array
(
'status'
=>
1
,
'data'
=>
null
);
...
...
application/views/CMS/notification.php
View file @
40f8354a
...
...
@@ -45,6 +45,23 @@
</div>
</div>
</div>
<div
class=
"col-sm-12"
>
<div
class=
"col-sm-6"
>
<div
class=
"form-group"
>
<label>
Checker Activation Mail
</label>
<textarea
id=
"rich_editor_2"
type=
"text"
class=
"ip_reg_form_input form-control reset-form-custom"
placeholder=
"Checker Activation Mail"
name=
"checker_activation_mail"
style=
"height:108px;"
data-parsley-trigger=
"change"
>
<?=
$notificationData
->
checker_activation_mail
?>
</textarea>
</div>
</div>
<div
class=
"col-sm-6"
>
<div
class=
"form-group"
>
<label>
Provider Activation Mail
</label>
<textarea
id=
"rich_editor_6"
type=
"text"
class=
"ip_reg_form_input form-control reset-form-custom"
placeholder=
"Provider Activation Mail"
style=
"height:108px;"
name=
"provider_activation_mail"
data-parsley-trigger=
"change"
>
<?=
$notificationData
->
provider_activation_mail
?>
</textarea>
</div>
</div>
</div>
</div>
<div
class=
"box-header with-border"
>
...
...
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