From 1febb373dcca833cba418e7c74b3d60720b953e9 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期四, 14 四月 2022 10:10:56 +0800
Subject: [PATCH] 2022-04-14

---
 public/options.json                                   |   14 +-
 src/mob/components/topbar/normal-navbar/options.jsx   |  141 ++++++++++++++++++++--------------
 src/components/normalform/modalform/index.scss        |    5 +
 src/mob/components/menubar/common-menubar/options.jsx |    4 
 src/mob/components/topbar/normal-navbar/index.jsx     |    8 ++
 src/tabviews/formtab/index.jsx                        |   18 ++--
 src/views/mobdesign/menuform/index.jsx                |    7 +
 src/menu/popview/index.jsx                            |   17 ++-
 src/menu/replaceField/index.jsx                       |    2 
 9 files changed, 131 insertions(+), 85 deletions(-)

diff --git a/public/options.json b/public/options.json
index fa76f1c..f5f2215 100644
--- a/public/options.json
+++ b/public/options.json
@@ -1,18 +1,18 @@
 {
-  "appId": "201912040924165801464FF1788654BC5AC73",
-  "appkey": "20191106103859640976D6E924E464D029CF0",
+  "appId": "202108312122504607B107A83F55B40C98CCF",
+  "appkey": "20210831212235413F287EC3BF489424496C8",
   "mainSystemApi": "http://sso.mk9h.cn/cloud/webapi/dostars",
   "systemType": "",
   "externalDatabase": "false",
   "lineColor": "",
   "filter": "false",
-  "defaultApp": "mk",
+  "defaultApp": "mkindustry",
   "defaultLang": "zh-CN",
   "WXAppID": "",
   "debugger": false,
-  "licenseKey": "",
-  "probation": "",
+  "licenseKey": "7EFE13KIKLILIJB64C12",
+  "probation": "2021-12-31",
   "keepPassword": "true",
-  "host": "http://qingqiumarket.cn",
-  "service": "MKWMS/"
+  "host": "http://demo.mk9h.cn",
+  "service": "erp_new/"
 }
\ No newline at end of file
diff --git a/src/components/normalform/modalform/index.scss b/src/components/normalform/modalform/index.scss
index 2d38c93..4bd743d 100644
--- a/src/components/normalform/modalform/index.scss
+++ b/src/components/normalform/modalform/index.scss
@@ -57,4 +57,9 @@
       width: 16%;
     }
   }
+  .ant-col-12 + .ant-col-24 + .ant-col-24 {
+    .ant-form-item-label {
+      width: 16%;
+    }
+  }
 }
\ No newline at end of file
diff --git a/src/menu/popview/index.jsx b/src/menu/popview/index.jsx
index 7e90b9a..e820385 100644
--- a/src/menu/popview/index.jsx
+++ b/src/menu/popview/index.jsx
@@ -46,7 +46,8 @@
     menuloading: false,
     oriConfig: null,
     config: null,
-    customComponents: []
+    customComponents: [],
+    comloading: false
   }
 
   UNSAFE_componentWillMount() {
@@ -133,10 +134,11 @@
     })
 
     this.setState({
-      config: {...config, components: []}
+      config: {...config, components},
+      comloading: true
     }, () => {
       this.setState({
-        config: {...config, components: components}
+        comloading: false
       })
     })
   }
@@ -577,10 +579,11 @@
 
   resetConfig = (config) => {
     this.setState({
-      config: {...config, components: []},
+      config,
+      comloading: true
     }, () => {
       this.setState({
-        config: config
+        comloading: false
       })
     })
 
@@ -625,7 +628,7 @@
 
   render () {
     const { btn } = this.props
-    const { activeKey, dict, config, menuloading, customComponents, MenuId } = this.state
+    const { activeKey, comloading, dict, config, menuloading, customComponents, MenuId } = this.state
 
     return (
       <div className="pc-poper-view">
@@ -670,7 +673,7 @@
                   <Button type="default" onClick={this.closeView}>{dict['mob.return']}</Button>
                 </div>
               } style={{ width: '100%' }}>
-                {config && config.components ? <MenuShell menu={config} handleList={this.updateConfig} /> : null}
+                {config && !comloading ? <MenuShell menu={config} handleList={this.updateConfig} /> : null}
               </Card>
             </div>
           </div>
diff --git a/src/menu/replaceField/index.jsx b/src/menu/replaceField/index.jsx
index 0fce450..81e4921 100644
--- a/src/menu/replaceField/index.jsx
+++ b/src/menu/replaceField/index.jsx
@@ -446,7 +446,7 @@
 
     setTimeout(() => {
       MKEmitter.emit('revert')
-    }, 500)
+    }, 300)
   }
 
   execLabel = (map) => {
diff --git a/src/mob/components/menubar/common-menubar/options.jsx b/src/mob/components/menubar/common-menubar/options.jsx
index aea9633..65029fe 100644
--- a/src/mob/components/menubar/common-menubar/options.jsx
+++ b/src/mob/components/menubar/common-menubar/options.jsx
@@ -32,9 +32,9 @@
     {
       type: 'number',
       field: 'maxcount',
-      label: '鏄剧ず鏁伴噺',
+      label: '鑿滃崟鏁�',
       initval: wrap.maxcount || '',
-      tooltip: '鏈�澶ф樉绀烘暟閲忥紝绌烘椂涓嶅仛闄愬埗銆�',
+      tooltip: '鑿滃崟鐨勬渶澶ф樉绀烘暟閲忥紝绌烘椂涓嶅仛闄愬埗銆�',
       min: 1,
       max: 9999,
       precision: 0,
diff --git a/src/mob/components/topbar/normal-navbar/index.jsx b/src/mob/components/topbar/normal-navbar/index.jsx
index 7d3e599..b8ece4c 100644
--- a/src/mob/components/topbar/normal-navbar/index.jsx
+++ b/src/mob/components/topbar/normal-navbar/index.jsx
@@ -175,6 +175,14 @@
   }
 
   updateWrap = (res) => {
+    let funs = res.funs || []
+
+    delete res.funs
+
+    funs.forEach(n => {
+      res[n] = 'true'
+    })
+
     this.updateComponent({...this.state.card, wrap: res})
   }
 
diff --git a/src/mob/components/topbar/normal-navbar/options.jsx b/src/mob/components/topbar/normal-navbar/options.jsx
index e47a66d..5a016d9 100644
--- a/src/mob/components/topbar/normal-navbar/options.jsx
+++ b/src/mob/components/topbar/normal-navbar/options.jsx
@@ -23,6 +23,21 @@
     menulist = []
   }
 
+  let funs = []
+
+  if (wrap.back === 'true') {
+    funs.push('back')
+  }
+  if (wrap.logout === 'true') {
+    funs.push('logout')
+  }
+  if (wrap.scan === 'true') {
+    funs.push('scan')
+  }
+  if (wrap.refresh === 'true') {
+    funs.push('refresh')
+  }
+
   const topbarWrapForm = [
     {
       type: 'radio',
@@ -61,67 +76,86 @@
     },
     {
       type: 'radio',
-      field: 'back',
-      label: '杩斿洖',
-      initval: wrap.back || 'true',
+      field: 'mode',
+      label: '寮规鑳屾櫙',
+      initval: wrap.mode || 'dark',
       required: false,
       options: [
-        {value: 'true', label: '鏄剧ず'},
-        {value: 'false', label: '闅愯棌'},
+        {value: 'light', label: '鐧借壊'},
+        {value: 'dark', label: '榛戣壊'},
+      ]
+    },
+    {
+      type: 'checkbox',
+      field: 'funs',
+      label: '鎵╁睍鍔熻兘',
+      tooltip: '1銆佽繑鍥炰笂涓�椤碉紱2銆佺粦瀹氬叕浼楀彿鍚庡彲鍒嗕韩褰撳墠椤甸潰锛�3銆佷簩缁寸爜浠モ�渓ogin鈥濆紑澶存椂涓烘壂鐮佺櫥褰曪紝浜岀淮鐮佷互鈥渉ttp鈥濆紑澶翠负椤甸潰璺宠浆锛屼簩缁寸爜浠モ�渕kbid鈥濆紑澶翠负鑿滃崟璺宠浆锛屼笖璁剧疆鏈夊叧鑱旇彍鍗曪紱4銆佸綋鍓嶉〉闈㈠埛鏂帮紱5銆侀��鍑虹郴缁燂紝杩斿洖绗竴涓〉闈€��',
+      initval: funs,
+      required: false,
+      options: [
+        {value: 'back', label: '杩斿洖'},
+        {value: 'scan', label: '鎵竴鎵�'},
+        {value: 'refresh', label: '鍒锋柊'},
+        {value: 'logout', label: '閫�鍑�'},
       ],
       controlFields: [
-        {field: 'reload', values: ['true']},
-      ]
+        {field: 'reload', values: ['back']},
+        {field: 'linkmenu', values: ['scan']},
+      ],
+      span: 24
     },
     // {
     //   type: 'radio',
-    //   field: 'search',
-    //   label: '鎼滅储',
-    //   initval: wrap.search || 'false',
+    //   field: 'back',
+    //   label: '杩斿洖',
+    //   initval: wrap.back || 'true',
+    //   required: false,
+    //   options: [
+    //     {value: 'true', label: '鏄剧ず'},
+    //     {value: 'false', label: '闅愯棌'},
+    //   ],
+    //   controlFields: [
+    //     {field: 'reload', values: ['true']},
+    //   ]
+    // },
+    // {
+    //   type: 'radio',
+    //   field: 'logout',
+    //   label: '閫�鍑�',
+    //   initval: wrap.logout || 'false',
+    //   tooltip: '鐐瑰嚮閫�鍑烘椂锛岃繑鍥炵涓�涓〉闈€��',
     //   required: false,
     //   options: [
     //     {value: 'true', label: '鏄剧ず'},
     //     {value: 'false', label: '闅愯棌'},
     //   ]
     // },
-    {
-      type: 'radio',
-      field: 'logout',
-      label: '閫�鍑�',
-      initval: wrap.logout || 'false',
-      tooltip: '鐐瑰嚮閫�鍑烘椂锛岃繑鍥炵涓�涓〉闈€��',
-      required: false,
-      options: [
-        {value: 'true', label: '鏄剧ず'},
-        {value: 'false', label: '闅愯棌'},
-      ]
-    },
-    {
-      type: 'radio',
-      field: 'scan',
-      label: '鎵竴鎵�',
-      initval: wrap.scan || 'false',
-      tooltip: '绯荤粺鍔熻兘锛�1銆佹壂鐮佺櫥褰曪紝浜岀淮鐮佷互鈥渓ogin鈥濆紑澶达紝2銆侀〉闈㈣烦杞紝浜岀淮鐮佷互鈥渉ttp鈥濆紑澶达紝3銆佽彍鍗曡烦杞紝浜岀淮鐮佷互鈥渕kbid鈥濆紑澶达紝涓旇缃叧鑱旇彍鍗�',
-      required: false,
-      options: [
-        {value: 'true', label: '鏄剧ず'},
-        {value: 'false', label: '闅愯棌'},
-      ],
-      controlFields: [
-        {field: 'linkmenu', values: ['true']},
-      ]
-    },
-    {
-      type: 'radio',
-      field: 'refresh',
-      label: '鍒锋柊',
-      initval: wrap.refresh || 'false',
-      required: false,
-      options: [
-        {value: 'true', label: '鏄剧ず'},
-        {value: 'false', label: '闅愯棌'},
-      ]
-    },
+    // {
+    //   type: 'radio',
+    //   field: 'scan',
+    //   label: '鎵竴鎵�',
+    //   initval: wrap.scan || 'false',
+    //   tooltip: '绯荤粺鍔熻兘锛�1銆佹壂鐮佺櫥褰曪紝浜岀淮鐮佷互鈥渓ogin鈥濆紑澶达紝2銆侀〉闈㈣烦杞紝浜岀淮鐮佷互鈥渉ttp鈥濆紑澶达紝3銆佽彍鍗曡烦杞紝浜岀淮鐮佷互鈥渕kbid鈥濆紑澶达紝涓旇缃叧鑱旇彍鍗�',
+    //   required: false,
+    //   options: [
+    //     {value: 'true', label: '鏄剧ず'},
+    //     {value: 'false', label: '闅愯棌'},
+    //   ],
+    //   controlFields: [
+    //     {field: 'linkmenu', values: ['true']},
+    //   ]
+    // },
+    // {
+    //   type: 'radio',
+    //   field: 'refresh',
+    //   label: '鍒锋柊',
+    //   initval: wrap.refresh || 'false',
+    //   required: false,
+    //   options: [
+    //     {value: 'true', label: '鏄剧ず'},
+    //     {value: 'false', label: '闅愯棌'},
+    //   ]
+    // },
     {
       type: 'radio',
       field: 'reload',
@@ -136,17 +170,6 @@
         value: 'true',
         label: '鍒锋柊'
       }]
-    },
-    {
-      type: 'radio',
-      field: 'mode',
-      label: '寮规鑳屾櫙',
-      initval: wrap.mode || 'dark',
-      required: false,
-      options: [
-        {value: 'light', label: '鐧借壊'},
-        {value: 'dark', label: '榛戣壊'},
-      ]
     },
     {
       type: 'select',
diff --git a/src/tabviews/formtab/index.jsx b/src/tabviews/formtab/index.jsx
index b16b3c7..719ade8 100644
--- a/src/tabviews/formtab/index.jsx
+++ b/src/tabviews/formtab/index.jsx
@@ -103,15 +103,17 @@
         config.tabgroups = _tabgroups
       }
 
-      config.action = config.action.filter(item => permAction[item.uuid])
-      config.tabgroups.forEach(group => {
-        group.sublist = group.sublist.filter(tab => {
-          if (tab.supMenu === 'mainTable') {
-            tab.supMenu = MenuID
-          }
-          return permAction[tab.linkTab]
+      if (this.props.menuType !== 'HS') {
+        config.action = config.action.filter(item => permAction[item.uuid])
+        config.tabgroups.forEach(group => {
+          group.sublist = group.sublist.filter(tab => {
+            if (tab.supMenu === 'mainTable') {
+              tab.supMenu = MenuID
+            }
+            return permAction[tab.linkTab]
+          })
         })
-      })
+      }
 
       // 鎸夐挳绫诲瀷鍏煎
       config.action = config.action.map(item => {
diff --git a/src/views/mobdesign/menuform/index.jsx b/src/views/mobdesign/menuform/index.jsx
index 79c4909..4478d02 100644
--- a/src/views/mobdesign/menuform/index.jsx
+++ b/src/views/mobdesign/menuform/index.jsx
@@ -221,7 +221,12 @@
             </Form.Item>
           </Col> : null}
           {adapters.includes('app') && config.advertUrl ? <Col span={24}>
-            <Form.Item label="鍋滅暀(s)">
+            <Form.Item label={
+              <Tooltip placement="topLeft" title="骞垮憡椤电殑鍋滅暀鏃堕棿銆�">
+                <QuestionCircleOutlined className="mk-form-tip" />
+                鍋滅暀(s)
+              </Tooltip>
+            }>
               {getFieldDecorator('advertTime', {
                 initialValue: config.advertTime || 3,
                 rules: [

--
Gitblit v1.8.0