mirror of
https://github.com/owncloudarchive/contacts.git
synced 2024-11-29 11:24:11 +01:00
Contacts: Added convinience method for notifications.
This commit is contained in:
parent
845cf4b51a
commit
d8cf49215a
@ -12,6 +12,14 @@ String.prototype.strip_tags = function(){
|
|||||||
|
|
||||||
Contacts={
|
Contacts={
|
||||||
UI:{
|
UI:{
|
||||||
|
notification:function(msg, ndata) {
|
||||||
|
$('#notification').text(msg);
|
||||||
|
if(data) {
|
||||||
|
$('#notification').data(ndata[0],ndata[1]);
|
||||||
|
}
|
||||||
|
$('#notification').fadeIn();
|
||||||
|
setTimeout($('#notification').fadeOut(), 10000);
|
||||||
|
},
|
||||||
notImplemented:function() {
|
notImplemented:function() {
|
||||||
OC.dialogs.alert(t('contacts', 'Sorry, this functionality has not been implemented yet'), t('contacts', 'Not implemented'));
|
OC.dialogs.alert(t('contacts', 'Sorry, this functionality has not been implemented yet'), t('contacts', 'Not implemented'));
|
||||||
},
|
},
|
||||||
@ -1536,6 +1544,10 @@ $(document).ready(function(){
|
|||||||
OCCategories.changed = Contacts.UI.Card.categoriesChanged;
|
OCCategories.changed = Contacts.UI.Card.categoriesChanged;
|
||||||
OCCategories.app = 'contacts';
|
OCCategories.app = 'contacts';
|
||||||
|
|
||||||
|
$('#notification').click(function(){
|
||||||
|
$('#notification').fadeOut();
|
||||||
|
});
|
||||||
|
|
||||||
$('#chooseaddressbook').click(function(){
|
$('#chooseaddressbook').click(function(){
|
||||||
Contacts.UI.Addressbooks.overview();
|
Contacts.UI.Addressbooks.overview();
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user