3030 </template >
3131 <div v-if =" configType === 'wechat'" class =" flex align-center mb-16" >
3232 <span class =" lighter mr-8" >{{
33- $t('views.application.applicationAccess.wecomSetting.authenticationSuccessful')
34- }}</span >
35- <el-switch v-if =" configType === 'wechat'" v-model =" form[configType].is_certification" />
33+ $t('views.application.applicationAccess.wecomSetting.authenticationSuccessful')
34+ }}</span >
35+ <el-switch v-if =" configType === 'wechat'" v-model =" form[configType].is_certification" />
3636 </div >
3737
3838 <h4 class =" title-decoration-1 mb-16" >
5656 class =" color-primary"
5757 href =" https://mp.weixin.qq.com/advanced/advanced?action=dev&t=advanced/dev"
5858 target =" _blank"
59- >{{ $t('views.application.applicationAccess.wechatPlatform') }}</a
59+ >{{ $t('views.application.applicationAccess.wechatPlatform') }}</a
6060 >{{ $t('views.application.applicationAccess.wechatSetting.urlInfo') }}
6161 </el-text >
6262 <el-text type =" info" v-if =" configType === 'dingtalk'" >
6565 class =" color-primary"
6666 href =" https://open-dev.dingtalk.com/fe/app?hash=%23%2Fcorp%2Fapp#/corp/app"
6767 target =" _blank"
68- >{{ $t('views.application.applicationAccess.dingtalkPlatform') }}</a
68+ >{{ $t('views.application.applicationAccess.dingtalkPlatform') }}</a
6969 >{{ $t('views.application.applicationAccess.dingtalkSetting.urlInfo') }}
7070 </el-text >
7171 <el-text type =" info" v-if =" configType === 'wecom'" >
7474 class =" color-primary"
7575 href =" https://work.weixin.qq.com/wework_admin/frame#apps"
7676 target =" _blank"
77- >{{ $t('views.application.applicationAccess.wecomPlatform') }}</a
77+ >{{ $t('views.application.applicationAccess.wecomPlatform') }}</a
7878 >{{ $t('views.application.applicationAccess.wecomSetting.urlInfo') }}
7979 </el-text >
8080 <el-text type =" info" v-if =" configType === 'lark'" >
8181 {{ $t('views.application.applicationAccess.copyUrl') }}
82- <a class =" primary" href =" https://open.feishu.cn/app/" target =" _blank" >{{
83- $t('views.application.applicationAccess.larkPlatform')
84- }}</a
82+ <a class =" color- primary" href =" https://open.feishu.cn/app/" target =" _blank" >{{
83+ $t('views.application.applicationAccess.larkPlatform')
84+ }}</a
8585 >{{ $t('views.application.applicationAccess.larkSetting.urlInfo') }}
8686 </el-text >
8787 <el-text type =" info" v-if =" configType === 'wecomBot'" >
9090 class =" color-primary"
9191 href =" https://work.weixin.qq.com/wework_admin/frame#/manageTools"
9292 target =" _blank"
93- >{{ $t('views.application.applicationAccess.wecomPlatform') }}</a
93+ >{{ $t('views.application.applicationAccess.wecomPlatform') }}</a
9494 >{{ $t('views.application.applicationAccess.wecomBotSetting.urlInfo') }}
9595 </el-text >
96-
9796 </el-form-item >
9897 </el-form >
9998
109108</template >
110109
111110<script setup lang="ts">
112- import {ref , reactive , computed } from ' vue'
113- import type {FormInstance } from ' element-plus'
114- import {useRoute } from ' vue-router'
115- import {MsgError , MsgSuccess } from ' @/utils/message'
116- import {copyClick } from ' @/utils/clipboard'
117- import {t } from ' @/locales'
118- import {loadSharedApi } from ' @/utils/dynamics-api/shared-api'
111+ import { ref , reactive , computed } from ' vue'
112+ import type { FormInstance } from ' element-plus'
113+ import { useRoute } from ' vue-router'
114+ import { MsgError , MsgSuccess } from ' @/utils/message'
115+ import { copyClick } from ' @/utils/clipboard'
116+ import { t } from ' @/locales'
117+ import { loadSharedApi } from ' @/utils/dynamics-api/shared-api'
119118
120119type PlatformType = ' wechat' | ' dingtalk' | ' wecom' | ' lark' | ' slack' | ' wecomBot'
121120
122121const route = useRoute ()
123122
124123const {
125- params : {id },
124+ params : { id },
126125} = route as any
127126const apiType = computed (() => {
128127 if (route .path .includes (' resource-management' )) {
@@ -147,7 +146,7 @@ const form = reactive<any>({
147146 is_certification: false ,
148147 callback_url: ' ' ,
149148 },
150- dingtalk: {client_id: ' ' , client_secret: ' ' , callback_url: ' ' },
149+ dingtalk: { client_id: ' ' , client_secret: ' ' , callback_url: ' ' },
151150 wecom: {
152151 app_id: ' ' ,
153152 agent_id: ' ' ,
@@ -156,13 +155,13 @@ const form = reactive<any>({
156155 encoding_aes_key: ' ' ,
157156 callback_url: ' ' ,
158157 },
159- lark: {app_id: ' ' , app_secret: ' ' , verification_token: ' ' , callback_url: ' ' },
160- slack: {signing_secret: ' ' , bot_user_token: ' ' , callback_url: ' ' },
158+ lark: { app_id: ' ' , app_secret: ' ' , verification_token: ' ' , callback_url: ' ' },
159+ slack: { signing_secret: ' ' , bot_user_token: ' ' , callback_url: ' ' },
161160 wecomBot: {
162161 token: ' ' ,
163162 encoding_aes_key: ' ' ,
164163 callback_url: ' ' ,
165- }
164+ },
166165})
167166
168167const rules = reactive <{ [propName : string ]: any }>({
@@ -316,38 +315,38 @@ const configFields: { [propName: string]: { [propName: string]: any } } = {
316315 label: t (' views.application.applicationAccess.wechatSetting.appSecret' ),
317316 placeholder: ' ' ,
318317 },
319- token: {label: t (' views.application.applicationAccess.wechatSetting.token' ), placeholder: ' ' },
318+ token: { label: t (' views.application.applicationAccess.wechatSetting.token' ), placeholder: ' ' },
320319 encoding_aes_key: {
321320 label: t (' views.application.applicationAccess.wechatSetting.aesKey' ),
322321 placeholder: ' ' ,
323322 },
324323 },
325324 dingtalk: {
326- client_id: {label: ' Client ID' , placeholder: ' ' },
327- client_secret: {label: ' Client Secret' , placeholder: ' ' },
325+ client_id: { label: ' Client ID' , placeholder: ' ' },
326+ client_secret: { label: ' Client Secret' , placeholder: ' ' },
328327 },
329328 wecom: {
330329 app_id: {
331330 label: t (' views.application.applicationAccess.wecomSetting.cropId' ),
332331 placeholder: ' ' ,
333332 },
334- agent_id: {label: ' Agent ID' , placeholder: ' ' },
335- secret: {label: ' Secret' , placeholder: ' ' },
336- token: {label: ' Token' , placeholder: ' ' },
337- encoding_aes_key: {label: ' EncodingAESKey' , placeholder: ' ' },
333+ agent_id: { label: ' Agent ID' , placeholder: ' ' },
334+ secret: { label: ' Secret' , placeholder: ' ' },
335+ token: { label: ' Token' , placeholder: ' ' },
336+ encoding_aes_key: { label: ' EncodingAESKey' , placeholder: ' ' },
338337 },
339338 wecomBot: {
340- token: {label: ' Token' , placeholder: ' ' },
341- encoding_aes_key: {label: ' EncodingAESKey' , placeholder: ' ' },
339+ token: { label: ' Token' , placeholder: ' ' },
340+ encoding_aes_key: { label: ' EncodingAESKey' , placeholder: ' ' },
342341 },
343342 lark: {
344- app_id: {label: ' App ID' , placeholder: ' ' },
345- app_secret: {label: ' App Secret' , placeholder: ' ' },
346- verification_token: {label: ' Verification Token' , placeholder: ' ' },
343+ app_id: { label: ' App ID' , placeholder: ' ' },
344+ app_secret: { label: ' App Secret' , placeholder: ' ' },
345+ verification_token: { label: ' Verification Token' , placeholder: ' ' },
347346 },
348347 slack: {
349- signing_secret: {label: ' Signing Secret' , placeholder: ' ' },
350- bot_user_token: {label: ' Bot User Token' , placeholder: ' ' },
348+ signing_secret: { label: ' Signing Secret' , placeholder: ' ' },
349+ bot_user_token: { label: ' Bot User Token' , placeholder: ' ' },
351350 },
352351}
353352
@@ -407,7 +406,7 @@ const submit = async () => {
407406 formRef .value ?.validate (async (valid ) => {
408407 if (valid ) {
409408 try {
410- loadSharedApi ({type: ' application' , systemType: apiType .value })
409+ loadSharedApi ({ type: ' application' , systemType: apiType .value })
411410 .updatePlatformConfig (id , configType .value , form [configType .value ], loading )
412411 .then (() => {
413412 MsgSuccess (t (' common.saveSuccess' ))
@@ -445,5 +444,5 @@ const open = async (id: string, type: PlatformType) => {
445444 }
446445}
447446
448- defineExpose ({open })
447+ defineExpose ({ open })
449448 </script >
0 commit comments