feat(系统设置): 自定义机器人非xpack
This commit is contained in:
parent
29eb6ca709
commit
7a4ed691f6
|
@ -161,29 +161,6 @@ public class FunctionalCaseMinderService {
|
|||
return customFields.stream().map(TemplateCustomFieldDTO::getFieldId).toList();
|
||||
}
|
||||
|
||||
private List<FunctionalMinderTreeDTO> buildAdditionalData(String moduleId) {
|
||||
List<FunctionalMinderTreeDTO> list = new ArrayList<>();
|
||||
MindAdditionalNodeExample mindAdditionalNodeExample = new MindAdditionalNodeExample();
|
||||
mindAdditionalNodeExample.createCriteria().andParentIdEqualTo(moduleId);
|
||||
mindAdditionalNodeExample.setOrderByClause("pos asc");
|
||||
List<MindAdditionalNode> mindAdditionalNodes = mindAdditionalNodeMapper.selectByExample(mindAdditionalNodeExample);
|
||||
if (CollectionUtils.isEmpty(mindAdditionalNodes)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
for (MindAdditionalNode mindAdditionalNode : mindAdditionalNodes) {
|
||||
FunctionalMinderTreeDTO root = new FunctionalMinderTreeDTO();
|
||||
FunctionalMinderTreeNodeDTO rootData = new FunctionalMinderTreeNodeDTO();
|
||||
rootData.setId(mindAdditionalNode.getId());
|
||||
rootData.setPos(mindAdditionalNode.getPos());
|
||||
rootData.setText(mindAdditionalNode.getName());
|
||||
rootData.setResource(new ArrayList<>());
|
||||
root.setChildren(buildAdditionalData(mindAdditionalNode.getId()));
|
||||
root.setData(rootData);
|
||||
list.add(root);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
private void buildList(List<FunctionalCaseMindDTO> functionalCaseMindDTOList, List<FunctionalMinderTreeDTO> list, Map<String, String> priorityMap) {
|
||||
//构造父子级数据
|
||||
for (FunctionalCaseMindDTO functionalCaseMindDTO : functionalCaseMindDTOList) {
|
||||
|
|
|
@ -212,8 +212,10 @@
|
|||
const unReadCount = ref<number>(0);
|
||||
|
||||
async function checkMessageRead() {
|
||||
if (appStore.currentProjectId) {
|
||||
unReadCount.value = await getMessageUnReadCount(appStore.currentProjectId);
|
||||
}
|
||||
}
|
||||
watch(
|
||||
() => appStore.currentOrgId,
|
||||
async () => {
|
||||
|
|
|
@ -130,7 +130,6 @@
|
|||
{{ platform.name }}
|
||||
</div>
|
||||
<div
|
||||
v-xpack
|
||||
:class="['platform-card-custom', robotForm.platform === 'CUSTOM' ? 'platform-card--active' : '']"
|
||||
@click="robotForm.platform = 'CUSTOM'"
|
||||
>
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
{{ t('project.messageManagement.DING_TALK') }}
|
||||
</template>
|
||||
|
||||
<a-form class="ms-form rounded-[4px]" :model="dingTalkForm" layout="vertical">
|
||||
<a-form ref="dingTalkFormRef" class="ms-form rounded-[4px]" :model="dingTalkForm" layout="vertical">
|
||||
<a-form-item
|
||||
field="appKey"
|
||||
:label="t('system.config.qrCodeConfig.appKey')"
|
||||
|
@ -82,6 +82,7 @@
|
|||
|
||||
<script setup lang="ts">
|
||||
import { ref } from 'vue';
|
||||
import { FormInstance, ValidatedError } from '@arco-design/web-vue';
|
||||
|
||||
import { getDingInfo, saveDingTalkConfig, validateDingTalkConfig } from '@/api/modules/setting/qrCode';
|
||||
import { useI18n } from '@/hooks/useI18n';
|
||||
|
@ -100,6 +101,8 @@
|
|||
valid: false,
|
||||
});
|
||||
|
||||
const dingTalkFormRef = ref<FormInstance | null>(null);
|
||||
|
||||
const loading = ref<boolean>(false);
|
||||
const detailVisible = ref<boolean>(false);
|
||||
const props = defineProps<{
|
||||
|
@ -140,6 +143,8 @@
|
|||
}
|
||||
|
||||
async function validateInfo() {
|
||||
dingTalkFormRef.value?.validate(async (errors: Record<string, ValidatedError> | undefined) => {
|
||||
if (!errors) {
|
||||
loading.value = true;
|
||||
try {
|
||||
await validateDingTalkConfig(dingTalkForm.value);
|
||||
|
@ -151,8 +156,12 @@
|
|||
loading.value = false;
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
async function saveInfo() {
|
||||
dingTalkFormRef.value?.validate(async (errors: Record<string, ValidatedError> | undefined) => {
|
||||
if (!errors) {
|
||||
loading.value = true;
|
||||
try {
|
||||
await saveDingTalkConfig(dingTalkForm.value);
|
||||
|
@ -165,6 +174,8 @@
|
|||
detailVisible.value = false;
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
{{ t('project.messageManagement.WE_COM') }}
|
||||
</template>
|
||||
|
||||
<a-form class="ms-form rounded-[4px]" :model="weComForm" layout="vertical">
|
||||
<a-form ref="weComFormRef" class="ms-form rounded-[4px]" :model="weComForm" layout="vertical">
|
||||
<a-form-item
|
||||
field="corpId"
|
||||
:label="t('system.config.qrCodeConfig.corpId')"
|
||||
|
@ -79,6 +79,7 @@
|
|||
|
||||
<script setup lang="ts">
|
||||
import { ref } from 'vue';
|
||||
import { FormInstance, ValidatedError } from '@arco-design/web-vue';
|
||||
|
||||
import { getWeComInfo, saveWeComConfig, validateWeComConfig } from '@/api/modules/setting/qrCode';
|
||||
import { useI18n } from '@/hooks/useI18n';
|
||||
|
@ -97,6 +98,8 @@
|
|||
valid: false,
|
||||
});
|
||||
|
||||
const weComFormRef = ref<FormInstance | null>(null);
|
||||
|
||||
const emits = defineEmits<{
|
||||
(event: 'update:visible', visible: boolean): void;
|
||||
(event: 'success'): void;
|
||||
|
@ -137,6 +140,8 @@
|
|||
}
|
||||
|
||||
async function validateInfo() {
|
||||
weComFormRef.value?.validate(async (errors: Record<string, ValidatedError> | undefined) => {
|
||||
if (!errors) {
|
||||
loading.value = true;
|
||||
try {
|
||||
await validateWeComConfig(weComForm.value);
|
||||
|
@ -148,8 +153,12 @@
|
|||
loading.value = false;
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
async function saveInfo() {
|
||||
weComFormRef.value?.validate(async (errors: Record<string, ValidatedError> | undefined) => {
|
||||
if (!errors) {
|
||||
loading.value = true;
|
||||
try {
|
||||
await saveWeComConfig(weComForm.value);
|
||||
|
@ -162,6 +171,8 @@
|
|||
detailVisible.value = false;
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
|
|
Loading…
Reference in New Issue