Skip to content

Commit

Permalink
Merge pull request #1289 from hLinx/3.5.x
Browse files Browse the repository at this point in the history
3.5.x
  • Loading branch information
hLinx authored Sep 15, 2022
2 parents ff5c0e2 + d3a2c90 commit 689ef08
Show file tree
Hide file tree
Showing 3 changed files with 67 additions and 48 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -333,6 +333,15 @@
window.open(router.href);
},
routerBack () {
if (this.formData.taskExecution.debugTask) {
this.$router.push({
name: 'templateDetail',
params: {
id: this.formData.taskExecution.templateId,
},
});
return;
}
const { from } = this.$route.query;
if (from === 'viewPlan') {
this.$router.push({
Expand Down
19 changes: 7 additions & 12 deletions src/frontend/src/views/task-manage/common/plan/list/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -162,24 +162,21 @@
active: selectPlanInfo.id === row.id,
}">
<div class="name-wraper">
<div class="name-text" v-bk-overflow-tips>{{ row.name }}</div>
<router-link
<div
class="name-text"
v-bk-overflow-tips>
{{ row.name }}
</div>
<span
v-if="row.cronJobCount > 0"
class="cron-job-tag"
:to="{
name: 'cronList',
query: {
planId: row.id,
},
}"
target="_blank"
v-bk-tooltips.html="`
<div>${$t('template.有')} ${row.cronJobCount} ${$t('template.个定时任务')}</div>
<div>${$t('template.点击前往查看')}</div>
`">
<Icon type="job-timing" svg />
<span style="margin-left: 2px;">{{ row.cronJobCount }}</span>
</router-link>
</span>
<span
v-if="row.needUpdate"
class="update-flag">
Expand All @@ -188,10 +185,8 @@
type="sync-8"
svg />
</span>

</div>
<Icon
@click.stop="handleCollection(row)"
type="collection"
class="collection-flag"
:class="{ favored: row.favored }" />
Expand Down
87 changes: 51 additions & 36 deletions src/frontend/src/views/task-manage/list/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -109,42 +109,57 @@
key="name"
align="left">
<template slot-scope="{ row }">
<div class="task-name-box">
<Icon
type="collection"
class="task-collection"
:class="row.favored ? 'favored' : 'unfavored'"
@click="handleCollection(row)" />
<auth-router-link
class="task-name-text"
v-bk-overflow-tips
:permission="row.canView"
auth="job_template/view"
:resource-id="row.id"
:to="{
name: 'templateDetail',
params: {
id: row.id,
},
}">
{{ row.name }}
</auth-router-link>
<auth-router-link
:permission="row.canView"
auth="job_template/view"
:resource-id="row.id"
:to="{
name: 'templateDetail',
params: {
id: row.id,
},
query: {
mode: 'scriptUpdate',
},
}">
<span v-html="row.scriptStatusHtml" />
</auth-router-link>
</div>
<auth-component
:permission="row.canView"
auth="job_template/view"
:resource-id="row.id">
<div class="task-name-box">
<Icon
type="collection"
class="task-collection"
:class="row.favored ? 'favored' : 'unfavored'"
@click="handleCollection(row)" />
<router-link
class="task-name-text"
v-bk-overflow-tips
:to="{
name: 'templateDetail',
params: {
id: row.id,
},
}">
{{ row.name }}
</router-link>
<router-link
:to="{
name: 'templateDetail',
params: {
id: row.id,
},
query: {
mode: 'scriptUpdate',
},
}">
<span v-html="row.scriptStatusHtml" />
</router-link>
</div>
<div
slot="forbid"
class="task-name-box">
<Icon
type="collection"
class="task-collection"
:class="row.favored ? 'favored' : 'unfavored'" />
<span
class="task-name-text"
v-bk-overflow-tips>
{{ row.name }}
</span>
<span>
<span v-html="row.scriptStatusHtml" />
</span>
</div>
</auth-component>
</template>
</bk-table-column>
<bk-table-column
Expand Down

0 comments on commit 689ef08

Please sign in to comment.