Contains tips for configurators working with Aware IM
#41094 by hpl123
Wed Oct 12, 2016 10:59 pm
Hi all,
Here is a sample BSV implementing custom notifications in an Aware IM app (using the new AWESOME EXEC_SCRIPT action).

The sample shows 2 types or notifications, 1 notification bar and 1 notification shown in the middle of the screen and this is only a sample and you can basically customize it however you want and the sample will be a good starting point. PS: I haven´t looked at the quality of the code i.e. the CSS and JS and not looked to see if it interferes with other Aware IM CSS/JS so test it thoroughly before implementing it in a live app.

Just import the BSV, place in testing mode and log on. Press buttons "Notification bar" and "Notification" in top bar (these execute processes that execute the scripts).

Notification bar:
2.png
2.png (54.77 KiB) Viewed 16840 times


Notification:
3.png
3.png (58.65 KiB) Viewed 16840 times


Enjoy :).
Attachments
(35.82 KiB) Downloaded 502 times
#41118 by weblike
Thu Oct 13, 2016 7:28 pm
Henrik,
great job
thx for sharing this....
#41141 by hpl123
Fri Oct 14, 2016 3:21 pm
Update: Another notificaiton added, this time "inpage" i.e a notification shown inpage (above all else on page) for 5 seconds and then the notification is removed. With this solution you also have 4 different alertboxes with different icons and colors (see the "NotificationInPage" content panel for more info):

3.png
3.png (37.6 KiB) Viewed 16795 times


You need to place the "alertboxes" folder in the AwareIM folder for the icons to show.
Attachments
(40.03 KiB) Downloaded 478 times
#41145 by hpl123
Fri Oct 14, 2016 8:49 pm
hpl123 wrote:Update: Another notificaiton added, this time "inpage" i.e a notification shown inpage (above all else on page) for 5 seconds and then the notification is removed. With this solution you also have 4 different alertboxes with different icons and colors (see the "NotificationInPage" content panel for more info):

3.png


You need to place the "alertboxes" folder in the AwareIM folder for the icons to show.


If the code in the SystemSettings.NotificationInpage (initial value) is empty, here is the code you should use and you can change this code to change alertbox type (see NotificationInPage content panel):
Code: Select all$( ".append" ).append( '<div id="append" class="alert-box2 success2"><span>success: </span>Write your success message here.</div>' );setTimeout(function(){$("#append").remove();},5000);
#41185 by hpl123
Mon Oct 17, 2016 9:46 am
Yeah, the EXEC_SCRIPT is a gamechanger :). and a lot of new, cool things can now be done.

Regarding alertify, yes, this should be fairly easy to implement as well. Just follow the instructions on the "Get started" page (to include the alertify source files) and then call the function (s) via EXEC_SCRIPT:
Code: Select allalertify.success('Success notification message.');
#43885 by PointsWell
Sun Jul 09, 2017 7:58 am
Was wondering if you ever got this to work?

I've included the JS and the CSS to the startup.html but I can't get it to call properly
#43896 by weblike
Mon Jul 10, 2017 12:38 pm
PointsWell wrote:Was wondering if you ever got this to work?

I've included the JS and the CSS to the startup.html but I can't get it to call properly


Hi,

Have you tried to copy the JS&CSS files in the following folders?
c:\AwareIM\Tomcat\webapps\AwareIM\Custom\CSS\your_bsv_name
c:\AwareIM\Tomcat\webapps\AwareIM\Custom\JS\your_bsv_name
#43918 by PointsWell
Wed Jul 12, 2017 5:59 am
weblike wrote:Have you tried to copy the JS&CSS files in the following folders?


it would appear that sctipt and script look very similar on a terminal screen - doh!

Who is online

Users browsing this forum: No registered users and 4 guests