From 991459ece9519d19ee54adc5c934a64c874b86c7 Mon Sep 17 00:00:00 2001 From: Ramiro Saenz Date: Tue, 5 Jul 2016 19:54:15 -0300 Subject: [PATCH] Notes for Services Displays a note if the service have one, inside the Add Window. --- app/model/ServiceList.js | 4 ++++ app/store/ServicesList.js | 7 ++++++- app/view/main/MainController.js | 11 +++++++++++ 3 files changed, 21 insertions(+), 1 deletion(-) diff --git a/app/model/ServiceList.js b/app/model/ServiceList.js index ce1efdd5..39fffa05 100644 --- a/app/model/ServiceList.js +++ b/app/model/ServiceList.js @@ -20,5 +20,9 @@ Ext.define('Rambox.model.ServiceList', { name: 'js_unread' ,type: 'string' ,defaultValue: '' + },{ + name: 'note' + ,type: 'string' + ,defaultValue: '' }] }); diff --git a/app/store/ServicesList.js b/app/store/ServicesList.js index e97a70c7..be9cc2d7 100644 --- a/app/store/ServicesList.js +++ b/app/store/ServicesList.js @@ -49,6 +49,7 @@ Ext.define('Rambox.store.ServicesList', { ,name: 'Messenger' ,url: 'https://www.messenger.com/login/' ,type: 'messaging' + ,note: 'To enable desktop notifications, you have to go to Options inside Messenger.' }, { id: 'skype' @@ -56,6 +57,7 @@ Ext.define('Rambox.store.ServicesList', { ,name: 'Skype' ,url: 'https://web.skype.com/' ,type: 'messaging' + ,note: 'Text and Audio calls support only. Video for now is not working.' }, { id: 'hangouts' @@ -107,6 +109,7 @@ Ext.define('Rambox.store.ServicesList', { ,name: 'ChatWork' ,url: 'https://www.chatwork.com/login.php' ,type: 'messaging' + ,note: 'To enable desktop notifications, you have to go to Options inside ChatWork.' }, { id: 'groupme' @@ -114,6 +117,7 @@ Ext.define('Rambox.store.ServicesList', { ,name: 'GroupMe' ,url: 'https://web.groupme.com/signin' ,type: 'messaging' + ,note: 'To enable desktop notifications, you have to go to Options inside GroupMe.' }, { id: 'grape' @@ -267,9 +271,10 @@ Ext.define('Rambox.store.ServicesList', { id: 'mysms' ,logo: 'mysms.png' ,name: 'mysms' - ,url: 'https://app.mysms.com/' + ,url: 'https://app.mysms.com/#login' ,type: 'messaging' ,js_unread: 'function checkUnread(){var e=document.getElementsByClassName("unread"),t=0;for(i=0;i=1?document.title="("+e+") "+originalTitle:document.title=originalTitle}var originalTitle=document.title;setInterval(checkUnread,3000);' + ,note: 'You have to use this service by signing in with your mobile number.' }, { id: 'icq' diff --git a/app/view/main/MainController.js b/app/view/main/MainController.js index 9f0d50c1..b8e99562 100644 --- a/app/view/main/MainController.js +++ b/app/view/main/MainController.js @@ -74,6 +74,17 @@ Ext.define('Rambox.view.main.MainController', { } ] } + ,{ + xtype: 'container' + ,hidden: record.get('note') === '' + ,data: { note: record.get('note') } + ,margin: '10 0 0 0' + ,style: 'background-color:#93CFE0;color:#053767;' + ,tpl: [ + '' + ,'{note}' + ] + } ] } ]