From d77bffddf598583a1a11ed8068d9df5bc2acdac2 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期三, 21 二月 2024 14:27:40 +0800
Subject: [PATCH] Merge branch 'master' into positec

---
 src/menu/components/carousel/data-card/options.jsx |   96 +++++++++++++++++++++++++++++++++++++++++++++++-
 1 files changed, 94 insertions(+), 2 deletions(-)

diff --git a/src/menu/components/carousel/data-card/options.jsx b/src/menu/components/carousel/data-card/options.jsx
index a770500..f7ba65c 100644
--- a/src/menu/components/carousel/data-card/options.jsx
+++ b/src/menu/components/carousel/data-card/options.jsx
@@ -4,6 +4,7 @@
 export default function (wrap, subtype) {
   let appType = sessionStorage.getItem('appType')
   let roleList = sessionStorage.getItem('sysRoles')
+  let ispop = sessionStorage.getItem('editMenuType') === 'popview'
 
   if (roleList) {
     try {
@@ -16,6 +17,13 @@
   }
 
   const cardWrapForm = [
+    {
+      type: 'text',
+      field: 'title',
+      label: '鏍囬',
+      initval: wrap.title || '',
+      required: false
+    },
     {
       type: 'text',
       field: 'name',
@@ -53,13 +61,73 @@
     },
     {
       type: 'radio',
+      field: 'display',
+      label: '鏄剧ず妯″紡',
+      initval: wrap.display || 'normal',
+      required: false,
+      options: [
+        {value: 'normal', label: '姝e父'},
+        {value: 'modal', label: '寮圭獥'},
+      ],
+      controlFields: [
+        {field: 'modalWidth', values: ['modal']},
+        {field: 'modalContent', values: ['modal']},
+        {field: 'code', values: ['modal']},
+      ]
+    },
+    {
+      type: 'radio',
+      field: 'modalContent',
+      label: '寮圭獥鍐呭',
+      initval: wrap.modalContent || 'message',
+      tooltip: '浣跨敤绯荤粺鏇存柊鏃讹紝濡傛灉杩斿洖鍊肩殑ErrCode涓�-1锛屽彧浼氬仛绯荤粺閰嶇疆鏇存柊涓嶄細鏄剧ず寮圭獥銆傛敞锛氭暟鎹簮浣跨敤鍚屾鏌ヨ鏃舵棤鏁堛��',
+      required: false,
+      options: [
+        {value: 'message', label: '娑堟伅鎻愰啋'},
+        {value: 'update', label: '绯荤粺鏇存柊'},
+      ]
+    },
+    {
+      type: 'styleInput',
+      field: 'height',
+      label: '缁勪欢楂樺害',
+      initval: wrap.height || '',
+      required: true,
+      options: ['px', 'vh']
+    },
+    {
+      type: 'styleInput',
+      field: 'modalWidth',
+      label: '寮圭獥瀹藉害',
+      initval: wrap.modalWidth || '300px',
+      required: true,
+      options: ['px', 'vw'],
+      forbid: appType === 'mob'
+    },
+    {
+      type: 'text',
+      field: 'code',
+      label: '娑堟伅缂栫爜',
+      initval: wrap.code || '',
+      tooltip: '鐢ㄤ簬璁板綍娑堟伅鏄惁宸茶鐨勬爣璇嗭紝濡傛灉涓嶅悓椤甸潰涓瓨鍦ㄧ浉鍚屾秷鎭紝鍙寚瀹氬浐瀹氬�笺��',
+      required: false,
+      rules: [{
+        pattern: /^[0-9a-zA-Z_]*$/ig,
+        message: '鍙厑璁稿寘鍚暟瀛椼�佸瓧姣嶄互鍙奯銆�'
+      }]
+    },
+    {
+      type: 'radio',
       field: 'autoplay',
       label: '鑷姩鍒囨崲',
       initval: wrap.autoplay || 'false',
       required: false,
       options: [
         {value: 'false', label: '鍚�'},
-        {value: 'true', label: '鏄�'},
+        {value: 'true', label: '鏄�'}
+      ],
+      controlFields: [
+        {field: 'speed', values: ['true']}
       ]
     },
     {
@@ -67,7 +135,7 @@
       field: 'speed',
       label: '鏃堕棿闂撮殧',
       initval: wrap.speed || 3,
-      tooltip: '浣跨敤鑷姩鍒囨崲鏃舵湁鏁堬紝榛樿涓�3绉�',
+      tooltip: '榛樿涓�3绉�',
       min: 1,
       max: 100,
       precision: 0,
@@ -136,6 +204,30 @@
       ],
     },
     {
+      type: 'radio',
+      field: 'permission',
+      label: '鏉冮檺楠岃瘉',
+      initval: wrap.permission || (!appType ? 'true' : 'false'),
+      required: false,
+      options: [
+        {value: 'true', label: !appType ? '缁ф壙鑿滃崟' : '鍚敤'},
+        {value: 'false', label: '绂佺敤'},
+      ],
+      forbid: ispop
+    },
+    {
+      type: 'radio',
+      field: 'cacheLocal',
+      label: '鏈湴缂撳瓨',
+      initval: wrap.cacheLocal || 'true',
+      required: false,
+      options: [
+        {value: 'true', label: '缁ф壙鑿滃崟'},
+        {value: 'false', label: '绂佺敤'},
+      ],
+      forbid: ispop
+    },
+    {
       type: 'multiselect',
       field: 'blacklist',
       label: '榛戝悕鍗�',

--
Gitblit v1.8.0