-
Notifications
You must be signed in to change notification settings - Fork 20
9.2 Notification Function
Taufik Firmansyah edited this page Nov 26, 2015
·
3 revisions
In New Sximo 5.1.2 we adding notification system .
// filename /app/Library/SximoHelpers.php
static function storeNote( $args )
{
$args = array_merge( array(
'url' => '#' ,
'userid' => '0' ,
'title' => '' ,
'note' => '' ,
'created' => date("Y-m-d H:i:s") ,
'icon' => 'fa fa-envelope',
'is_read' => 0
), $args );
\DB::table('tb_notification')->insert($args);
}
##How to adding notification to spesific users ?##
Example after save data , you want to notify superadmin that new data is changed
function postSave( Request $request)
{
$notif = array(
'url' => '#',
'userid' => '1',
'title' => 'New data changed',
'note' => 'Hi Admin, some data has been changed',
);
\SximoHelpers::storeNote($notif);
}
if you log as superadmin with user id 1 , this notification will appeared at your top right screen
####Getting Started
####Setting Application
- Manage Translation
- Manage Social Network
- Manage Basic Info
- Manage Users and Groups
- Blast Emails
- Audit Trails / Log Activities
- Create New Page
- Working with PHP and MySQL on static page
- Create your own theme
- Embed form on your page
- Multilanguage Page content
- Shotcode
- How to disable your input form
- Nested select Dropdown
- [Change Date format] (https://github.com/mangopik/sximo5/wiki/5.3-Changing-Date-format)
- [Select with advance filder] (https://github.com/mangopik/sximo5/wiki/5.4-Select-with-advance-filter)
- Structure
- [Module Configuration Info] (https://github.com/mangopik/sximo5/wiki/6.7-Module-Configuration-Info)
- Formating Post Value before insert to database
- Default Sort and Order
- Entry By table field
- Add default filter Search
- Change view layout template to frontend
- Registering Helpers/Library
- [Notification System] (https://github.com/mangopik/sximo5/wiki/9.2-Notification-Function)