mirror of
https://github.com/m-xlsea/ruoyi-plus-soybean.git
synced 2025-09-24 07:49:47 +08:00
Merge branch 'dev' into flow
This commit is contained in:
@ -31,7 +31,7 @@ const processResponse = async () => {
|
||||
msg.value = '登录成功,1s 后即将跳转至首页';
|
||||
}, 1000);
|
||||
setTimeout(() => {
|
||||
routerPushByKey('home');
|
||||
routerPushByKey(import.meta.env.VITE_ROUTE_HOME || 'home');
|
||||
}, 1000);
|
||||
};
|
||||
|
||||
|
@ -1,12 +1,7 @@
|
||||
<script setup lang="ts">
|
||||
import { computed, reactive, watch } from 'vue';
|
||||
import { Tinymce } from '@sa/tinymce';
|
||||
import { fetchCreateNotice, fetchUpdateNotice } from '@/service/api/system/notice';
|
||||
import { getToken } from '@/store/modules/auth/shared';
|
||||
import { useAppStore } from '@/store/modules/app';
|
||||
import { useThemeStore } from '@/store/modules/theme';
|
||||
import { useFormRules, useNaiveForm } from '@/hooks/common/form';
|
||||
import { getServiceBaseURL } from '@/utils/service';
|
||||
import { $t } from '@/locales';
|
||||
|
||||
defineOptions({
|
||||
@ -32,17 +27,6 @@ const visible = defineModel<boolean>('visible', {
|
||||
default: false
|
||||
});
|
||||
|
||||
const appStore = useAppStore();
|
||||
const themeStore = useThemeStore();
|
||||
|
||||
const isHttpProxy = import.meta.env.DEV && import.meta.env.VITE_HTTP_PROXY === 'Y';
|
||||
const { baseURL } = getServiceBaseURL(import.meta.env, isHttpProxy);
|
||||
|
||||
const headers: Record<string, string> = {
|
||||
Authorization: `Bearer ${getToken()}`,
|
||||
clientid: import.meta.env.VITE_APP_CLIENT_ID!
|
||||
};
|
||||
|
||||
const { formRef, validate, restoreValidation } = useNaiveForm();
|
||||
const { createRequiredRule } = useFormRules();
|
||||
|
||||
@ -139,13 +123,7 @@ watch(visible, () => {
|
||||
<DictRadio v-model:value="model.noticeType" dict-code="sys_notice_type" />
|
||||
</NFormItem>
|
||||
<NFormItem label="公告内容" path="noticeContent">
|
||||
<Tinymce
|
||||
v-model="model.noticeContent"
|
||||
:lang="appStore.locale"
|
||||
:is-dark="themeStore.darkMode"
|
||||
:upload-url="`${baseURL}/resource/oss/upload`"
|
||||
:upload-headers="headers"
|
||||
/>
|
||||
<TinymceEditor v-model:value="model.noticeContent" />
|
||||
</NFormItem>
|
||||
<NFormItem label="公告状态" path="status">
|
||||
<DictRadio v-model:value="model.status" dict-code="sys_normal_disable" />
|
||||
|
Reference in New Issue
Block a user