| @@ -304,37 +304,31 @@ | |||
| </div> | |||
| <div class="five wide column text center"> | |||
| <div class="ui compact buttons"> | |||
| {{if and (ne .Status "WAITING") (ne .JobType "DEBUG")}} | |||
| <!-- {{if and (ne .Status "WAITING") (ne .JobType "DEBUG")}} | |||
| <a class="ui basic button" href="{{$.Link}}/{{.JobID}}/rate" target="_blank"> | |||
| 评分 | |||
| </a> | |||
| {{end}} | |||
| {{end}} --> | |||
| <!-- 调试 --> | |||
| {{if $.Permission.CanWrite $.UnitTypeCloudBrain}} | |||
| {{if .CanDebug}} | |||
| {{if eq .ComputeResource "CPU/GPU"}} | |||
| {{if .CanDebug}} | |||
| <a id="model-debug-{{.JobID}}" class='ui basic {{if ne .Status "RUNNING"}} disabled {{else}}blue {{end}}button' href="{{$.RepoLink}}/cloudbrain/{{.JobID}}/debug" target="_blank"> | |||
| {{$.i18n.Tr "repo.debug"}} | |||
| </a> | |||
| {{else}} | |||
| <a id="model-debug-{{.JobID}}" class="ui basic disabled button" > | |||
| {{$.i18n.Tr "repo.debug"}} | |||
| </a> | |||
| {{end}} | |||
| <a id="model-debug-{{.JobID}}" class='ui basic {{if ne .Status "RUNNING"}} disabled {{else}}blue {{end}}button' href="{{$.RepoLink}}/cloudbrain/{{.JobID}}/debug" target="_blank"> | |||
| {{$.i18n.Tr "repo.debug"}} | |||
| </a> | |||
| {{else}} | |||
| <a id="model-debug-{{.JobID}}" class="ui basic {{if not .CanDebug}}disabled {{else}}blue {{end}}button" href="{{$.RepoLink}}/modelarts/notebook/{{.JobID}}/debug" target="_blank"> | |||
| <a id="model-debug-{{.JobID}}" class='ui basic {{if ne .Status "RUNNING"}} disabled {{else}}blue {{end}}button' href="{{$.RepoLink}}/modelarts/notebook/{{.JobID}}/debug" target="_blank"> | |||
| {{$.i18n.Tr "repo.debug"}} | |||
| </a> | |||
| {{end}} | |||
| {{else}} | |||
| <a class="ui basic disabled button" href="{{$.Link}}/{{.JobID}}/debug" target="_blank"> | |||
| <a class="ui basic disabled button"> | |||
| {{$.i18n.Tr "repo.debug"}} | |||
| </a> | |||
| {{end}} | |||
| <!-- 停止 --> | |||
| <form id="stopForm-{{.JobID}}" action="{{if eq .ComputeResource "CPU/GPU"}}{{$.RepoLink}}/cloudbrain{{else}}{{$.RepoLink}}/modelarts/notebook{{end}}/{{.JobID}}/stop" method="post" style="margin-left:-1px;"> | |||
| {{$.CsrfTokenHtml}} | |||
| {{if $.Permission.CanWrite $.UnitTypeCloudBrain}} | |||
| {{if .CanDel}} | |||
| <a id="stop-model-debug-{{.JobID}}" class='ui basic {{if eq .Status "STOPPED" "FAILED" "START_FAILED" "STOPPING" "CREATING" "STARTING"}}disabled {{else}}blue {{end}}button' onclick="document.getElementById('stopForm-{{.JobID}}').submit();"> | |||
| {{$.i18n.Tr "repo.stop"}} | |||
| </a> | |||
| @@ -361,20 +355,6 @@ | |||
| {{end}} | |||
| </form> | |||
| </div> | |||
| <!-- <div class="ui compact buttons"> | |||
| <a class="ui basic blue button" href="{{$.Link}}/{{.JobID}}/models" target="_blank"> | |||
| {{$.i18n.Tr "repo.download"}} | |||
| </a> | |||
| <iframe src="" frameborder="0" name="iframeContent" style="display: none;"></iframe> | |||
| {{if $.Permission.CanWrite $.UnitTypeCloudBrain}} | |||
| <a id="model-image-{{.JobID}}" style="{{if eq .ComputeResource "CPU/GPU"}} visibility: visible {{else}} visibility: hidden{{end}}" class="imageBtn ui basic {{if not .CanDebug}}disabled {{else}}blue {{end}}button" value="{{.CanDebug}}">{{$.i18n.Tr "repo.submit_image"}}</a> | |||
| {{else}} | |||
| <a class="imageBtn ui basic disabled button" style="{{if eq .ComputeResource "CPU/GPU"}} visibility: visible {{else}} visibility: hidden{{end}}" value="{{.CanDebug}}">{{$.i18n.Tr "repo.submit_image"}}</a> | |||
| {{end}} | |||
| </div> --> | |||
| <!-- 删除任务 --> | |||
| <div class="ui compact buttons" style="{{if eq .ComputeResource "CPU/GPU"}} visibility: visible {{else}} visibility: hidden{{end}}"> | |||
| @@ -394,7 +374,7 @@ | |||
| <div class="item" style="padding: 0 !important;"> | |||
| <!-- 模型下载 --> | |||
| {{if .CanDel}} | |||
| <a class="ui basic blue button" href="{{$.Link}}/{{.JobID}}/models" target="_blank">{{$.i18n.Tr "repo.download"}}</a> | |||
| <a class="ui basic blue button" href="{{$.RepoLink}}/cloudbrain/{{.JobID}}/models" target="_blank">{{$.i18n.Tr "repo.download"}}</a> | |||
| {{else}} | |||
| <a class="ui basic disabled button">{{$.i18n.Tr "repo.download"}}</a> | |||
| {{end}} | |||