Skip to content

Commit 7dba06e

Browse files
fix: Advanced orchestration, adding applications, filtering oneself
1 parent f7623dc commit 7dba06e

File tree

7 files changed

+40
-36
lines changed

7 files changed

+40
-36
lines changed

ui/src/styles/component.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,7 @@
165165
border-radius: var(--el-border-radius-base) !important;
166166
padding: 5px 8px;
167167
font-weight: 400;
168+
color: var(--el-text-color-primary) !important;
168169
}
169170
.el-radio-button__original-radio:checked + .el-radio-button__inner {
170171
color: var(--el-color-primary) !important;

ui/src/views/application-workflow/component/DropdownMenu.vue

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -157,9 +157,6 @@ const apiType = computed(() => {
157157
const permissionPrecise = computed(() => {
158158
return permissionMap['tool'][apiType.value]
159159
})
160-
const isShared = computed(() => {
161-
return folder.currentFolder.id === 'share'
162-
})
163160
164161
const loading = ref(false)
165162
const activeName = ref('base')
@@ -278,7 +275,9 @@ async function getApplicationList() {
278275
}).getAllApplication({
279276
folder_id: folder.currentFolder?.id || user.getWorkspaceId(),
280277
})
281-
applicationList.value = res.data.filter((item: any) => item.resource_type === 'application')
278+
applicationList.value = res.data.filter(
279+
(item: any) => item.resource_type === 'application' && item.id !== props.id,
280+
)
282281
}
283282
284283
function folderClickHandle(row: any) {

ui/src/views/system-chat-user/authentication/component/CAS.vue

Lines changed: 32 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,7 @@
99
label-position="top"
1010
require-asterisk-position="right"
1111
>
12-
<el-form-item
13-
:label="$t('views.system.authentication.cas.ldpUri')"
14-
prop="config.ldpUri"
15-
>
12+
<el-form-item :label="$t('views.system.authentication.cas.ldpUri')" prop="config.ldpUri">
1613
<el-input
1714
v-model="form.config.ldpUri"
1815
:placeholder="$t('views.system.authentication.cas.ldpUriPlaceholder')"
@@ -38,18 +35,24 @@
3835
</el-form-item>
3936
<el-form-item>
4037
<el-checkbox v-model="form.is_active"
41-
>{{ $t('views.system.authentication.cas.enableAuthentication') }}
38+
>{{ $t('views.system.authentication.cas.enableAuthentication') }}
4239
</el-checkbox>
4340
</el-form-item>
4441
</el-form>
4542

46-
<div class="text-right">
47-
<el-button @click="submit(authFormRef)" type="primary" :disabled="loading"
48-
v-hasPermission="
49-
new ComplexPermission(
50-
[RoleConst.ADMIN],
51-
[PermissionConst.CHAT_USER_AUTH_EDIT],
52-
[],'OR',)"
43+
<div>
44+
<el-button
45+
@click="submit(authFormRef)"
46+
type="primary"
47+
:disabled="loading"
48+
v-hasPermission="
49+
new ComplexPermission(
50+
[RoleConst.ADMIN],
51+
[PermissionConst.CHAT_USER_AUTH_EDIT],
52+
[],
53+
'OR',
54+
)
55+
"
5356
>
5457
{{ $t('common.save') }}
5558
</el-button>
@@ -59,23 +62,23 @@
5962
</div>
6063
</template>
6164
<script setup lang="ts">
62-
import {reactive, ref, watch, onMounted} from 'vue'
65+
import { reactive, ref, watch, onMounted } from 'vue'
6366
import authApi from '@/api/chat-user/auth-setting'
64-
import type {FormInstance, FormRules} from 'element-plus'
65-
import {t} from '@/locales'
66-
import {MsgSuccess} from '@/utils/message'
67-
import {PermissionConst, RoleConst} from '@/utils/permission/data'
68-
import {ComplexPermission} from '@/utils/permission/type'
67+
import type { FormInstance, FormRules } from 'element-plus'
68+
import { t } from '@/locales'
69+
import { MsgSuccess } from '@/utils/message'
70+
import { PermissionConst, RoleConst } from '@/utils/permission/data'
71+
import { ComplexPermission } from '@/utils/permission/type'
6972
7073
const form = ref<any>({
7174
id: '',
7275
auth_type: 'CAS',
7376
config: {
7477
ldpUri: '',
7578
validateUrl: '',
76-
redirectUrl: ''
79+
redirectUrl: '',
7780
},
78-
is_active: true
81+
is_active: true,
7982
})
8083
8184
const authFormRef = ref()
@@ -87,23 +90,23 @@ const rules = reactive<FormRules<any>>({
8790
{
8891
required: true,
8992
message: t('views.system.authentication.cas.ldpUriPlaceholder'),
90-
trigger: 'blur'
91-
}
93+
trigger: 'blur',
94+
},
9295
],
9396
'config.validateUrl': [
9497
{
9598
required: true,
9699
message: t('views.system.authentication.cas.validateUrlPlaceholder'),
97-
trigger: 'blur'
98-
}
100+
trigger: 'blur',
101+
},
99102
],
100103
'config.redirectUrl': [
101104
{
102105
required: true,
103106
message: t('views.system.authentication.cas.redirectUrlPlaceholder'),
104-
trigger: 'blur'
105-
}
106-
]
107+
trigger: 'blur',
108+
},
109+
],
107110
})
108111
109112
const submit = async (formEl: FormInstance | undefined) => {
@@ -126,7 +129,8 @@ function getDetail() {
126129
form.value = res.data
127130
}
128131
if (!form.value.config.redirectUrl) {
129-
form.value.config.redirectUrl = window.location.origin + window.MaxKB.chatPrefix + '/api/auth/cas'
132+
form.value.config.redirectUrl =
133+
window.location.origin + window.MaxKB.chatPrefix + '/api/auth/cas'
130134
}
131135
})
132136
}

ui/src/views/system-chat-user/authentication/component/LDAP.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
</el-form-item>
6666
</el-form>
6767

68-
<div class="text-right">
68+
<div>
6969
<el-button @click="submit(authFormRef, 'test')" :disabled="loading">
7070
{{ $t('views.system.test') }}</el-button
7171
>

ui/src/views/system-chat-user/authentication/component/OAuth2.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@
8989
</el-form-item>
9090
</el-form>
9191

92-
<div class="text-right">
92+
<div>
9393
<el-button @click="submit(authFormRef)" type="primary" :disabled="loading"
9494
v-hasPermission="
9595
new ComplexPermission(

ui/src/views/system-chat-user/authentication/component/OIDC.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@
8686
</el-form-item>
8787
</el-form>
8888

89-
<div class="text-right">
89+
<div>
9090
<el-button @click="submit(authFormRef)" type="primary" :disabled="loading"
9191
v-hasPermission="
9292
new ComplexPermission(

ui/src/views/system-chat-user/authentication/component/SCAN.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
<div v-if="item.isValid" class="border-t mt-16">
3535
<el-row :gutter="12" class="mt-16">
3636
<el-col v-for="(value, key) in item.config" :key="key" :span="12">
37-
<el-text type="info">{{ formatFieldName(key, item) }}</el-text>
37+
<el-text type="info" class="lighter">{{ formatFieldName(key, item) }}</el-text>
3838
<div class="mt-4 mb-16 flex align-center">
3939
<span
4040
v-if="key !== 'app_secret'"

0 commit comments

Comments
 (0)