From 40bb1078afeb647132444c7d6df2beb7b9db7140 Mon Sep 17 00:00:00 2001 From: Klaus Leithoff Date: Fri, 18 Oct 2013 14:04:04 +0000 Subject: [PATCH] basic implementation of open and edit on signature (no template for edit, and no action on delete yet) --- mail/inc/class.mail_signatures.inc.php | 4 ++-- mail/js/app.js | 14 ++++++++++++++ mail/templates/default/signatures.index.xet | 2 +- 3 files changed, 17 insertions(+), 3 deletions(-) diff --git a/mail/inc/class.mail_signatures.inc.php b/mail/inc/class.mail_signatures.inc.php index 9717561757..e03a9e33d6 100644 --- a/mail/inc/class.mail_signatures.inc.php +++ b/mail/inc/class.mail_signatures.inc.php @@ -105,7 +105,7 @@ class mail_signatures 'caption' => lang('Open'), 'icon' => 'view', 'group' => ++$group, - 'onExecute' => 'javaScript:app.mail.mail_open', + 'onExecute' => 'javaScript:app.mail.signature_open', 'allowOnMultiple' => false, 'default' => true, ), @@ -113,7 +113,7 @@ class mail_signatures 'caption' => lang('delete'), 'icon' => 'delete', 'group' => ++$group, - 'onExecute' => 'javaScript:app.mail.mail_open', + 'onExecute' => 'javaScript:app.mail.signature_delete', 'allowOnMultiple' => false, ), ); diff --git a/mail/js/app.js b/mail/js/app.js index dce7a9911a..e5bf444a7d 100644 --- a/mail/js/app.js +++ b/mail/js/app.js @@ -1757,6 +1757,20 @@ app.mail = AppJS.extend( this.et2_obj.submit(); }, + signature_open: function(_egw, _widget) + { + var id = _widget[0].id.replace(/row_/,''); + var siggrid = this.et2.getArrayMgr("content").getEntry('sig')[id]; + console.log(_egw, _widget,siggrid,id); + }, + + signature_delete: function(_egw, _widget) + { + var id = _widget[0].id.replace(/row_/,''); + var siggrid = this.et2.getArrayMgr("content").getEntry('sig')[id]; + console.log(_egw, _widget); + }, + /** * Focus handler for folder, address, reject textbox/taglist to automatic check associated radio button */ diff --git a/mail/templates/default/signatures.index.xet b/mail/templates/default/signatures.index.xet index b61839e409..b88adf0af5 100644 --- a/mail/templates/default/signatures.index.xet +++ b/mail/templates/default/signatures.index.xet @@ -2,7 +2,7 @@