From 0535ed02cd1f0ff6b22c7b1ea25b1547adcf4950 Mon Sep 17 00:00:00 2001 From: x2001corpet Date: Tue, 21 Nov 2006 00:25:23 +0000 Subject: [PATCH] #553 fix send a bug link when right clicking git-svn-id: svn+ssh://murphy/home/svn/platal/trunk@1115 839d8a87-29fc-0310-9880-83ba4fa771e5 --- ChangeLog | 1 + modules/events.php | 7 +++++++ templates/skin/common.bug.tpl | 10 ++++++++-- 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 6e14b7b..1507b03 100644 --- a/ChangeLog +++ b/ChangeLog @@ -38,6 +38,7 @@ Bug/Wish: - #473: Use 'événement' instead of 'évènement'. -FRU - #475: More understandable bug report form. -FRU - #548: More informations for recovery for homonyms. -FRU + - #553: Fix right click on send bug link. -Car * Events: - #517: URL catcher update (www). -Car diff --git a/modules/events.php b/modules/events.php index 7af2fc2..2702756 100644 --- a/modules/events.php +++ b/modules/events.php @@ -25,6 +25,7 @@ class EventsModule extends PLModule { return array( 'events' => $this->make_hook('ev', AUTH_COOKIE), + 'send_bug' => $this->make_hook('bug', AUTH_COOKIE), 'events/submit' => $this->make_hook('ev_submit', AUTH_MDP), 'admin/events' => $this->make_hook('admin_events', AUTH_MDP, 'admin'), @@ -43,6 +44,12 @@ class EventsModule extends PLModule subscribe_nl($uid); } + function handler_bug(&$page) + { + $this->handler_ev($page); + $page->assign('bug', 1); + } + function handler_ev(&$page, $action = 'list', $eid = null, $pound = null) { $page->changeTpl('login.tpl'); diff --git a/templates/skin/common.bug.tpl b/templates/skin/common.bug.tpl index 5a1c911..639ee05 100644 --- a/templates/skin/common.bug.tpl +++ b/templates/skin/common.bug.tpl @@ -11,7 +11,7 @@ -   Sujet : +   Sujet : @@ -25,7 +25,8 @@ ** Explique ici le problème ou l'amélioration proposée ** -Page : {$globals->baseurl}/?{$smarty.server.QUERY_STRING} +Page : {if $bug}{$smarty.server.HTTP_REFERER}{else}{$globals->baseurl}/?{$smarty.server.QUERY_STRING}{/if} + Navigateur : {$smarty.server.HTTP_USER_AGENT} Skin : {$smarty.session.skin} Signalé par {$smarty.session.forlife} @@ -36,3 +37,8 @@ Signal +{if $bug} + +{/if} -- 2.1.4