Merge branch 'dev-dictionary' of github.com:jetlinks/jetlinks-ui-vue into dev-dictionary

This commit is contained in:
leiqiaochu 2023-10-17 15:29:13 +08:00
commit 329ec037d2
4 changed files with 16 additions and 18 deletions

View File

@ -166,4 +166,4 @@ watch(() => instanceStore.current?.id, () => {
} }
}, { immediate: true }) }, { immediate: true })
</script> </script>

View File

@ -61,10 +61,11 @@
title="继承自产品物模型的数据不支持修改" title="继承自产品物模型的数据不支持修改"
> >
<!-- <ModelButton :disabled="true"/>--> <!-- <ModelButton :disabled="true"/>-->
<j-button :disabled="true" type="link" style="padding-left: 0;"> <j-button :disabled="true" type="link" >
<AIcon type="SettingOutlined" /> <AIcon type="SettingOutlined" />
配置 配置
</j-button> </j-button>
</j-tooltip> </j-tooltip>
<PermissionButton <PermissionButton
v-else v-else
@ -93,7 +94,7 @@
title="继承自产品物模型的数据不支持修改" title="继承自产品物模型的数据不支持修改"
> >
<!-- <ModelButton :disabled="true"/>--> <!-- <ModelButton :disabled="true"/>-->
<j-button :disabled="true" type="link" style="padding-left: 0;"> <j-button :disabled="true" type="link">
<AIcon type="SettingOutlined" /> <AIcon type="SettingOutlined" />
配置 配置
</j-button> </j-button>
@ -116,30 +117,29 @@
</j-tag> </j-tag>
</template> </template>
<template #other="{ data }"> <template #other="{ data }">
<j-tooltip <!-- <j-tooltip
v-if="target === 'device' && productNoEdit.id?.includes?.(data.record.id)" v-if="target === 'device' && productNoEdit.id?.includes?.(data.record.id)"
title="继承自产品物模型的数据不支持修改" title="继承自产品物模型的数据不支持修改"
> > -->
<!-- <ModelButton :disabled="true"/>--> <!-- <ModelButton :disabled="true"/>-->
<j-button :disabled="true" type="link" style="padding-left: 0;"> <!-- <j-button :disabled="true" type="link" style="padding-left: 0;">
<AIcon type="SettingOutlined" /> <AIcon type="SettingOutlined" />
配置 配置
</j-button> </j-button> -->
</j-tooltip> <!-- </j-tooltip> -->
<PermissionButton <PermissionButton
v-else
:has-permission="`${permission}:update`" :has-permission="`${permission}:update`"
type="link" type="link"
key="setting" key="setting"
:tooltip="target === 'device' && productNoEdit.id?.includes?.(data.record.id) ? {
title: '继承自产品物模型的数据不支持删除',
} : undefined"
> >
<OtherSetting <OtherSetting
v-model:value="data.record.expands" v-model:value="data.record.expands"
:id="data.record.id" :id="data.record.id"
:disabled="target === 'device' && productNoEdit.id?.includes?.(data.record.id)" :disabled="target === 'device' && productNoEdit.id?.includes?.(data.record.id)"
:record="data.record" :record="data.record"
:tooltip="target === 'device' && productNoEdit.id?.includes?.(data.record.id) ? {
title: '继承自产品物模型的数据不支持删除',
} : undefined"
:type="data.record.valueType.type" :type="data.record.valueType.type"
/> />
</PermissionButton> </PermissionButton>

View File

@ -637,7 +637,7 @@ const handleImport = async () => {
data[data?.type === 'copy' ? 'copy' : 'import'] || data[data?.type === 'copy' ? 'copy' : 'import'] ||
'{}', '{}',
); );
if(data?.type === 'import'){ if(data?.type !== 'copy'){
Object.keys(_object).forEach((i:any)=>{ Object.keys(_object).forEach((i:any)=>{
const map = new Map() const map = new Map()
_object[i].forEach((item:any)=>( _object[i].forEach((item:any)=>(

View File

@ -319,7 +319,6 @@
</j-button> </j-button>
</div> </div>
</FullPage> </FullPage>
<Relation></Relation>
</page-container> </page-container>
</template> </template>
@ -333,7 +332,6 @@ import { save_api } from '@/api/system/basis';
import { usePermissionStore } from '@/store/permission'; import { usePermissionStore } from '@/store/permission';
import { useSystem } from '@/store/system'; import { useSystem } from '@/store/system';
import { settingDetail } from '@/api/login'; import { settingDetail } from '@/api/login';
import Relation from '@/components/Relation/index.vue'
const action = `${BASE_API_PATH}/file/static`; const action = `${BASE_API_PATH}/file/static`;
const headers = { [TOKEN_KEY]: LocalStore.get(TOKEN_KEY) }; const headers = { [TOKEN_KEY]: LocalStore.get(TOKEN_KEY) };
const formRef = ref(); const formRef = ref();