实现项目归档功能
This commit is contained in:
@@ -62,7 +62,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {getStatusCounts, listProject, rebuildProjectTags} from '@/api/ccdiProject'
|
||||
import {archiveProject, getStatusCounts, listProject, rebuildProjectTags} from '@/api/ccdiProject'
|
||||
import SearchBar from './components/SearchBar'
|
||||
import ProjectTable from './components/ProjectTable'
|
||||
import QuickEntry from './components/QuickEntry'
|
||||
@@ -268,11 +268,17 @@ export default {
|
||||
this.archiveDialogVisible = true;
|
||||
},
|
||||
/** 确认归档 */
|
||||
handleConfirmArchive(data) {
|
||||
console.log("确认归档:", data);
|
||||
this.$modal.msgSuccess("项目已归档");
|
||||
this.archiveDialogVisible = false;
|
||||
this.getList();
|
||||
async handleConfirmArchive(data) {
|
||||
try {
|
||||
await archiveProject(data.projectId)
|
||||
this.$modal.msgSuccess("项目归档成功")
|
||||
this.archiveDialogVisible = false
|
||||
this.currentArchiveProject = null
|
||||
this.getList()
|
||||
} catch (error) {
|
||||
const message = error && error.message ? error.message : "项目归档失败,请稍后重试"
|
||||
this.$modal.msgError(message)
|
||||
}
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user