| @@ -97,37 +97,41 @@ | |||||
| <div class="three wide column text center padding0"> | <div class="three wide column text center padding0"> | ||||
| <div class="ui compact buttons" > | <div class="ui compact buttons" > | ||||
| <!-- 停止任务 --> | <!-- 停止任务 --> | ||||
| <form id="stopForm-{{.ID}}" style="margin-left:-1px;"> | |||||
| <form id="stopForm-{{.ID}}" style="margin-left:-1px;" action="{{$.RepoLink}}/modelmanage/convert_stop/{{.ID}}" method="post"> | |||||
| {{$.CsrfTokenHtml}} | {{$.CsrfTokenHtml}} | ||||
| {{if .IsCanOper}} | {{if .IsCanOper}} | ||||
| <a id="ai-stop-{{.ID}}" class='ui basic ai_stop {{if eq .Status "STOPPED" "FAILED" "START_FAILED" "STOPPING" "CREATING" "STARTING" "SUCCEEDED"}}disabled {{else}}blue {{end}}button' data-repopath="{{$.RepoLink}}/modelmanage/convert_stop/{{.ID}}" data-jobid="{{.ID}}"> | |||||
| <a id="ai-stop-{{.ID}}" class='ui basic ai_stop {{if eq .Status "STOPPED" "FAILED" "START_FAILED" "STOPPING" "CREATING" "STARTING" "SUCCEEDED"}}disabled {{else}}blue {{end}}button' > | |||||
| {{$.i18n.Tr "repo.stop"}} | {{$.i18n.Tr "repo.stop"}} | ||||
| </a> | </a> | ||||
| {{else}} | {{else}} | ||||
| <a class="ui basic disabled button"> | |||||
| {{$.i18n.Tr "repo.stop"}} | |||||
| </a> | |||||
| <a class="ui basic disabled button">{{$.i18n.Tr "repo.stop"}} </a> | |||||
| {{end}} | {{end}} | ||||
| </form> | |||||
| </form> | |||||
| <!-- 删除任务 --> | <!-- 删除任务 --> | ||||
| <form id="delForm-{{.ID}}" action="{{$.RepoLink}}/modelmanage/delete_model_convert/{{.ID}}" method="post"> | <form id="delForm-{{.ID}}" action="{{$.RepoLink}}/modelmanage/delete_model_convert/{{.ID}}" method="post"> | ||||
| {{$.CsrfTokenHtml}} | {{$.CsrfTokenHtml}} | ||||
| {{if .IsCanOper}} | |||||
| <a id="ai-delete-{{.ID}}" class='ui basic ai_delete blue button' style="border-radius: .28571429rem;"> | <a id="ai-delete-{{.ID}}" class='ui basic ai_delete blue button' style="border-radius: .28571429rem;"> | ||||
| {{$.i18n.Tr "repo.delete"}} | {{$.i18n.Tr "repo.delete"}} | ||||
| </a> | </a> | ||||
| {{else}} | |||||
| <a class="ui basic disabled button">{{$.i18n.Tr "repo.delete"}} </a> | |||||
| {{end}} | |||||
| </form> | </form> | ||||
| <a href="{{$.Repository.HTMLURL}}/modelmanage/download_model_convert/{{.ID}}?AllDownload=true&a=1" class='ui basic {{if eq .Status "SUCCEEDED"}}blue {{else}}disabled {{end}}button' style="border-radius: .28571429rem;"> | |||||
| {{if .IsCanOper}} | |||||
| <a href="{{$.Repository.HTMLURL}}/modelmanage/download_model_convert/{{.ID}}?AllDownload=true&a=1" class='ui basic {{if eq .Status "SUCCEEDED"}}blue {{else}}disabled {{end}}button' style="border-radius: .28571429rem;"> | |||||
| 下载 | 下载 | ||||
| </a> | |||||
| </a> | |||||
| {{else}} | |||||
| <a class="ui basic disabled button">下载</a> | |||||
| {{end}} | |||||
| </div> | </div> | ||||
| </div> | </div> | ||||
| </div> | </div> | ||||
| </div> | </div> | ||||
| {{end}} | {{end}} | ||||
| <div id="app" style="margin-top: 2rem;"> | <div id="app" style="margin-top: 2rem;"> | ||||
| <div class="center"> | <div class="center"> | ||||
| <el-pagination | <el-pagination | ||||