From a3dca2e61afd9f0966753d7b8c551c1fd5f4e9d7 Mon Sep 17 00:00:00 2001 From: heshunme Date: Sat, 6 Jul 2024 01:53:47 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E4=BA=86=E4=B8=BA=E8=B6=85?= =?UTF-8?q?=E7=BA=A7=E7=AE=A1=E7=90=86=E5=91=98=E5=8A=A8=E6=80=81=E5=8A=A0?= =?UTF-8?q?=E8=BD=BD=E7=A7=9F=E6=88=B7=E9=80=89=E9=A1=B9=E7=9A=84=E5=8A=9F?= =?UTF-8?q?=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/news-management/EditNews.vue | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/src/views/news-management/EditNews.vue b/src/views/news-management/EditNews.vue index ed5da23..bfb5043 100644 --- a/src/views/news-management/EditNews.vue +++ b/src/views/news-management/EditNews.vue @@ -87,6 +87,8 @@ const props = defineProps({ const containerStyle = ref('form-container') const emit = defineEmits(['setNewsDialogInvisible']); + +const options = ref([]) const setNewsDialogInvisible = (changed) => { emit('setNewsDialogInvisible', changed); }; @@ -204,6 +206,18 @@ const fetchNewsDetail = async () => { fileList.value.push({url: res.data.imagePath}); } +const fetchOptions = async () => { + const params = { + token: token.value, + } + try{ + const res = await axios.get('/api/tenant/getTenantOptions',{params}); + options.value = res.data.options; + } catch (e) { + await ElMessageBox.alert(e.response.data.message); + } +} + onMounted(() => { token.value = store.getters['authentication/token']; form.value.token = token.value; @@ -231,6 +245,8 @@ onMounted(() => { fetchNewsDetail(); } + fetchOptions() + config.value = { toolbar: { items: [ @@ -489,9 +505,12 @@ onMounted(() => { - - - +