HF Space Manager

退出登录
{% if spaces %} {% set grouped_spaces = {} %} {% for space in spaces %} {% if space.owner not in grouped_spaces %} {% set _ = grouped_spaces.update({space.owner: []}) %} {% endif %} {% set _ = grouped_spaces[space.owner].append(space) %} {% endfor %} {% for owner, owner_spaces in grouped_spaces.items() %} {% set sorted_spaces = owner_spaces %} {% set running_count = sorted_spaces | selectattr('status','equalto','RUNNING') | list | length %} {% set building_count = sorted_spaces | selectattr('status','equalto','BUILDING') | list | length %} {% set sleeping_count = sorted_spaces | selectattr('status','equalto','SLEEPING') | list | length %} {% set stopped_count = sorted_spaces | selectattr('status','equalto','STOPPED') | list | length %} {% set failed_count = sorted_spaces | selectattr('status','equalto','BUILD_ERROR') | list | length %}
{{ owner }} 总数: {{ sorted_spaces | length }} 运行:{{ running_count }} 休眠:{{ sleeping_count }} 停止:{{ stopped_count }} 失败:{{ failed_count }}
{% for space in sorted_spaces %}
{{ space.name }}

ID: {{ space.repo_id }}

状态: {{ space.status }}

创建时间: {{ space.created_at }}

最后修改: {{ space.last_modified }}

SDK: {{ space.sdk }}

App端口: {{ space.app_port }}

{% if space.tags %}

标签:{% for tag in space.tags %}{{ tag }} {% endfor %}

{% endif %}

私有: {{ '是' if space.private else '否' }}

查看
{% endfor %}
{% endfor %} {% else %}

没有找到任何 Spaces。请确保你的账户中有创建的Spaces,并且提供的 token 有正确的权限。

{% endif %}