mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-12 13:24:52 +00:00
Modify shared repo
This commit is contained in:
@@ -67,36 +67,7 @@
|
||||
{% endif %}
|
||||
|
||||
<h3>共享给我的同步目录</h3>
|
||||
{% if in_repos %}
|
||||
<table>
|
||||
<tr>
|
||||
<th width="20%">名字</th>
|
||||
<th width="40%">描述</th>
|
||||
<th width="15%">更新时间</th>
|
||||
<th width="15%">共享来源</th>
|
||||
<th width="10%">操作</th>
|
||||
</tr>
|
||||
|
||||
{% for repo in in_repos %}
|
||||
<tr>
|
||||
<td><a href="{{ SITE_ROOT }}repo/{{ repo.props.id }}">{{ repo.props.name }}</a></td>
|
||||
<td>{{ repo.props.desc }}</td>
|
||||
{% if repo.latest_modify %}
|
||||
<td>{{ repo.latest_modify|translate_commit_time }}</td>
|
||||
{% else %}
|
||||
<td>--</td>
|
||||
{% endif %}
|
||||
<td>{{ repo.props.shared_email }}</td>
|
||||
<td>
|
||||
<img src="{{ MEDIA_URL }}img/sync-20.png" data="{{ repo.props.id }}" class="download-btn vh" title="同步到本地" alt="同步" />
|
||||
<img src="{{ MEDIA_URL }}img/delete-20.png" data="{{ SITE_ROOT }}shareadmin/removeshare/?repo_id={{ repo.id }}&from={{ repo.shared_email }}&to={{ request.user }}" class="unshare-btn vh" title="取消共享" alt="取消共享" />
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
{% else %}
|
||||
<p>暂无</p>
|
||||
{% endif %}
|
||||
{% include "snippets/shared_in_repos.html" %}
|
||||
|
||||
{% url 'org_repo_share' org.url_prefix as repo_share_url %}
|
||||
{% with post_url=repo_share_url %}
|
||||
|
@@ -97,36 +97,7 @@
|
||||
{% endif %}
|
||||
|
||||
<h3>共享给我的同步目录</h3>
|
||||
{% if in_repos %}
|
||||
<table>
|
||||
<tr>
|
||||
<th width="20%">名字</th>
|
||||
<th width="40%">描述</th>
|
||||
<th width="15%">更新时间</th>
|
||||
<th width="15%">共享来源</th>
|
||||
<th width="10%">操作</th>
|
||||
</tr>
|
||||
|
||||
{% for repo in in_repos %}
|
||||
<tr>
|
||||
<td><a href="{{ SITE_ROOT }}repo/{{ repo.props.id }}">{{ repo.props.name }}</a></td>
|
||||
<td>{{ repo.props.desc }}</td>
|
||||
{% if repo.latest_modify %}
|
||||
<td>{{ repo.latest_modify|translate_commit_time }}</td>
|
||||
{% else %}
|
||||
<td>--</td>
|
||||
{% endif %}
|
||||
<td>{{ repo.props.shared_email }}</td>
|
||||
<td>
|
||||
<img src="{{ MEDIA_URL }}img/sync-20.png" data="{{ repo.props.id }}" class="download-btn vh" title="同步到本地" alt="同步" />
|
||||
<img src="{{ MEDIA_URL }}img/delete-20.png" data="{{ SITE_ROOT }}shareadmin/removeshare/?repo_id={{ repo.id }}&from={{ repo.shared_email }}&to={{ request.user }}" class="unshare-btn vh" title="取消共享" alt="取消共享" />
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
{% else %}
|
||||
<p>暂无</p>
|
||||
{% endif %}
|
||||
{% include "snippets/shared_in_repos.html" %}
|
||||
|
||||
{% url 'share_repo' as repo_share_url %}
|
||||
{% with post_url=repo_share_url %}
|
||||
|
31
templates/snippets/shared_in_repos.html
Normal file
31
templates/snippets/shared_in_repos.html
Normal file
@@ -0,0 +1,31 @@
|
||||
{% load seahub_tags %}
|
||||
{% if in_repos %}
|
||||
<table>
|
||||
<tr>
|
||||
<th width="25%">名字</th>
|
||||
<th width="35%">描述</th>
|
||||
<th width="15%">更新时间</th>
|
||||
<th width="15%">共享来源</th>
|
||||
<th width="10%">操作</th>
|
||||
</tr>
|
||||
|
||||
{% for repo in in_repos %}
|
||||
<tr>
|
||||
<td><a href="{{ SITE_ROOT }}repo/{{ repo.props.id }}">{{ repo.props.name }}</a></td>
|
||||
<td>{{ repo.props.desc }}</td>
|
||||
{% if repo.latest_modify %}
|
||||
<td>{{ repo.latest_modify|translate_commit_time }}</td>
|
||||
{% else %}
|
||||
<td>--</td>
|
||||
{% endif %}
|
||||
<td>{{ repo.props.shared_email|email2nickname }}</td>
|
||||
<td>
|
||||
<img src="{{ MEDIA_URL }}img/sync-20.png" data="{{ repo.props.id }}" class="download-btn vh" title="同步到本地" alt="同步" />
|
||||
<img src="{{ MEDIA_URL }}img/delete-20.png" data="{{ SITE_ROOT }}shareadmin/removeshare/?repo_id={{ repo.id }}&from={{ repo.shared_email }}&to={{ request.user }}" class="unshare-btn vh" title="取消共享" alt="取消共享" />
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
{% else %}
|
||||
<p>暂无</p>
|
||||
{% endif %}
|
Reference in New Issue
Block a user