This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "FusionForge".

The branch, feature/subversion-multiple-repositories-per-project has been 
updated
       via  5d705288014afc573f8f117799723329693dfa28 (commit)
      from  c93714ad615d6e368b9f81857afff728a6ab6bdf (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=5d705288014afc573f8f117799723329693dfa28

commit 5d705288014afc573f8f117799723329693dfa28
Author: Franck Villaume <franck.villa...@trivialdev.com>
Date:   Sun Feb 25 19:12:44 2018 +0100

    add missing SVN multirepo browse block

diff --git a/src/plugins/scmsvn/common/SVNPlugin.class.php 
b/src/plugins/scmsvn/common/SVNPlugin.class.php
index 9acc289..4e80d8b 100644
--- a/src/plugins/scmsvn/common/SVNPlugin.class.php
+++ b/src/plugins/scmsvn/common/SVNPlugin.class.php
@@ -267,16 +267,15 @@ some control over it to the project's administrator.");
 
        function getBrowserLinkBlock($project) {
                $b = html_e('h2', array(), _('Subversion Repository Browser'));
-               $b .= '<p>';
-               $b .= sprintf(_("Browsing the %s tree gives you a view into the 
current status of this project's code."), 'Subversion');
-               $b .= ' ';
-               $b .= _('You may also view the complete histories of any file 
in the repository.');
-               $b .= '</p>';
-               $b .= '<p>[' ;
-               $b .= util_make_link 
("/scm/browser.php?group_id=".$project->getID().'&scm_plugin='.$this->name,
-                                                               
sprintf(_('Browse %s Repository'), 'Subversion')
-               ) ;
-               $b .= ']</p>' ;
+               $b .= html_e('p', array(),_("Browsing the Subversion tree gives 
you a view into the current status of this project's code.")
+                                               .' '
+                                               ._('You may also view the 
complete histories of any file in the repository.'));
+               $b .= html_e('p', array(), '['.util_make_link 
("/scm/browser.php?group_id=".$project->getID().'&scm_plugin='.$this->name, 
sprintf(_('Browse %s Repository'), 'Subversion')).']');
+               # Extra repos
+               $repo_list = $this->getRepositories($project, false);
+               foreach ($repo_list as $repo_name) {
+                       $b .= 
'['.util_make_link('/scm/browser.php?group_id='.$project->getID().'&extra='.$repo_name.'&scm_plugin='.$this->name,
 _('Browse extra SVN repository')._(': ').$repo_name).']'.html_e('br');
+               }
                return $b ;
        }
 
@@ -1129,6 +1128,21 @@ some control over it to the project's administrator.");
                        echo html_ac(html_ap() - 1);
                }
        }
+
+       function getRepositories($group, $autoinclude = true) {
+               $repoarr = array();
+               if ($autoinclude) {
+                       $repoarr[] = $group->getUnixName();
+               }
+               $result = db_query_params('SELECT repo_name FROM 
scm_secondary_repos WHERE group_id = $1 AND next_action = $2 AND plugin_id = $3 
ORDER BY repo_name',
+                                                  array($group->getID(),
+                                                         
SCM_EXTRA_REPO_ACTION_UPDATE,
+                                                         $this->getID()));
+               while ($arr = db_fetch_array($result)) {
+                       $repoarr[] = $arr['repo_name'];
+               }
+               return $repoarr;
+       }
 }
 
 // End of class, helper functions now

-----------------------------------------------------------------------

Summary of changes:
 src/plugins/scmsvn/common/SVNPlugin.class.php | 34 +++++++++++++++++++--------
 1 file changed, 24 insertions(+), 10 deletions(-)


hooks/post-receive
-- 
FusionForge

_______________________________________________
Fusionforge-commits mailing list
Fusionforge-commits@lists.fusionforge.org
http://lists.fusionforge.org/cgi-bin/mailman/listinfo/fusionforge-commits

Reply via email to