|
|
|
|
@ -235,6 +235,14 @@
|
|
|
|
|
>
|
|
|
|
|
</template>
|
|
|
|
|
<template v-else>
|
|
|
|
|
<el-button
|
|
|
|
|
v-if="isHasAuth('clone')"
|
|
|
|
|
size="small"
|
|
|
|
|
type="primary"
|
|
|
|
|
plain
|
|
|
|
|
@click="clone(row)"
|
|
|
|
|
>克隆</el-button
|
|
|
|
|
>
|
|
|
|
|
<el-button
|
|
|
|
|
v-if="isHasAuth('detail')"
|
|
|
|
|
size="small"
|
|
|
|
|
@ -306,7 +314,7 @@ import { authMixin } from "@/mixin/authMixin";
|
|
|
|
|
import { uploadSize } from "@/settings";
|
|
|
|
|
import { deepCopy } from "@/utils";
|
|
|
|
|
import { download } from "@/utils/downloadRequest";
|
|
|
|
|
import { destroy, index, save } from "@/api/aspiration/aspiration";
|
|
|
|
|
import { destroy, index, save, clone } from "@/api/aspiration/aspiration";
|
|
|
|
|
import AddAspiration from "./components/AddAspiration.vue";
|
|
|
|
|
import ShowAspiration from "./components/ShowAspiration.vue";
|
|
|
|
|
import axios from "axios";
|
|
|
|
|
@ -469,6 +477,21 @@ export default {
|
|
|
|
|
default:
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
async clone(row) {
|
|
|
|
|
try {
|
|
|
|
|
await this.$confirm("确认操作?", "提示", {
|
|
|
|
|
confirmButtonText: "确认",
|
|
|
|
|
cancelButtonText: "取消",
|
|
|
|
|
});
|
|
|
|
|
await clone({
|
|
|
|
|
id: row.id
|
|
|
|
|
})
|
|
|
|
|
this.$message.success("操作成功")
|
|
|
|
|
this.getList(true)
|
|
|
|
|
} catch (err) {
|
|
|
|
|
console.error(err)
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
async detail(row) {
|
|
|
|
|
await this.$refs["ShowAspiration"].getDetail(row.id);
|
|
|
|
|
this.isShowDetail = true;
|
|
|
|
|
|