|
22 | 22 | style="background: none" |
23 | 23 | class="mr-12" |
24 | 24 | > |
25 | | - <img :src="resetUrl(currentSource?.icon, resetUrl('./favicon.ico'))" alt=""/> |
| 25 | + <img :src="resetUrl(currentSource?.icon, resetUrl('./favicon.ico'))" alt="" /> |
26 | 26 | </el-avatar> |
27 | 27 | <ToolIcon |
28 | 28 | v-else-if="currentSourceType === 'TOOL'" |
|
45 | 45 | <div class="flex-between mb-16"> |
46 | 46 | <div class="flex-between complex-search"> |
47 | 47 | <el-select class="complex-search__left" v-model="searchType" style="width: 100px"> |
48 | | - <el-option :label="$t('common.name')" value="resource_name"/> |
49 | | - <el-option :label="$t('common.creator')" value="user_name"/> |
50 | | - <el-option :label="$t('common.type')" value="source_type"/> |
| 48 | + <el-option :label="$t('common.name')" value="resource_name" /> |
| 49 | + <el-option :label="$t('common.creator')" value="user_name" /> |
| 50 | + <el-option :label="$t('common.type')" value="source_type" /> |
51 | 51 | </el-select> |
52 | 52 | <el-input |
53 | 53 | v-if="searchType === 'resource_name'" |
|
76 | 76 | collapse-tags |
77 | 77 | collapse-tags-tooltip |
78 | 78 | style="width: 220px" |
| 79 | + :placeholder="$t('common.search')" |
79 | 80 | > |
80 | | - <el-option :label="$t('views.application.title')" value="APPLICATION"/> |
81 | | - <el-option :label="$t('views.knowledge.title')" value="KNOWLEDGE"/> |
| 81 | + <el-option :label="$t('views.application.title')" value="APPLICATION" /> |
| 82 | + <el-option :label="$t('views.knowledge.title')" value="KNOWLEDGE" /> |
82 | 83 | </el-select> |
83 | 84 | </div> |
84 | 85 | </div> |
|
111 | 112 | style="background: none" |
112 | 113 | class="mr-8" |
113 | 114 | > |
114 | | - <img :src="resetUrl(row?.icon, resetUrl('./favicon.ico'))" alt=""/> |
| 115 | + <img :src="resetUrl(row?.icon, resetUrl('./favicon.ico'))" alt="" /> |
115 | 116 | </el-avatar> |
116 | 117 |
|
117 | 118 | <span>{{ row.name }}</span> |
|
158 | 159 | @click="workspaceVisible = !workspaceVisible" |
159 | 160 | > |
160 | 161 | <el-icon> |
161 | | - <Filter/> |
| 162 | + <Filter /> |
162 | 163 | </el-icon> |
163 | 164 | </el-button> |
164 | 165 | </template> |
|
184 | 185 | /> |
185 | 186 | </el-checkbox-group> |
186 | 187 | </el-scrollbar> |
187 | | - <el-empty v-else :description="$t('common.noData')"/> |
| 188 | + <el-empty v-else :description="$t('common.noData')" /> |
188 | 189 | </div> |
189 | 190 | </div> |
190 | 191 | </div> |
191 | 192 | <div class="text-right"> |
192 | 193 | <el-button size="small" @click="filterWorkspaceChange('clear')" |
193 | | - >{{ $t('common.clear') }} |
| 194 | + >{{ $t('common.clear') }} |
194 | 195 | </el-button> |
195 | 196 | <el-button type="primary" @click="filterWorkspaceChange" size="small" |
196 | | - >{{ $t('common.confirm') }} |
| 197 | + >{{ $t('common.confirm') }} |
197 | 198 | </el-button> |
198 | 199 | </div> |
199 | 200 | </el-popover> |
|
210 | 211 | </el-drawer> |
211 | 212 | </template> |
212 | 213 | <script setup lang="ts"> |
213 | | -import {ref, reactive, computed, onMounted, watch} from 'vue' |
214 | | -import {useRoute, useRouter} from 'vue-router' |
215 | | -import {loadSharedApi} from '@/utils/dynamics-api/shared-api' |
216 | | -import {isAppIcon, resetUrl} from '@/utils/common' |
| 214 | +import { ref, reactive, computed, onMounted, watch } from 'vue' |
| 215 | +import { useRoute, useRouter } from 'vue-router' |
| 216 | +import { loadSharedApi } from '@/utils/dynamics-api/shared-api' |
| 217 | +import { isAppIcon, resetUrl } from '@/utils/common' |
217 | 218 | import useStore from '@/stores' |
218 | | -import {t} from '@/locales' |
219 | | -import type {Provider} from '@/api/type/model' |
220 | | -import {loadPermissionApi} from '@/utils/dynamics-api/permission-api.ts' |
| 219 | +import { t } from '@/locales' |
| 220 | +import type { Provider } from '@/api/type/model' |
| 221 | +import { loadPermissionApi } from '@/utils/dynamics-api/permission-api.ts' |
221 | 222 |
|
222 | 223 | const route = useRoute() |
223 | 224 | const router = useRouter() |
224 | | -const {model, user} = useStore() |
| 225 | +const { model, user } = useStore() |
225 | 226 | const searchType = ref<string>('resource_name') |
226 | 227 | const query = ref<any>({ |
227 | 228 | resource_name: '', |
@@ -267,7 +268,7 @@ const pageResourceMapping = () => { |
267 | 268 | if (workspaceArr.value.length > 0) { |
268 | 269 | params.workspace_ids = JSON.stringify(workspaceArr.value) |
269 | 270 | } |
270 | | - loadSharedApi({type: 'resourceMapping', systemType: apiType.value}) |
| 271 | + loadSharedApi({ type: 'resourceMapping', systemType: apiType.value }) |
271 | 272 | .getResourceMapping( |
272 | 273 | workspaceId, |
273 | 274 | currentSourceType.value, |
@@ -385,7 +386,7 @@ watch( |
385 | 386 | v.label.toLowerCase().includes(filterText.value.toLowerCase()), |
386 | 387 | ) |
387 | 388 | }, |
388 | | - {immediate: true}, |
| 389 | + { immediate: true }, |
389 | 390 | ) |
390 | 391 |
|
391 | 392 | defineExpose({ |
|
0 commit comments