From f2e4a9d500d2ae2a0ca0fe9ff8cb050c90ccaa2e Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Fri, 05 Jan 2024 18:02:00 +0800
Subject: [PATCH] 所有图片字段需要调整

---
 src/views/article/rotation.vue |   55 +++++++++++++++++++++++++++++++++++++++++++++++++++----
 1 files changed, 51 insertions(+), 4 deletions(-)

diff --git a/src/views/article/rotation.vue b/src/views/article/rotation.vue
index 8af2bfd..6194d08 100644
--- a/src/views/article/rotation.vue
+++ b/src/views/article/rotation.vue
@@ -57,17 +57,56 @@
                         search: true,
                     },
                     {
-                        label: "跳转地址",
-                        prop: "junpUrl",
+                        label: "类型",
+                        prop: "type",
                         span: 12,
                         searchSpan: 4,
                         search: true,
+                        type: "select",
+                        dicData: [
+                            {
+                                label: "系统",
+                                value: "1"
+                            },
+                            {
+                                label: "社区",
+                                value: "2"
+                            }
+                        ]
                     },
                     {
+                        width: 156,
+                        overHidden: true,
+                        label: "所属社区",
+                        parent: false,
+                        prop: "communityCode",
+                        search: true,
+                        searchSpan: 4,
+                        searchType: 'input',
+                        type: "tree",
+                        dicUrl: "/api/blade-system/region/tree",
+                        props: {
+                            label: "name",
+                            value: "id"
+                        },
+                        rules: [
+                            {
+                                required: true,
+                                message: "请选择所属社区",
+                                trigger: "blur",
+                            },
+                        ],
+                    },
+                    {
+                        label: "跳转地址",
+                        prop: "junpUrl",
+                        span: 12,
+                    },
+                    {
+                        width: 110,
                         label: "图片",
                         prop: "url",
                         type: "upload",
-                        width: 80,
                         listType: "picture-img",
                         action: "/api/blade-resource/oss/endpoint/put-file",
                         propsHttp: {
@@ -246,7 +285,7 @@
             this.onLoad(this.page, this.query)
         },
         onLoad (page, params = {}) {
-            const { dateTime } = this.query
+            const { dateTime, communityCode } = this.query
             let values = {
                 ...params,
             }
@@ -259,6 +298,14 @@
                 }
                 values.dateTime = null
             }
+            if (communityCode) {
+                values = {
+                    ...values,
+                    communityName: communityCode
+                }
+
+                delete values.communityCode
+            }
             this.loading = true
             getList(page.currentPage, page.pageSize, values).then((res) => {
                 const data = res.data.data

--
Gitblit v1.9.3