2012-05-22 15:28:24 +08:00
|
|
|
|
{% extends "myhome_base.html" %}
|
|
|
|
|
{% load seahub_tags %}
|
|
|
|
|
|
2012-05-31 19:53:33 +08:00
|
|
|
|
{% block main_panel %}
|
|
|
|
|
<h2 class="subject">
|
|
|
|
|
{{repo.props.name}} 历史浏览
|
|
|
|
|
<span class="latest-commit-time-author">({{ current_commit.props.ctime|tsstr_sec }})</span>
|
|
|
|
|
</h2>
|
|
|
|
|
|
|
|
|
|
<div class="side fright">
|
2012-06-06 19:32:27 +08:00
|
|
|
|
{% if is_owner or repo_ap == 'public' or share_to_me %}
|
2012-05-30 14:44:03 +08:00
|
|
|
|
<div class="latest-commit">
|
2012-05-31 17:50:46 +08:00
|
|
|
|
<h3>修改信息</h3>
|
2012-05-30 14:44:03 +08:00
|
|
|
|
<p>{{ current_commit.props.desc|translate_commit_desc }}</p>
|
|
|
|
|
<p class="al-rt">
|
|
|
|
|
<span class="author">by
|
|
|
|
|
{% if current_commit.props.creator_name %}
|
|
|
|
|
{{ current_commit.props.creator_name }}
|
|
|
|
|
{% else %}
|
|
|
|
|
未知
|
|
|
|
|
{% endif %}
|
|
|
|
|
</span>
|
|
|
|
|
<span class="time">{{ current_commit.props.ctime|translate_commit_time }}</span>
|
|
|
|
|
</p>
|
|
|
|
|
</div>
|
2012-05-30 14:12:48 +08:00
|
|
|
|
{% endif %}
|
2012-05-30 14:44:03 +08:00
|
|
|
|
<h3>操作</h3>
|
|
|
|
|
<ul class="with-bg">
|
|
|
|
|
<li><a href="{{ SITE_ROOT }}repo/history/{{ repo.id }}/">返回历史列表</a></li>
|
|
|
|
|
</ul>
|
2012-05-31 19:53:33 +08:00
|
|
|
|
</div>
|
2012-05-30 14:12:48 +08:00
|
|
|
|
|
2012-05-31 19:53:33 +08:00
|
|
|
|
<div class="main fleft">
|
2012-06-06 19:32:27 +08:00
|
|
|
|
{% if not is_owner and repo_ap == 'own' and not share_to_me %}
|
2012-06-01 02:20:35 +08:00
|
|
|
|
<p class="access-notice">该同步目录web匿名访问未开启,不能在线查看。</p>
|
2012-06-06 19:32:27 +08:00
|
|
|
|
{% else %}
|
2012-06-01 02:20:35 +08:00
|
|
|
|
<p class="path">当前路径:
|
2012-06-06 19:32:27 +08:00
|
|
|
|
{% for name, link in zipped %}
|
|
|
|
|
{% if not forloop.last %}
|
2012-05-30 14:44:03 +08:00
|
|
|
|
<a href="{{ SITE_ROOT }}repo/history/dir/{{ repo.id }}/?commit_id={{ current_commit.id}}&p={{ link|urlencode }}">{{ name }}</a> /
|
2012-06-06 19:32:27 +08:00
|
|
|
|
{% else %}
|
2012-05-30 14:44:03 +08:00
|
|
|
|
{{ name }}
|
2012-06-06 19:32:27 +08:00
|
|
|
|
{% endif %}
|
|
|
|
|
{% endfor %}
|
2012-05-30 14:44:03 +08:00
|
|
|
|
</p>
|
|
|
|
|
<table>
|
|
|
|
|
<tr>
|
|
|
|
|
<th width="5%"></th>
|
2012-05-31 19:21:07 +08:00
|
|
|
|
<th width="65%">名字</th>
|
2012-05-30 14:44:03 +08:00
|
|
|
|
<th width="15%">大小</th>
|
2012-05-31 19:21:07 +08:00
|
|
|
|
<th width="15%">操作</th>
|
2012-05-30 14:44:03 +08:00
|
|
|
|
</tr>
|
2012-05-22 15:28:24 +08:00
|
|
|
|
|
2012-06-06 19:32:27 +08:00
|
|
|
|
{% for dirent in dir_list %}
|
2012-05-30 14:44:03 +08:00
|
|
|
|
<tr>
|
|
|
|
|
<td><img src="{{ MEDIA_URL }}img/folder-icon-24.png" /></td>
|
|
|
|
|
<td><a href="{{ SITE_ROOT }}repo/history/dir/{{ repo.id }}/?commit_id={{ current_commit.id }}&p={{ path|urlencode }}{{ dirent.obj_name|urlencode }}">{{ dirent.obj_name }}</a></td>
|
|
|
|
|
<td></td>
|
|
|
|
|
<td></td>
|
|
|
|
|
</tr>
|
2012-06-06 19:32:27 +08:00
|
|
|
|
{% endfor %}
|
2012-05-22 15:28:24 +08:00
|
|
|
|
|
2012-06-06 19:32:27 +08:00
|
|
|
|
{% for dirent in file_list %}
|
2012-05-30 14:44:03 +08:00
|
|
|
|
<tr>
|
|
|
|
|
<td><img src="{{ MEDIA_URL }}img/{{ dirent.obj_name|file_icon_filter }}" /></td>
|
|
|
|
|
<td>{{ dirent.props.obj_name }}</td>
|
|
|
|
|
<td>{{ dirent.file_size|filesizeformat }}</td>
|
|
|
|
|
<td>
|
|
|
|
|
<a class="op" href="{{ SITE_ROOT }}repo/{{ repo.props.id }}/{{ dirent.props.obj_id }}/?file_name={{ dirent.props.obj_name }}&op=view">查看</a>
|
|
|
|
|
<a class="op" href="{{ SITE_ROOT }}repo/{{ repo.props.id }}/{{ dirent.props.obj_id }}/?file_name={{ dirent.props.obj_name }}&op=download">下载</a>
|
|
|
|
|
</td>
|
|
|
|
|
</tr>
|
2012-06-06 19:32:27 +08:00
|
|
|
|
{% endfor %}
|
2012-05-30 14:44:03 +08:00
|
|
|
|
</table>
|
|
|
|
|
{% endif %}
|
2012-05-31 19:53:33 +08:00
|
|
|
|
</div>
|
2012-05-22 15:28:24 +08:00
|
|
|
|
{% endblock %}
|