fix: 修复项目详情页模块加载错误
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
export function getUploadFileAction(status) {
|
||||
const actionMap = {
|
||||
parsed_failed: { key: "viewError", text: "查看错误原因" },
|
||||
parsed_success: { key: "delete", text: "删除" }
|
||||
};
|
||||
|
||||
return actionMap[status] || null;
|
||||
}
|
||||
|
||||
export function getUploadFileStatusText(status) {
|
||||
const map = {
|
||||
uploading: "上传中",
|
||||
parsing: "解析中",
|
||||
parsed_success: "解析成功",
|
||||
parsed_failed: "解析失败",
|
||||
deleted: "已删除"
|
||||
};
|
||||
|
||||
return map[status] || status;
|
||||
}
|
||||
|
||||
export function getUploadFileStatusType(status) {
|
||||
const map = {
|
||||
uploading: "primary",
|
||||
parsing: "warning",
|
||||
parsed_success: "success",
|
||||
parsed_failed: "danger",
|
||||
deleted: "info"
|
||||
};
|
||||
|
||||
return map[status] || "info";
|
||||
}
|
||||
Reference in New Issue
Block a user