summaryrefslogtreecommitdiffstats
path: root/smarty/templates/rpmphp/zoom.tpl
blob: a470b188508ec75dec2d344d3e438644094b579f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
{*
 * Zoom page template
 *
 * Copyright © 2010 Remi Collet
 *
 * This file is part of rpmphp.
 *
 * rpmphp is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * rpmphp 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 Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with rpmphp.  If not, see <http://www.gnu.org/licenses/>.
*}

{if isset($error)}
    {if $error eq 'missing_name'}
                <h1>Missing package name</h1>
                <form action="?" method="get">
                    <p>You have not specified any package name.</p>
                    <p><label for="rpm">Please enter one package name: </label><input type="text" name="rpm" id="rpm"/> <input type="submit"/></p>
                </form>
    {else}
        <p id="error"><strong>Ooops, an error occured:</strong><br/>{$error}</p>
    {/if}
{/if}
{if isset($pkgdb)}
                <p id="pkgdb-link"><a href="?rpm={$name}">Hide pkgdb informations</a></p>
{else}
                <p id="pkgdb-link"><a href="?rpm={$name}&amp;pkgdb=1">Show more informations from pkgdb</a></p>
{/if}
                <table id="upstream">
                    <caption>Upstream info</caption>
{foreach from=$summary key=k item=v}
                    <tr>
                        <th>{$k}:</th>
                        <td{if $k eq 'Description'} id="pkgdb_desc"{/if}>
    {if $k eq 'Bugzilla'}
                            <a href="{$v}">Active bugs</a>
    {elseif $k eq 'URL' or $k eq 'Pagure' or $k eq 'PkgDB' or $k eq 'Fedora git'}
                            <a href="{$v}">{$v}</a>
    {else}
                            {$v}
    {/if}
                        </td>
                    </tr>
{/foreach}
                </table>
{if is_array($packages) and count($packages) > 0}
                <table id="list-packages">
                    <caption>Packages available in Fedora Repositories</caption>
                    <thead>
                        <tr>
                            <th>Branch</th>
                            <th>Repository</th>
                            <th>Version-Release</th>
                            <th>Owner</th>
                            <th>Co-maintainers</th>
                        </tr>
                    </thead>
                    <tbody>
    {assign var='prev' value=''}
    {foreach from=$packages item=p name=plist}
                        <tr class="{if $smarty.foreach.plist.iteration % 2 eq 0}even{else}odd{/if}">
                            <td>{if $p->repo_main != $prev}
                                <strong>{$p->repo_main}</strong>
                              {else}
                                &nbsp;
                              {/if}</td>
                            <td>{$p->repo_sub}</td>
                            <td><a href='{$p->rpmurl}' alt='Download source RPM'>
                                {if $p->epoch}{$p->epoch}:{/if}
                                {$p->ver}-{$p->rel}</a>
                            </td>
                            <td{if $p->repo_main != $prev} id="pkgdb_{$p->repo_main}_owner"{/if}>
                                {if $p->repo_main != $prev}
                                    {if $fedpkg}
                                        {getBranchPeople branch=$p->repo_main people='owner'}
                                    {elseif $p->askpkgdb}
                                        {$ajax_infos}
                                    {/if}
                                {/if}
                            </td>
                            <td{if $p->repo_main != $prev} id="pkgdb_{$p->repo_main}_maintainers"{/if}>
                                {if $p->repo_main != $prev}
                                    {if $fedpkg}
                                        {getBranchPeople branch=$p->repo_main people='people'}
                                    {elseif $p->askpkgdb}
                                        {$ajax_infos}
                                    {/if}
                                {/if}
                            </td>
                        </tr>
                        {assign var='prev' value=$p->repo_main}
    {/foreach}
                    </tbody>
                </table>
{/if}