style(项目设置): 优化无license时文件模块节点创建的样式

优化无license时文件模块节点创建的样式
This commit is contained in:
song-tianyang 2022-09-19 20:14:11 +08:00 committed by 建国
parent 188a273a51
commit a3da8f2f0b
1 changed files with 7 additions and 3 deletions

View File

@ -11,8 +11,8 @@
:update-permission="['PROJECT_API_SCENARIO:READ+EDIT']" :update-permission="['PROJECT_API_SCENARIO:READ+EDIT']"
:default-label="$t('commons.module_title')" :default-label="$t('commons.module_title')"
:show-case-num="showCaseNum" :show-case-num="showCaseNum"
operation_type_add="external" :operation_type_add="treeOperationType"
operation_type_edit="external" :operation_type_edit="treeOperationType"
@edit="edit" @edit="edit"
@drag="drag" @drag="drag"
@remove="remove" @remove="remove"
@ -39,7 +39,7 @@ import MsNodeTree from "../../../../track/common/NodeTree";
import {buildTree} from "@/business/components/api/definition/model/NodeTree"; import {buildTree} from "@/business/components/api/definition/model/NodeTree";
import MsMyFile from "./MyFile"; import MsMyFile from "./MyFile";
import MsSearchBar from "@/business/components/common/components/search/MsSearchBar"; import MsSearchBar from "@/business/components/common/components/search/MsSearchBar";
import {getCurrentProjectID, getCurrentUserId} from "@/common/js/utils"; import {getCurrentProjectID, getCurrentUserId, hasLicense} from "@/common/js/utils";
import FileModuleDialog from "@/business/components/project/menu/file/dialog/FileModuleDialog"; import FileModuleDialog from "@/business/components/project/menu/file/dialog/FileModuleDialog";
export default { export default {
@ -71,6 +71,10 @@ export default {
computed: { computed: {
projectId() { projectId() {
return getCurrentProjectID(); return getCurrentProjectID();
},
treeOperationType() {
let returnStr = hasLicense() ? 'external' : 'simple'
return returnStr;
} }
}, },
data() { data() {