From b63b085814103cabe989d9600bc925559cc6d56d Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期三, 13 四月 2022 01:29:21 +0800
Subject: [PATCH] 2022-04-13

---
 src/assets/mobimg/commonbar.png                                   |    0 
 src/index.js                                                      |    7 
 src/tabviews/custom/components/card/cardcellList/index.jsx        |    4 
 src/mob/components/menubar/normal-menubar/menucomponent/index.jsx |    4 
 src/menu/components/card/data-card/options.jsx                    |   77 +++++++
 src/mob/components/menubar/normal-menubar/index.jsx               |   14 -
 src/menu/components/card/cardcellcomponent/elementform/index.jsx  |    5 
 src/mob/modulesource/option.jsx                                   |    2 
 public/options.json                                               |   14 
 src/menu/components/card/cardcellcomponent/formconfig.jsx         |   10 +
 src/mob/components/menubar/common-menubar/options.jsx             |   83 ++++++++
 src/mob/components/menubar/normal-menubar/options.jsx             |   12 +
 src/mob/components/menubar/common-menubar/index.jsx               |  190 +++++++++++++++++++
 src/mob/components/menubar/common-menubar/index.scss              |   98 +++++++++
 src/views/mobdesign/index.jsx                                     |   10 
 src/mob/mobshell/card.jsx                                         |    5 
 src/views/login/index.jsx                                         |   14 
 17 files changed, 511 insertions(+), 38 deletions(-)

diff --git a/public/options.json b/public/options.json
index f5f2215..fa76f1c 100644
--- a/public/options.json
+++ b/public/options.json
@@ -1,18 +1,18 @@
 {
-  "appId": "202108312122504607B107A83F55B40C98CCF",
-  "appkey": "20210831212235413F287EC3BF489424496C8",
+  "appId": "201912040924165801464FF1788654BC5AC73",
+  "appkey": "20191106103859640976D6E924E464D029CF0",
   "mainSystemApi": "http://sso.mk9h.cn/cloud/webapi/dostars",
   "systemType": "",
   "externalDatabase": "false",
   "lineColor": "",
   "filter": "false",
-  "defaultApp": "mkindustry",
+  "defaultApp": "mk",
   "defaultLang": "zh-CN",
   "WXAppID": "",
   "debugger": false,
-  "licenseKey": "7EFE13KIKLILIJB64C12",
-  "probation": "2021-12-31",
+  "licenseKey": "",
+  "probation": "",
   "keepPassword": "true",
-  "host": "http://demo.mk9h.cn",
-  "service": "erp_new/"
+  "host": "http://qingqiumarket.cn",
+  "service": "MKWMS/"
 }
\ No newline at end of file
diff --git a/src/assets/mobimg/commonbar.png b/src/assets/mobimg/commonbar.png
new file mode 100644
index 0000000..9b0822f
--- /dev/null
+++ b/src/assets/mobimg/commonbar.png
Binary files differ
diff --git a/src/index.js b/src/index.js
index 601a715..65b760a 100644
--- a/src/index.js
+++ b/src/index.js
@@ -176,6 +176,13 @@
       }
     }
 
+    if (/^https/.test(window.location.protocol)) { // https杞崲
+      let meta = document.createElement('meta')
+      meta.content = 'upgrade-insecure-requests'
+      meta.httpEquiv = 'Content-Security-Policy'
+      document.getElementsByTagName('head')[0].appendChild(meta)
+    }
+
     document.title = GLOB.platTitle || ''
 
     if (config.filter === 'true' || (/^20\d{2}-\d{2}-\d{2}$/.test(config.filter) && new Date(config.filter).getTime() + 86400000 >= new Date().getTime())) {
diff --git a/src/menu/components/card/cardcellcomponent/elementform/index.jsx b/src/menu/components/card/cardcellcomponent/elementform/index.jsx
index 1aaec05..8495d20 100644
--- a/src/menu/components/card/cardcellcomponent/elementform/index.jsx
+++ b/src/menu/components/card/cardcellcomponent/elementform/index.jsx
@@ -15,7 +15,7 @@
 
 const cardTypeOptions = {
   sequence: ['eleType', 'width'],
-  text: ['eleType', 'datatype', 'format', 'width', 'height', 'prefix', 'postfix', 'link', 'noValue'],
+  text: ['eleType', 'datatype', 'format', 'width', 'height', 'prefix', 'postfix', 'link', 'noValue', 'bgImage'],
   number: ['eleType', 'datatype', 'format', 'width', 'height', 'prefix', 'postfix', 'noValue'],
   picture: ['eleType', 'datatype', 'width', 'lenWidRadio', 'maxWidth', 'link', 'noValue'],
   video: ['eleType', 'datatype', 'width', 'aspectRatio', 'autoPlay', 'loop', 'noValue'],
@@ -59,7 +59,7 @@
       formlist: this.props.formlist.map(item => {
         item.hidden = !_options.includes(item.key)
 
-        if (item.key === 'field' || item.key === 'linkurl') {
+        if (item.key === 'field' || item.key === 'linkurl' || item.key === 'bgImage') {
           item.options = []
           config.columns.forEach(col => {
             let label = col.label
@@ -389,6 +389,7 @@
               })(
                 <Select
                   showSearch
+                  allowClear={item.allowClear || false}
                   filterOption={(input, option) => option.props.children.toLowerCase().indexOf(input.toLowerCase()) >= 0}
                   onChange={(value, option) => {this.selectChange(item.key, value, option)}}
                   getPopupContainer={() => document.getElementById('card-winter')}
diff --git a/src/menu/components/card/cardcellcomponent/formconfig.jsx b/src/menu/components/card/cardcellcomponent/formconfig.jsx
index 498c1c4..48c492b 100644
--- a/src/menu/components/card/cardcellcomponent/formconfig.jsx
+++ b/src/menu/components/card/cardcellcomponent/formconfig.jsx
@@ -313,6 +313,16 @@
       required: false
     },
     {
+      type: 'select',
+      key: 'bgImage',
+      label: '鍔ㄦ�佽儗鏅�',
+      initVal: card.bgImage || '',
+      tooltip: '缁戝畾鏁版嵁婧愬瓧娈碉紝鍙牴鎹繑鍥炲�兼敼鍙樿儗鏅浘銆�',
+      required: false,
+      allowClear: true,
+      options: []
+    },
+    {
       type: 'number',
       key: 'barHeight',
       min: 5,
diff --git a/src/menu/components/card/data-card/options.jsx b/src/menu/components/card/data-card/options.jsx
index 9001f8b..01a1f13 100644
--- a/src/menu/components/card/data-card/options.jsx
+++ b/src/menu/components/card/data-card/options.jsx
@@ -29,6 +29,21 @@
     roleList = []
   }
 
+  let menulist = []
+
+  if (appType === 'mob') {
+    menulist = sessionStorage.getItem('appMenus')
+    if (menulist) {
+      try {
+        menulist = JSON.parse(menulist)
+      } catch (e) {
+        menulist = []
+      }
+    } else {
+      menulist = []
+    }
+  }
+
   const cardWrapForm = [
     {
       type: 'text',
@@ -71,6 +86,7 @@
       controlFields: [
         {field: 'goback', values: ['dynamic']},
         {field: 'empty', values: ['dynamic']},
+        {field: 'jump', values: ['dynamic']},
         {field: 'supModule', values: ['static']},
       ],
       forbid: subtype !== 'propcard'
@@ -270,6 +286,67 @@
     },
     {
       type: 'radio',
+      field: 'jump',
+      label: '椤甸潰璺宠浆',
+      initval: wrap.jump || '',
+      tooltip: '閫氳繃鏌ヨ杩斿洖鍊煎垽鏂〉闈㈡槸鍚﹁璺宠浆銆�',
+      required: false,
+      options: [
+        {value: '', label: '鏃�'},
+        {value: 'menu', label: '鑿滃崟'},
+        {value: 'link', label: '閾炬帴'},
+      ],
+      controlFields: [
+        {field: 'jumpField', values: ['menu', 'link']},
+        {field: 'joint', values: ['menu', 'link']},
+        {field: 'menu', values: ['menu']},
+        {field: 'link', values: ['link']},
+      ],
+      forbid: subtype !== 'propcard' || appType !== 'mob'
+    },
+    {
+      type: 'select',
+      field: 'jumpField',
+      label: '鎺у埗瀛楁',
+      initval: wrap.jumpField || '',
+      tooltip: '褰撳瓧娈靛�间负true鏃�',
+      required: true,
+      options: columns,
+      forbid: subtype !== 'propcard' || appType !== 'mob'
+    },
+    {
+      type: 'select',
+      field: 'menu',
+      label: '鑿滃崟',
+      initval: wrap.menu || '',
+      required: true,
+      options: menulist,
+      forbid: subtype !== 'propcard' || appType !== 'mob'
+    },
+    {
+      type: 'select',
+      field: 'link',
+      label: '閾炬帴瀛楁',
+      initval: wrap.link || '',
+      tooltip: '璺宠浆閾炬帴涓烘煡璇㈡暟鎹殑杩斿洖鍊笺��',
+      required: true,
+      options: columns,
+      forbid: subtype !== 'propcard' || appType !== 'mob'
+    },
+    {
+      type: 'radio',
+      field: 'joint',
+      label: '鍙傛暟鎷兼帴',
+      initval: wrap.joint || 'true',
+      required: false,
+      options: [
+        {value: 'true', label: '鏄�'},
+        {value: 'false', label: '鍚�'},
+      ],
+      forbid: subtype !== 'propcard' || appType !== 'mob'
+    },
+    {
+      type: 'radio',
       field: 'supKey',
       label: '涓婄骇涓婚敭',
       initval: wrap.supKey || 'true',
diff --git a/src/mob/components/menubar/common-menubar/index.jsx b/src/mob/components/menubar/common-menubar/index.jsx
new file mode 100644
index 0000000..479cbf5
--- /dev/null
+++ b/src/mob/components/menubar/common-menubar/index.jsx
@@ -0,0 +1,190 @@
+import React, {Component} from 'react'
+import PropTypes from 'prop-types'
+import { is, fromJS } from 'immutable'
+import { Popover, Col } from 'antd'
+import { ToolOutlined, RightOutlined, MenuOutlined, SettingOutlined, EditOutlined, FontColorsOutlined, DeleteOutlined } from '@ant-design/icons'
+
+import asyncComponent from '@/utils/asyncComponent'
+import asyncIconComponent from '@/utils/asyncIconComponent'
+import { resetStyle } from '@/utils/utils-custom.js'
+import MKEmitter from '@/utils/events.js'
+import getWrapForm from './options'
+import './index.scss'
+
+const NormalForm = asyncIconComponent(() => import('@/components/normalform'))
+const CopyComponent = asyncIconComponent(() => import('@/menu/components/share/copycomponent'))
+const PasteComponent = asyncIconComponent(() => import('@/menu/components/share/pastecomponent'))
+const NormalHeader = asyncComponent(() => import('@/menu/components/share/normalheader'))
+const SettingComponent = asyncIconComponent(() => import('@/menu/datasource'))
+
+class CommonMenuBar extends Component {
+  static propTpyes = {
+    card: PropTypes.object,
+    deletecomponent: PropTypes.func,
+    updateConfig: PropTypes.func,
+  }
+
+  state = {
+    card: null,
+    back: false
+  }
+
+  UNSAFE_componentWillMount () {
+    const { card } = this.props
+
+    if (card.isNew) {
+      let _card = {
+        uuid: card.uuid,
+        type: card.type,
+        tabId: '',
+        parentId: '',
+        format: 'object',   // 缁勪欢灞炴�� - 鏁版嵁鏍煎紡
+        pageable: false,    // 缁勪欢灞炴�� - 鏄惁鍙垎椤�
+        switchable: false,  // 缁勪欢灞炴�� - 鏁版嵁鏄惁鍙垏鎹�
+        dataName: card.dataName || '',
+        width: card.width || 24,
+        name: card.name,
+        subtype: card.subtype,
+        setting: { interType: 'system' },
+        wrap: { name: card.name, width: card.width || 24, title: '鎴戠殑鑿滃崟', menuWidth: 6 },
+        style: { marginLeft: '0px', marginRight: '0px', marginTop: '8px', marginBottom: '8px' },
+        headerStyle: { fontSize: '16px', borderBottomWidth: '1px', borderBottomColor: '#e8e8e8' },
+        subMenus: []
+      }
+
+      if (card.config) {
+        let config = fromJS(card.config).toJS()
+
+        _card.wrap = config.wrap
+        _card.wrap.name = card.name
+        _card.style = config.style
+        _card.headerStyle = config.headerStyle
+      }
+      this.setState({
+        card: _card
+      })
+      this.props.updateConfig(_card)
+    } else {
+      this.setState({
+        card: fromJS(card).toJS()
+      })
+    }
+  }
+
+  componentDidMount () {
+    MKEmitter.addListener('submitStyle', this.getStyle)
+  }
+
+  shouldComponentUpdate (nextProps, nextState) {
+    return !is(fromJS(this.state), fromJS(nextState))
+  }
+
+  /**
+   * @description 缁勪欢閿�姣侊紝娓呴櫎state鏇存柊锛屾竻闄ゅ揩鎹烽敭璁剧疆
+   */
+  componentWillUnmount () {
+    this.setState = () => {
+      return
+    }
+    MKEmitter.removeListener('submitStyle', this.getStyle)
+  }
+
+  /**
+   * @description 鍗$墖琛屽灞備俊鎭洿鏂帮紙鏁版嵁婧愶紝鏍峰紡绛夛級
+   */
+  updateComponent = (component) => {
+    this.setState({
+      card: component
+    })
+
+    component.width = component.wrap.width
+    component.name = component.wrap.name
+
+    this.props.updateConfig(component)
+  }
+
+  changeStyle = () => {
+    const { card } = this.state
+
+    MKEmitter.emit('changeStyle', [card.uuid], ['background', 'border', 'padding', 'margin', 'shadow'], card.style)
+  }
+
+  getStyle = (comIds, style) => {
+    const { card } = this.state
+
+    if (comIds.length !== 1 || comIds[0] !== card.uuid) return
+
+    let _card = {...card, style}
+
+    this.setState({
+      card: _card
+    })
+    
+    this.props.updateConfig(_card)
+  }
+
+  getWrapForms = () => {
+    const { card } = this.state
+
+    return getWrapForm(card.wrap)
+  }
+
+  updateWrap = (res) => {
+    let card = {...this.state.card, wrap: res}
+    if (res.datatype === 'dynamic' && !card.format) {
+      card.format = 'object'
+      card.pageable = false
+      card.switchable = false
+      card.setting = { interType: 'system' }
+      card.columns = []
+      card.scripts = []
+    }
+    this.updateComponent(card)
+  }
+
+  clickComponent = (e) => {
+    if (sessionStorage.getItem('style-control') === 'true' || sessionStorage.getItem('style-control') === 'component') {
+      e.stopPropagation()
+      MKEmitter.emit('clickComponent', this.state.card)
+    }
+  }
+
+  render() {
+    const { card } = this.state
+    let _style = resetStyle(card.style)
+
+    return (
+      <div className="menu-commonbar-edit-box" style={_style} onClick={this.clickComponent} id={card.uuid}>
+        {card.wrap.title ? <NormalHeader config={card} updateComponent={this.updateComponent}/> : null}
+        <Popover overlayClassName="mk-popover-control-wrap" mouseLeaveDelay={0.2} mouseEnterDelay={0.2} content={
+          <div className="mk-popover-control">
+            <NormalForm title="鑿滃崟璁剧疆" width={800} update={this.updateWrap} getForms={this.getWrapForms}>
+              <EditOutlined style={{color: '#1890ff'}} title="缂栬緫"/>
+            </NormalForm>
+            <CopyComponent type="menubar" card={card}/>
+            <PasteComponent config={card} options={['menucell']} updateConfig={this.updateComponent} />
+            <FontColorsOutlined className="style" title="璋冩暣鏍峰紡" onClick={this.changeStyle} />
+            <DeleteOutlined className="close" title="鍒犻櫎缁勪欢" onClick={() => this.props.deletecomponent(card.uuid)} />
+            {card.wrap.datatype === 'dynamic' ? <SettingComponent config={card} updateConfig={this.updateComponent} /> : null}
+            {card.wrap.datatype !== 'dynamic' ? <SettingOutlined style={{color: '#eeeeee', cursor: 'not-allowed'}}/> : null}
+          </div>
+        } trigger="hover">
+          <ToolOutlined />
+        </Popover>
+        <div className={(card.wrap.layout || 'grid') + '-layout'}>
+          <Col span={card.wrap.menuWidth || 24}>
+            <div className="menu-item">
+              <div className="menu-sign">
+                <MenuOutlined />
+              </div>
+              <div className="menu-name" >甯哥敤鑿滃崟</div>
+              <RightOutlined className="menu-right" />
+            </div>
+          </Col>
+        </div>
+      </div>
+    )
+  }
+}
+
+export default CommonMenuBar
\ No newline at end of file
diff --git a/src/mob/components/menubar/common-menubar/index.scss b/src/mob/components/menubar/common-menubar/index.scss
new file mode 100644
index 0000000..042afc5
--- /dev/null
+++ b/src/mob/components/menubar/common-menubar/index.scss
@@ -0,0 +1,98 @@
+.menu-commonbar-edit-box {
+  position: relative;
+  box-sizing: border-box;
+  background: #ffffff;
+  background-position: center center;
+  background-repeat: no-repeat;
+  background-size: cover;
+  min-height: 20px;
+  
+  .card-control {
+    position: absolute;
+    top: 0px;
+    left: 0px;
+    .anticon-tool {
+      right: auto;
+      left: 1px;
+      padding: 1px;
+    }
+  }
+  >.anticon-tool {
+    position: absolute;
+    z-index: 2;
+    font-size: 16px;
+    right: 1px;
+    top: 1px;
+    cursor: pointer;
+    padding: 5px;
+    background: rgba(255, 255, 255, 0.55);
+  }
+  .menu-right {
+    display: none;
+  }
+  .vertical-layout {
+    >.ant-col {
+      width: 100%;
+      .menu-item {
+        display: flex;
+        align-items: center;
+        .menu-sign {
+          margin-right: 10px;
+        }
+        .menu-name {
+          text-align: inherit;
+          flex: 10;
+        }
+        .menu-right {
+          margin-left: 5px;
+          display: inline-block;
+        }
+      }
+    }
+  }
+
+  .menu-item {
+    overflow: hidden;
+    position: relative;
+    min-height: 20px;
+    padding: 15px;
+    .menu-name {
+      text-align: center;
+      font-style: inherit;
+      font-weight: inherit;
+      white-space: nowrap;
+      overflow: hidden;
+      text-overflow: ellipsis;
+      font-size: 17px;
+      line-height: 2;
+    }
+    .menu-sign {
+      position: relative;
+      text-align: center;
+      .anticon {
+        border-radius: 15%;
+        color: #ffffff;
+        font-size: 20px;
+        padding: 12px;
+        background: #1890ff;
+      }
+      .am-badge-text {
+        position: absolute;
+        height: 8px;
+        width: 8px;
+        border-radius: 100%;
+        background: #ff5b05;
+        z-index: 1;
+      }
+    }
+  }
+}
+.menu-commonbar-edit-box::after {
+  display: block;
+  content: ' ';
+  clear: both;
+}
+.menu-commonbar-edit-box:hover {
+  z-index: 1;
+  box-shadow: 0px 0px 4px #1890ff;
+}
diff --git a/src/mob/components/menubar/common-menubar/options.jsx b/src/mob/components/menubar/common-menubar/options.jsx
new file mode 100644
index 0000000..aea9633
--- /dev/null
+++ b/src/mob/components/menubar/common-menubar/options.jsx
@@ -0,0 +1,83 @@
+/**
+ * @description Wrap琛ㄥ崟閰嶇疆淇℃伅
+ */
+export default function (wrap) {
+  const menuWrapForm = [
+    {
+      type: 'text',
+      field: 'title',
+      label: '鏍囬',
+      initval: wrap.title || '',
+      required: false
+    },
+    {
+      type: 'text',
+      field: 'name',
+      label: '缁勪欢鍚嶇О',
+      initval: wrap.name || '',
+      tooltip: '鐢ㄤ簬缁勪欢闂寸殑鍖哄垎銆�',
+      required: true
+    },
+    {
+      type: 'number',
+      field: 'width',
+      label: '缁勪欢瀹藉害',
+      initval: wrap.width || 24,
+      tooltip: '鏍呮牸甯冨眬锛屾瘡琛岀瓑鍒嗕负24鍒椼��',
+      min: 1,
+      max: 24,
+      precision: 0,
+      required: true
+    },
+    {
+      type: 'number',
+      field: 'maxcount',
+      label: '鏄剧ず鏁伴噺',
+      initval: wrap.maxcount || '',
+      tooltip: '鏈�澶ф樉绀烘暟閲忥紝绌烘椂涓嶅仛闄愬埗銆�',
+      min: 1,
+      max: 9999,
+      precision: 0,
+      required: false
+    },
+    {
+      type: 'radio',
+      field: 'datatype',
+      label: '鏁版嵁鏉ユ簮',
+      initval: wrap.datatype || 'static',
+      tooltip: '閫夋嫨闈欐�佸�硷紝鏃犻渶閰嶇疆鏁版嵁婧愩��',
+      required: false,
+      options: [
+        {value: 'dynamic', label: '鍔ㄦ��'},
+        {value: 'static', label: '闈欐��'},
+      ]
+    },
+    {
+      type: 'radio',
+      field: 'layout',
+      label: '鑿滃崟甯冨眬',
+      initval: wrap.layout || 'grid',
+      required: false,
+      options: [
+        {value: 'grid', label: '鏍呮牸甯冨眬'},
+        {value: 'vertical', label: '涓婁笅甯冨眬'},
+      ],
+      controlFields: [
+        {field: 'menuWidth', values: ['grid']},
+      ],
+    },
+    {
+      type: 'number',
+      field: 'menuWidth',
+      label: '鑿滃崟瀹藉害',
+      initval: wrap.menuWidth || 6,
+      tooltip: '鏍呮牸甯冨眬锛屾瘡琛岀瓑鍒嗕负24鍒椼��',
+      min: 1,
+      max: 24,
+      precision: 0,
+      required: true
+    },
+  ]
+
+  return menuWrapForm
+} 
\ No newline at end of file
diff --git a/src/mob/components/menubar/normal-menubar/index.jsx b/src/mob/components/menubar/normal-menubar/index.jsx
index 0ff743d..4416b94 100644
--- a/src/mob/components/menubar/normal-menubar/index.jsx
+++ b/src/mob/components/menubar/normal-menubar/index.jsx
@@ -274,18 +274,6 @@
   render() {
     const { card } = this.state
 
-    let offset = 0
-    if (card.wrap.cardFloat && card.wrap.cardFloat !== 'left') {
-      let _width = 0
-      card.subMenus.forEach(card => {
-        _width += card.setting.width
-      })
-      offset = _width < 24 ? 24 - _width : 0
-      if (card.wrap.cardFloat === 'center') {
-        offset = Math.floor(offset / 2)
-      }
-    }
-
     let _style = resetStyle(card.style)
 
     return (
@@ -309,7 +297,7 @@
           <ToolOutlined />
         </Popover>
         <div className={(card.wrap.layout || 'grid') + '-layout'}>
-          {card.subMenus.map((menu, index) => (<MenuComponent key={menu.uuid} offset={!index ? offset : 0} cards={card} card={menu} move={this.move} updateElement={this.updateCard} deleteElement={this.deleteCard}/>))}
+          {card.subMenus.map((menu, index) => (<MenuComponent key={menu.uuid} cards={card} card={menu} move={this.move} updateElement={this.updateCard} deleteElement={this.deleteCard}/>))}
         </div>
       </div>
     )
diff --git a/src/mob/components/menubar/normal-menubar/menucomponent/index.jsx b/src/mob/components/menubar/normal-menubar/menucomponent/index.jsx
index 3d90d4e..daac1c6 100644
--- a/src/mob/components/menubar/normal-menubar/menucomponent/index.jsx
+++ b/src/mob/components/menubar/normal-menubar/menucomponent/index.jsx
@@ -17,7 +17,6 @@
 
 class MenuBoxComponent extends Component {
   static propTpyes = {
-    offset: PropTypes.any,           // 鍋忕Щ閲�
     cards: PropTypes.object,         // 鍗$墖琛岄厤缃俊鎭�
     card: PropTypes.object,          // 鍗$墖閰嶇疆淇℃伅
     move: PropTypes.func,            // 鍗$墖绉诲姩
@@ -118,7 +117,6 @@
   }
 
   render() {
-    const { offset } = this.props
     const { card } = this.state
 
     let _style = {...card.style}
@@ -126,7 +124,7 @@
     _style = resetStyle(_style)
 
     return (
-      <Col span={card.setting.width || 6} offset={offset || 0}>
+      <Col span={card.setting.width || 6}>
         <Popover overlayClassName="mk-popover-control-wrap" mouseLeaveDelay={0.2} mouseEnterDelay={0.2} content={
           <div className="mk-popover-control">
             <NormalForm title="鑿滃崟缂栬緫" width={900} update={this.updateSetting} getForms={this.getSettingForms}>
diff --git a/src/mob/components/menubar/normal-menubar/options.jsx b/src/mob/components/menubar/normal-menubar/options.jsx
index 5aeb689..97bc816 100644
--- a/src/mob/components/menubar/normal-menubar/options.jsx
+++ b/src/mob/components/menubar/normal-menubar/options.jsx
@@ -51,6 +51,18 @@
         {value: 'grid', label: '鏍呮牸甯冨眬'},
         {value: 'vertical', label: '涓婁笅甯冨眬'},
       ]
+    },
+    {
+      type: 'radio',
+      field: 'common',
+      label: '甯哥敤',
+      initval: wrap.common || 'true',
+      tooltip: '褰撳墠鑿滃崟缁勪腑鐨勮彍鍗曟槸鍚﹀彲娣诲姞鑷冲父鐢ㄨ彍鍗曠粍銆�',
+      required: false,
+      options: [
+        {value: 'true', label: '鍙坊鍔�'},
+        {value: 'false', label: '涓嶅彲娣诲姞'},
+      ]
     }
   ]
 
diff --git a/src/mob/mobshell/card.jsx b/src/mob/mobshell/card.jsx
index 9c18493..7095000 100644
--- a/src/mob/mobshell/card.jsx
+++ b/src/mob/mobshell/card.jsx
@@ -25,6 +25,7 @@
 const NormalNavbar = asyncComponent(() => import('@/mob/components/navbar/normal-navbar'))
 const NormalTopbar = asyncComponent(() => import('@/mob/components/topbar/normal-navbar'))
 const NormalMenuBar = asyncComponent(() => import('@/mob/components/menubar/normal-menubar'))
+const CommonMenuBar = asyncComponent(() => import('@/mob/components/menubar/common-menubar'))
 const Balcony = asyncComponent(() => import('@/menu/components/card/balcony'))
 const Timeline = asyncComponent(() => import('@/menu/components/timeline/normal-timeline'))
 
@@ -120,8 +121,10 @@
       return (<NormalNavbar card={card} updateConfig={updateConfig} deletecomponent={delCard}/>)
     } else if (card.type === 'topbar') {
       return (<NormalTopbar card={card} updateConfig={updateConfig} deletecomponent={delCard}/>)
-    } else if (card.type === 'menubar') {
+    } else if (card.type === 'menubar' && card.subtype === 'menubar') {
       return (<NormalMenuBar card={card} updateConfig={updateConfig} deletecomponent={delCard}/>)
+    } else if (card.type === 'menubar' && card.subtype === 'commonbar') {
+      return (<CommonMenuBar card={card} updateConfig={updateConfig} deletecomponent={delCard}/>)
     } else if (card.type === 'balcony') {
       return (<Balcony card={card} updateConfig={updateConfig} deletecomponent={delCard}/>)
     } else if (card.type === 'timeline') {
diff --git a/src/mob/modulesource/option.jsx b/src/mob/modulesource/option.jsx
index 0869dff..34798d2 100644
--- a/src/mob/modulesource/option.jsx
+++ b/src/mob/modulesource/option.jsx
@@ -24,6 +24,7 @@
 import NavTop from '@/assets/mobimg/navtop-mob.png'
 import scatter from '@/assets/mobimg/scatter.png'
 import MenuBar from '@/assets/mobimg/menubar.png'
+import CommonBar from '@/assets/mobimg/commonbar.png'
 import timeline from '@/assets/mobimg/timeline.png'
 
 // 缁勪欢閰嶇疆淇℃伅
@@ -31,6 +32,7 @@
   { type: 'menu', url: NavTop, component: 'topbar', subtype: 'topbar', title: '瀵艰埅鏍�' },
   { type: 'menu', url: Navbar, component: 'navbar', subtype: 'tabbar', title: '鑿滃崟鏍�' },
   { type: 'menu', url: MenuBar, component: 'menubar', subtype: 'menubar', title: '鑿滃崟' },
+  { type: 'menu', url: CommonBar, component: 'menubar', subtype: 'commonbar', title: '甯哥敤鑿滃崟' },
   { type: 'menu', url: tabs, component: 'tabs', subtype: 'tabs', title: '鏍囩椤�', width: 24 },
   { type: 'menu', url: singlesearch, component: 'search', subtype: 'mainsearch', title: '鎼滅储鏉′欢', width: 24 },
   { type: 'menu', url: card1, component: 'card', subtype: 'datacard', title: '鏁版嵁鍗�', width: 24 },
diff --git a/src/tabviews/custom/components/card/cardcellList/index.jsx b/src/tabviews/custom/components/card/cardcellList/index.jsx
index 8dde166..64352f0 100644
--- a/src/tabviews/custom/components/card/cardcellList/index.jsx
+++ b/src/tabviews/custom/components/card/cardcellList/index.jsx
@@ -311,6 +311,10 @@
         _style.cursor = 'pointer'
       }
 
+      if (card.bgImage && data[card.bgImage]) {
+        _style.backgroundImage = `url('${data[card.bgImage]}')`
+      }
+
       return (
         <Col key={card.uuid} span={card.width}>
           <div style={_style} onClick={(e) => {this.openNewView(e, card)}}>
diff --git a/src/views/login/index.jsx b/src/views/login/index.jsx
index 11df93c..437598a 100644
--- a/src/views/login/index.jsx
+++ b/src/views/login/index.jsx
@@ -517,13 +517,13 @@
             // res.indexlogo = res.indexlogo ? res.indexlogo.replace(/:8080/ig, '').replace(/http:/ig, 'https:') : ''
             // res.loginlogo = res.loginlogo ? res.loginlogo.replace(/:8080/ig, '').replace(/http:/ig, 'https:') : ''
 
-            if (/^https/.test(window.location.protocol)) { // https杞崲
-              res.Banner = res.Banner ? res.Banner.replace(/^http:/ig, 'https:') : ''
-              res.doclogo = res.doclogo ? res.doclogo.replace(/^http:/ig, 'https:') : ''
-              res.indexlogo = res.indexlogo ? res.indexlogo.replace(/^http:/ig, 'https:') : ''
-              res.loginlogo = res.loginlogo ? res.loginlogo.replace(/^http:/ig, 'https:') : ''
-              res.titlelogo = res.titlelogo ? res.titlelogo.replace(/^http:/ig, 'https:') : ''
-            }
+            // if (/^https/.test(window.location.protocol)) { // https杞崲
+            //   res.Banner = res.Banner ? res.Banner.replace(/^http:/ig, 'https:') : ''
+            //   res.doclogo = res.doclogo ? res.doclogo.replace(/^http:/ig, 'https:') : ''
+            //   res.indexlogo = res.indexlogo ? res.indexlogo.replace(/^http:/ig, 'https:') : ''
+            //   res.loginlogo = res.loginlogo ? res.loginlogo.replace(/^http:/ig, 'https:') : ''
+            //   res.titlelogo = res.titlelogo ? res.titlelogo.replace(/^http:/ig, 'https:') : ''
+            // }
 
             let _url = _href + 'system'
             let systemMsg = {
diff --git a/src/views/mobdesign/index.jsx b/src/views/mobdesign/index.jsx
index f630a78..09de4d2 100644
--- a/src/views/mobdesign/index.jsx
+++ b/src/views/mobdesign/index.jsx
@@ -864,7 +864,7 @@
           children: []
         }
 
-        if (item.type === 'topbar' || item.type === 'login' || item.type === 'navbar') {
+        if (item.type === 'topbar' || item.type === 'login' || item.type === 'navbar' || (item.type === 'menubar' && item.subtype === 'commonbar')) {
           return null
         } else if (item.type === 'tabs') {
           let tabs = []
@@ -1369,7 +1369,7 @@
   }
 
   verifyConfig = (show) => {
-    const { config, viewType } = this.state
+    const { config } = this.state
     let error = ''
     let searchSum = 0
     let swipes = []
@@ -1437,9 +1437,9 @@
 
     check(config.components)
 
-    if (!error && viewType === 'userbind' && config.components.filter(item => item.type === 'login').length === 0) {
-      error = '鐢ㄦ埛缁戝畾椤甸潰蹇呴』娣诲姞鐧诲綍銆�'
-    }
+    // if (!error && viewType === 'userbind' && config.components.filter(item => item.type === 'login').length === 0) {
+    //   error = '鐢ㄦ埛缁戝畾椤甸潰蹇呴』娣诲姞鐧诲綍銆�'
+    // }
 
     if (!error && searchSum > 1) {
       error = '鎼滅储缁勪欢涓庡鑸爮鐨勬悳绱㈠姛鑳戒笉鍙悓鏃朵娇鐢ㄣ��'

--
Gitblit v1.8.0