Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3.5.x #1289

Merged
merged 2 commits into from
Sep 15, 2022
Merged

3.5.x #1289

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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