Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Screenshots
-----------

![alt text](doc/SearchRelatedIssue.png)
![alt text](doc/description.png)

Download
--------
Expand Down
36 changes: 32 additions & 4 deletions SearchRelatedIssue/files/related_search_240520191349.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/*
# Copyright (c) 2019 brlumen (igflocal@gmail.com)
# Original Copyright (c) 2019 brlumen (igflocal@gmail.com)
# Modification Copyright (c) 2020 Selonka
# SearchRelatedIssue for MantisBT is free software:
# you can redistribute it and/or modify it under the terms of the GNU
# General Public License as published by the Free Software Foundation,
Expand All @@ -23,8 +24,15 @@
margin: 0 0 0 0;
margin-top: 2px;
}

.search_result a{
.popup{
background: #FFF;
border: 1px #ccc solid;
max-height:400px;
overflow-y:auto;
margin: 0 0 0 0;
margin-top: 2px;
}
.search_result .issue{
display: block;
margin: 3px 3px;
padding: 7px;
Expand All @@ -34,4 +42,24 @@
cursor: pointer;
border-radius: 3px;
overflow-y: hidden;
}
}

.popup {
display: none;
visibility: hidden;
}
.search_result div:hover .popup{
display: block;
visibility: visible;
}
.search_result a{
display: none;
visibility: hidden;
}

.search_result div:hover a{
display: block;
visibility: visible;
}


3 changes: 2 additions & 1 deletion SearchRelatedIssue/lang/strings_english.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,5 @@
# If not, see <http://www.gnu.org/licenses/>.

$s_plugin_SearchRelatedIssue_header_related_issue_list = 'The following %1$s might be related.';
$s_plugin_SearchRelatedIssue_description = 'The plugin implements a live search for related issues during the creation of a new issue.';
$s_plugin_SearchRelatedIssue_description = 'The plugin implements a live search for related issues during the creation of a new issue.';
$s_plugin_SearchRelatedIssue_go_to = 'Go to';
19 changes: 19 additions & 0 deletions SearchRelatedIssue/lang/strings_german.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<?php
# Copyright (c) 2019 brlumen (igflocal@gmail.com)
# SearchRelatedIssue for MantisBT is free software:
# you can redistribute it and/or modify it under the terms of the GNU
# General Public License as published by the Free Software Foundation,
# either version 2 of the License, or (at your option) any later version.
#
# SearchRelatedIssue plugin for for MantisBT is distributed in the hope
# that it will be useful, but WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with SearchRelatedIssue plugin for MantisBT.
# If not, see <http://www.gnu.org/licenses/>.

$s_plugin_SearchRelatedIssue_header_related_issue_list = 'Die folgenden %1$s ähneln der Eingabe.';
$s_plugin_SearchRelatedIssue_description = 'Das Plugin implementiert eine Live-Suche für ähnliche Einträge, waehrend der Erstellung eines neuen Eintrags.';
$s_plugin_SearchRelatedIssue_go_to = 'Gehe zu Eintrag';
8 changes: 5 additions & 3 deletions SearchRelatedIssue/pages/search.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<?php

# Copyright (c) 2019 brlumen (igflocal@gmail.com)
# Original Copyright (c) 2019 brlumen (igflocal@gmail.com)
# Modification Copyright (c) 2020 Selonka
# SearchRelatedIssue for MantisBT is free software:
# you can redistribute it and/or modify it under the terms of the GNU
# General Public License as published by the Free Software Foundation,
Expand Down Expand Up @@ -45,10 +46,11 @@

$t_response['data'] = '<ul class="search_result">';
$t_response['data'] .= '<li style="margin-left: 5px; margin-top: 5px; margin-bottom: 5px;">' . sprintf( plugin_lang_get( 'header_related_issue_list' ), lang_get( 'issues' ) ) . '</li>';

foreach( $t_rows as $t_issue ) {
$t_response['data'] .= '<li>' .
'<a class=search_result style="background-color:' . get_status_color( $t_issue->status ) . ';" href="' . string_get_bug_view_url( $t_issue->id ) . '";>' . $t_issue->id . ": " . $t_issue->summary . '</a></li>';
'<div class="issue" style="background-color:' . get_status_color( $t_issue->status ) . ';" >' . $t_issue->id . ": " . $t_issue->summary . '<div class="popup">'. $t_issue->description.'</div><a href="' . string_get_bug_view_url( $t_issue->id ) . '";>' .plugin_lang_get( 'go_to' ).'</a></div></li>';

}

$t_response['data'] .= '</ul>';
Expand Down
Binary file added doc/description.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.