Browse Source

Merge remote-tracking branch 'origin/V20211228' into zouap

pull/1788/head
zouap 3 years ago
parent
commit
14251f603c
4 changed files with 11 additions and 3 deletions
  1. +1
    -0
      routers/repo/milestone.go
  2. +1
    -1
      routers/repo/modelarts.go
  3. +2
    -1
      templates/repo/home.tmpl
  4. +7
    -1
      web_src/js/components/Contributors.vue

+ 1
- 0
routers/repo/milestone.go View File

@@ -268,6 +268,7 @@ func MilestoneIssuesAndPulls(ctx *context.Context) {

ctx.Data["CanWriteIssues"] = ctx.Repo.CanWriteIssuesOrPulls(false)
ctx.Data["CanWritePulls"] = ctx.Repo.CanWriteIssuesOrPulls(true)
ctx.Data["PageIsIssueList"] = true

ctx.HTML(200, tplMilestoneIssues)
}

+ 1
- 1
routers/repo/modelarts.go View File

@@ -274,7 +274,7 @@ func NotebookDel(ctx *context.Context) {
return
}

if task.Status != string(models.JobStopped) {
if task.Status != string(models.ModelArtsCreateFailed) && task.Status != string(models.ModelArtsStartFailed) && task.Status != string(models.ModelArtsStopped){
log.Error("the job(%s) has not been stopped", task.JobName)
ctx.ServerError("the job has not been stopped", errors.New("the job has not been stopped"))
return


+ 2
- 1
templates/repo/home.tmpl View File

@@ -337,7 +337,8 @@
{{end}}
<div class="ui right">
<a class="membersmore text grey" href="{{.RepoLink}}/contributors">全部 {{svg "octicon-chevron-right" 16}}</a>
<!-- <a class="membersmore text grey" href="{{.RepoLink}}/contributors">全部 {{svg "octicon-chevron-right" 16}}</a> -->
<a class="membersmore text grey" href="{{.RepoLink}}/contributors?type={{if .IsViewBranch}}branch{{else}}tag{{end}}&name={{.BranchName}}">全部 {{svg "octicon-chevron-right" 16}}</a>
</div>
</h4>
<div class="ui members" id="contributorInfo">


+ 7
- 1
web_src/js/components/Contributors.vue View File

@@ -45,6 +45,8 @@ export default {
data() {
return {
url:'',
url_infor:'',
href_:'',
contributors_list:[],
contributors_list_page:[],
currentPage:1,
@@ -56,7 +58,7 @@ export default {
methods: {

getContributorsList(){
this.$axios.get(this.url+'/list').then((res)=>{
this.$axios.get(this.url+'/list?'+this.url_infor).then((res)=>{
this.contributors_list = res.data.contributor_info
this.totalNum = this.contributors_list.length
this.contributors_list_page = this.contributors_list.slice(0,this.pageSize)
@@ -78,6 +80,10 @@ created(){
this.url = url;
let strIndex = this.url.indexOf("contributors")
this.url_code = this.url.substr(0,strIndex)
this.href_ = window.location.href;
let index = this.href_.indexOf("?")
this.url_infor = this.href_.substring(index+1,this.href_.length)
this.getContributorsList()
},


Loading…
Cancel
Save