| | |
| | | ] |
| | | ] |
| | | }, |
| | | "homepage": ".", |
| | | "homepage": "./build", |
| | | "devDependencies": { |
| | | "typescript": "^4.0.2" |
| | | } |
| | |
| | | |
| | | // 新系统文件置于admin中 ../options.json |
| | | |
| | | fetch('../options.json') |
| | | fetch('./options.json') |
| | | .then(response => response.json()) |
| | | .catch(() => { |
| | | document.getElementById('root').innerHTML = '<div style="text-align: center; font-size: 30px; margin-top: 40vh;">系统配置信息获取失败,请联系管理员!</div>' |
| | |
| | | label: '链接方式', |
| | | initVal: card.open || 'blank', |
| | | required: true, |
| | | forbid: !isApp, |
| | | forbid: sessionStorage.getItem('appType') === 'pc', |
| | | options: [{ |
| | | value: 'blank', |
| | | text: '新窗口' |
| | |
| | | <div className="am-list-line"> |
| | | <div className="am-input-label">{card.label}</div> |
| | | <div className="am-input-control"> |
| | | <CheckCard width={card.width} ratio={card.ratio} display={card.display} fields={card.fields} options={card.options} /> |
| | | <CheckCard config={card} /> |
| | | </div> |
| | | </div> |
| | | </div>) |
| | |
| | | let _param = { |
| | | templatecode: verify.noteCode, // 模板编码 |
| | | TypeCharOne: verify.noteTemp, // N不同内容,Y相同内容 |
| | | ID: verify.noteId || '' // 模板Id,暂时未使用 |
| | | } |
| | | |
| | | _param.submitdate = res.submitdate |
| | |
| | | _param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') |
| | | _param.secretkey = Utils.encrypt(_param.LText, _param.timestamp) |
| | | |
| | | _param.rduri = 'http://sso.mk9h.cn/webapi/dostar' |
| | | _param.appkey = window.GLOB.appkey || '' |
| | | _param.rduri = 'http://sso.mk9h.cn/webapi/dostars' |
| | | |
| | | Api.dostarInterface(_param).then(result => { |
| | | _param.userid = 'bh0bapabtd45epsgra79segbch6c1ibk' |
| | | _param.LoginUID = 'bh0bapabtd45epsgra79segbch6c1ibk' |
| | | |
| | | Api.getLocalConfig(_param).then(result => { |
| | | if (!result.status) { |
| | | notification.warning({ |
| | | top: 92, |
| | |
| | | } |
| | | |
| | | getCards = () => { |
| | | const { display, width, options, fields, ratio, multiple } = this.props.card |
| | | const { display, width, options, fields, ratio, multiple, backgroundColor, borderColor } = this.props.card |
| | | const { selectKeys } = this.state |
| | | |
| | | let paddingTop = '100%' |
| | |
| | | paddingTop = '56.25%' |
| | | } |
| | | |
| | | let style = {} |
| | | |
| | | if (borderColor) { |
| | | style.borderColor = borderColor |
| | | } |
| | | |
| | | if (!options || options.length === 0) { |
| | | return null |
| | | } else if (display !== 'picture') { |
| | | if (!fields || fields.length === 0) { |
| | | return null |
| | | } |
| | | if (backgroundColor) { |
| | | style.backgroundColor = backgroundColor |
| | | } |
| | | return options.map(item => { |
| | | let _active = false |
| | |
| | | } |
| | | |
| | | return <Col span={width} key={item.key}> |
| | | <div className={'card-cell ' + (_active ? 'active' : '')} onClick={() => this.changeCard(item)}> |
| | | <div className={'card-cell ' + (_active ? 'active' : '')} style={style} onClick={() => this.changeCard(item)}> |
| | | {fields.map(col => { |
| | | return <span key={col.key} style={{color: col.color, fontSize: col.fontSize + 'px', height: col.fontSize * 1.5 + 'px', textAlign: col.align}}>{item[col.field]}</span> |
| | | })} |
| | |
| | | } |
| | | |
| | | return <Col span={width} key={item.key}> |
| | | <div className={'card-pic-cell ' + (_active ? 'active' : '')} onClick={() => this.changeCard(item)} style={{paddingTop, backgroundImage: `url(${item.$url})`}}> |
| | | <div className={'card-pic-cell ' + (_active ? 'active' : '')} onClick={() => this.changeCard(item)} style={{...style, paddingTop, backgroundImage: `url(${item.$url})`}}> |
| | | </div> |
| | | </Col> |
| | | }) |
| | |
| | | |
| | | class CheckCard extends Component { |
| | | static propTpyes = { |
| | | multiple: PropTypes.bool, // 是否可多选 |
| | | ratio: PropTypes.string, // 图片比例 |
| | | width: PropTypes.number, // 宽度 |
| | | display: PropTypes.string, // 显示为:text(文本)、picture(图片) |
| | | fields: PropTypes.array, // 字段集 |
| | | options: PropTypes.array, // 数据列表 |
| | | config: PropTypes.object, // 表单配置信息 |
| | | onChange: PropTypes.func, // 数据切换 |
| | | } |
| | | |
| | | state = {} |
| | | |
| | | getCards = () => { |
| | | const { display, width, options, fields, ratio } = this.props |
| | | const { display, width, options, fields, ratio, backgroundColor, borderColor } = this.props.config |
| | | |
| | | let paddingTop = '100%' |
| | | if (ratio === '4:3') { |
| | |
| | | paddingTop = '56.25%' |
| | | } |
| | | |
| | | let style = {} |
| | | |
| | | if (borderColor) { |
| | | style.borderColor = borderColor |
| | | } |
| | | |
| | | if (display !== 'picture') { |
| | | if (backgroundColor) { |
| | | style.backgroundColor = backgroundColor |
| | | } |
| | | if (!options || options.length === 0) { |
| | | return <Col span={width}> |
| | | <div className="card-cell"> |
| | | <div className="card-cell" style={style}> |
| | | {fields ? fields.map(col => { |
| | | return <span key={col.key} style={{color: col.color, fontSize: col.fontSize + 'px', height: col.fontSize * 1.5 + 'px', textAlign: col.align}}>{col.field}</span> |
| | | }) : null} |
| | |
| | | } |
| | | return options.map(item => { |
| | | return <Col span={width} key={item.key}> |
| | | <div className="card-cell"> |
| | | <div className="card-cell" style={style}> |
| | | {fields.map(col => { |
| | | return <span key={col.key} style={{color: col.color, fontSize: col.fontSize + 'px', height: col.fontSize * 1.5 + 'px', textAlign: col.align}}>{item[col.field]}</span> |
| | | })} |
| | |
| | | } else { |
| | | if (!options || options.length === 0) { |
| | | return <Col span={width}> |
| | | <div className="card-pic-cell" style={{paddingTop, background: '#91d5ff'}}> |
| | | <div className="card-pic-cell" style={{...style, paddingTop, background: '#91d5ff'}}> |
| | | </div> |
| | | </Col> |
| | | } |
| | | return options.map(item => { |
| | | return <Col span={width} key={item.key}> |
| | | <div className="card-pic-cell" style={{paddingTop, backgroundImage: `url(${item.$url})`}}> |
| | | <div className="card-pic-cell" style={{...style, paddingTop, backgroundImage: `url(${item.$url})`}}> |
| | | </div> |
| | | </Col> |
| | | }) |
| | |
| | | } else if (card.type === 'split') { |
| | | formItem = <div className="split-line">{card.label}</div> |
| | | } else if (card.type === 'checkcard') { |
| | | formItem = <CheckCard width={card.width} ratio={card.ratio} display={card.display} fields={card.fields} options={card.options} /> |
| | | formItem = <CheckCard config={card} /> |
| | | } |
| | | |
| | | let _label = card.label |
| | |
| | | }] |
| | | }, |
| | | { |
| | | type: 'color', |
| | | key: 'backgroundColor', |
| | | label: '背景色', |
| | | initVal: card.backgroundColor || '', |
| | | required: false |
| | | }, |
| | | { |
| | | type: 'color', |
| | | key: 'borderColor', |
| | | label: '边框颜色', |
| | | initVal: card.borderColor || '', |
| | | required: false |
| | | }, |
| | | { |
| | | type: 'radio', |
| | | key: 'declareType', |
| | | label: '数据类型', |
| | |
| | | import EditTable from './modaleditable' |
| | | import DataTable from './datatable' |
| | | import FieldsTable from './fieldtable' |
| | | import asyncComponent from '@/utils/asyncComponent' |
| | | import CodeMirror from '@/templates/zshare/codemirror' |
| | | import './index.scss' |
| | | |
| | | const { TextArea } = Input |
| | | const ColorSketch = asyncComponent(() => import('@/mob/colorsketch')) |
| | | |
| | | const modalTypeOptions = { |
| | | text: ['initval', 'readonly', 'required', 'hidden', 'readin', 'fieldlength', 'regular', 'interception', 'span', 'labelwidth', 'tooltip', 'extra', 'enter', 'cursor', 'scan'], |
| | |
| | | select: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'setAll', 'linkSubField', 'span', 'labelwidth', 'tooltip', 'extra', 'emptyText', 'enter'], |
| | | checkbox: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'span', 'labelwidth', 'tooltip', 'extra'], |
| | | radio: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'linkSubField', 'span', 'labelwidth', 'tooltip', 'extra', 'setAll', 'emptyText'], |
| | | checkcard: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'linkSubField', 'fieldlength', 'span', 'labelwidth', 'display', 'tooltip', 'extra', 'width', 'multiple'], |
| | | checkcard: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'linkSubField', 'fieldlength', 'span', 'labelwidth', 'display', 'tooltip', 'extra', 'width', 'multiple', 'borderColor'], |
| | | multiselect: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'fieldlength', 'span', 'labelwidth', 'tooltip', 'extra'], |
| | | link: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'setAll', 'linkField', 'span', 'labelwidth', 'tooltip', 'extra', 'emptyText', 'enter'], |
| | | fileupload: ['readonly', 'required', 'readin', 'fieldlength', 'maxfile', 'fileType', 'span', 'labelwidth', 'tooltip', 'extra', 'compress'], |
| | |
| | | } |
| | | } else { |
| | | if (resourceType === '0') { // 自定义资源 |
| | | _options.push('options', 'fields') |
| | | _options.push('options', 'fields', 'backgroundColor') |
| | | } else if (resourceType === '1') { // 数据源 |
| | | _options.push('dataSource', 'cardValField', 'fields', 'orderBy', 'orderType', 'database') |
| | | _options.push('dataSource', 'cardValField', 'fields', 'orderBy', 'orderType', 'database', 'backgroundColor') |
| | | } |
| | | } |
| | | } else if (type === 'fileupload') { |
| | |
| | | </Form.Item> |
| | | </Col> |
| | | ) |
| | | } else if (item.type === 'color') { |
| | | fields.push( |
| | | <Col span={12} key={index}> |
| | | <Form.Item label={item.label} className="color-form-item"> |
| | | {getFieldDecorator(item.key, { |
| | | initialValue: item.initVal |
| | | })(<ColorSketch allowClear={true}/>)} |
| | | </Form.Item> |
| | | </Col> |
| | | ) |
| | | } |
| | | }) |
| | | |
| | |
| | | .ant-input-number { |
| | | width: 100%; |
| | | } |
| | | .color-form-item { |
| | | .ant-form-item-control { |
| | | height: 40px; |
| | | .color-sketch-block { |
| | | margin-top: 7px; |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | }, |
| | | { |
| | | obj_name: 'noteCodes', |
| | | arr_field: 'templatecode,describe', |
| | | LText: window.btoa(window.encodeURIComponent(`select templatecode,'['+SignName+']'+describe as describe from (select * from bd_msn_sms_temp where deleted=0 and TypeDesc='QX' and status=20 ) t inner join (select openid from susers where uid=@userid@) u on t.openid =t.openid`)) |
| | | arr_field: 'templatecode,describe,id', |
| | | LText: window.btoa(window.encodeURIComponent(`select t.id,templatecode,'['+SignName+']'+describe as describe from (select * from bd_msn_sms_temp where deleted=0 and TypeDesc='QX' and status=20 ) t inner join (select openid from susers where uid=@userid@) u on t.openid =t.openid`)) |
| | | }, |
| | | { |
| | | obj_name: 'scripts', |
| | |
| | | notes: res.noteCodes.map(item => { |
| | | return { |
| | | name: item.describe, |
| | | value: item.templatecode |
| | | value: item.templatecode, |
| | | id: item.id |
| | | } |
| | | }), |
| | | systemScripts: res.scripts.map(item => { |
| | |
| | | this.setState({ verify }) |
| | | } |
| | | |
| | | onNoteCodeChange = (val) => { |
| | | onNoteCodeChange = (val, option) => { |
| | | const { verify } = this.state |
| | | |
| | | this.setState({ |
| | | verify: {...verify, noteCode: val} |
| | | verify: {...verify, noteCode: val, noteId: option.props.id} |
| | | }) |
| | | } |
| | | |
| | |
| | | <Form.Item label="短信模板"> |
| | | <Select value={verify.noteCode} onSelect={this.onNoteCodeChange}> |
| | | {notes.map(option => |
| | | <Select.Option key={option.value} value={option.value}> |
| | | <Select.Option key={option.value} id={option.id} value={option.value}> |
| | | {option.name} |
| | | </Select.Option> |
| | | )} |
| | |
| | | base_url = window.GLOB.location + '/' + window.GLOB.service |
| | | } |
| | | |
| | | sessionStorage.setItem('isEditState', 'true') |
| | | |
| | | class AppManage extends Component { |
| | | state = { |
| | | loading: false, |
| | |
| | | { |
| | | title: '权限管理', dataIndex: 'role_type', key: 'role_type', align: 'center', |
| | | render: (text, record) => text === 'false' ? '不启用' : '启用' |
| | | }, |
| | | { |
| | | title: '用户绑定', dataIndex: 'user_binding', key: 'user_binding', align: 'center', |
| | | render: (text, record) => { |
| | | let val = '' |
| | | if (!text) return '无' |
| | | if (text.indexOf('uname_pwd') > -1) { |
| | | val = '用户名' |
| | | } |
| | | if (text.indexOf('sms_vcode') > -1) { |
| | | val = val ? val + ',手机号' : '手机号' |
| | | } |
| | | return val |
| | | } |
| | | }, |
| | | { |
| | | title: '皮肤', dataIndex: 'css', key: 'css', align: 'center', |
| | |
| | | UNSAFE_componentWillMount() { |
| | | document.body.className = '' |
| | | this.getAppList() |
| | | this.getSmStemp() |
| | | } |
| | | |
| | | /** |
| | |
| | | duration: 5 |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | |
| | | getSmStemp = () => { |
| | | let _sql = `select ID,TemplateCode,SignName from (select * from bd_msn_sms_temp where deleted=0 and status=20 ) a |
| | | inner join (select openid from sapp where id='${window.GLOB.appkey}') b |
| | | on a.openid=b.openid` |
| | | |
| | | _sql = Utils.formatOptions(_sql) |
| | | |
| | | let param = { |
| | | func: 'sPC_Get_SelectedList', |
| | | LText: _sql, |
| | | obj_name: 'data', |
| | | arr_field: 'ID,TemplateCode,SignName' |
| | | } |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | param.open_key = Utils.encryptOpenKey(param.secretkey, param.timestamp) // 云端数据验证 |
| | | |
| | | Api.getSystemConfig(param).then(res => { |
| | | let msgs = [] |
| | | if (!res.status) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | | duration: 5 |
| | | }) |
| | | } else if (res.data) { |
| | | msgs = res.data |
| | | } |
| | | sessionStorage.setItem('msgTemplate', JSON.stringify(msgs)) |
| | | }) |
| | | } |
| | | |
| | |
| | | sublist = sublist.filter(item => item.ID !== record.ID) |
| | | |
| | | // param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','${item.link_type || 'true'}','${item.role_type || 'true'}','${item.lang || 'zh-CN'}'`) |
| | | param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}'`) |
| | | param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}','${item.user_binding || ''}','${item.sms_id || ''}'`) |
| | | param.LText = param.LText.join(' union all ') |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | |
| | |
| | | |
| | | if (visible === 'edit') { |
| | | // param.LText = selectApp.sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','${item.link_type || 'true'}','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}'`) |
| | | param.LText = selectApp.sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}'`) |
| | | param.LText = selectApp.sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}','${item.user_binding || ''}','${item.sms_id || ''}'`) |
| | | param.LText = param.LText.join(' union all ') |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | } |
| | |
| | | } |
| | | |
| | | // param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','${item.link_type || 'true'}','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}'`) |
| | | param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}'`) |
| | | param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}','${item.user_binding || ''}','${item.sms_id || ''}'`) |
| | | param.LText = param.LText.join(' union all ') |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | |
| | |
| | | </Modal> |
| | | <Modal |
| | | title={'编辑子应用'} |
| | | width={'750px'} |
| | | width={'850px'} |
| | | maskClosable={false} |
| | | visible={!!subVisible} |
| | | onCancel={() => this.setState({subVisible: false})} |
| | |
| | | import React, {Component} from 'react' |
| | | import PropTypes from 'prop-types' |
| | | import { Form, Row, Col, Select, Radio, Input } from 'antd' |
| | | import { Form, Row, Col, Select, Radio, Input, Tooltip, Icon, notification } from 'antd' |
| | | |
| | | import asyncComponent from '@/utils/asyncComponent' |
| | | import './index.scss' |
| | |
| | | inputSubmit: PropTypes.func // input回车提交 |
| | | } |
| | | |
| | | state = {} |
| | | state = {msgs: [], typename: 'mob', user_binding: []} |
| | | |
| | | UNSAFE_componentWillMount() { |
| | | const { card } = this.props |
| | | let msgs = sessionStorage.getItem('msgTemplate') |
| | | let user_binding = [] |
| | | let typename = 'mob' |
| | | |
| | | if (card) { |
| | | typename = card.typename || 'mob' |
| | | user_binding = card.user_binding ? card.user_binding.split(',') : [] |
| | | } |
| | | |
| | | this.setState({msgs: JSON.parse(msgs), typename, user_binding}) |
| | | } |
| | | |
| | | /** |
| | | * @description 获取表单值 |
| | |
| | | return new Promise(resolve => { |
| | | this.props.form.validateFieldsAndScroll((err, values) => { |
| | | if (!err) { |
| | | values.user_binding = values.user_binding ? values.user_binding.join(',') : '' |
| | | if (values.user_binding.indexOf('sms_vcode') > -1 && !values.sms_id) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: '手机号绑定时,需要短信模板!', |
| | | duration: 5 |
| | | }) |
| | | return |
| | | } |
| | | resolve(values) |
| | | } |
| | | }) |
| | |
| | | render() { |
| | | const { card, type } = this.props |
| | | const { getFieldDecorator } = this.props.form |
| | | const { msgs, typename, user_binding } = this.state |
| | | const formItemLayout = { |
| | | labelCol: { |
| | | xs: { span: 24 }, |
| | |
| | | } |
| | | |
| | | return ( |
| | | <Form {...formItemLayout} className="mob-card-edit-form"> |
| | | <Form {...formItemLayout} className="sub-app-edit-form"> |
| | | <Row gutter={24}> |
| | | <Col span={12}> |
| | | <Form.Item label="应用类型"> |
| | | {getFieldDecorator('typename', { |
| | | initialValue: card ? card.typename : 'mob' |
| | | initialValue: typename |
| | | })( |
| | | <Select disabled={type === 'edit'}> |
| | | <Select disabled={type === 'edit'} onChange={(val) => this.setState({typename: val})}> |
| | | <Select.Option value="mob">移动端(包括android、ios)</Select.Option> |
| | | <Select.Option value="pad">Pad端</Select.Option> |
| | | <Select.Option value="pc">PC端</Select.Option> |
| | |
| | | )} |
| | | </Form.Item> |
| | | </Col> |
| | | {typename !== 'pc' ? <Col span={12}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="使用微信授权登录时,是否需要绑定用户。"> |
| | | <Icon type="question-circle" /> |
| | | 用户绑定 |
| | | </Tooltip> |
| | | }> |
| | | {getFieldDecorator('user_binding', { |
| | | initialValue: user_binding |
| | | })( |
| | | <Select mode="multiple"> |
| | | <Select.Option value="uname_pwd">用户名</Select.Option> |
| | | <Select.Option value="sms_vcode">手机号</Select.Option> |
| | | </Select> |
| | | )} |
| | | </Form.Item> |
| | | </Col> : null} |
| | | {typename !== 'pc' ? <Col span={12}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="短信模板可在管理系统 HS-奇云短信模板 处添加。"> |
| | | <Icon type="question-circle" /> |
| | | 短信模板 |
| | | </Tooltip> |
| | | }> |
| | | {getFieldDecorator('sms_id', { |
| | | initialValue: card ? card.sms_id || '' : '' |
| | | })( |
| | | <Select allowClear> |
| | | {msgs.map(option => |
| | | <Select.Option key={option.ID} value={option.ID}>{option.SignName + ' - ' + option.TemplateCode}</Select.Option> |
| | | )} |
| | | </Select> |
| | | )} |
| | | </Form.Item> |
| | | </Col> : null} |
| | | <Col span={12}> |
| | | <Form.Item label="皮肤"> |
| | | {getFieldDecorator('css', { |
| | |
| | | .mob-card-edit-form { |
| | | .sub-app-edit-form { |
| | | padding: 0px 24px 20px; |
| | | |
| | | .anticon-question-circle { |
| | | color: #c49f47; |
| | | margin-right: 3px; |
| | | } |
| | | } |
| | |
| | | navBar: res.menu_type |
| | | } |
| | | |
| | | sessionStorage.setItem('home_background', res.index_background_color) |
| | | sessionStorage.setItem('sys_datetime', res.sys_datetime) |
| | | sessionStorage.setItem('app_datetime', new Date().getTime()) |
| | | sessionStorage.setItem('home_background', res.index_background_color || '') |
| | | if (res.sys_datetime) { |
| | | sessionStorage.setItem('sys_datetime', res.sys_datetime) |
| | | sessionStorage.setItem('app_datetime', new Date().getTime()) |
| | | } |
| | | |
| | | // url标题 |
| | | document.title = systemMsg.platTitle |
| | |
| | | return |
| | | } |
| | | |
| | | let param = { |
| | | func: 'MSN_sms_send_code', |
| | | let _param = { |
| | | func: 'mes_sms_send_code_sso', |
| | | send_type: 'login', |
| | | mob: _phone, |
| | | timestamp: moment().format('YYYY-MM-DD HH:mm:ss'), |
| | | ID: smsId |
| | | } |
| | | _param.LText = 'minke' |
| | | _param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') |
| | | _param.secretkey = md5(`${_param.LText}mingke${_param.timestamp}`) |
| | | |
| | | _param.userid = sessionStorage.getItem('visitorUserID') || '' |
| | | _param.LoginUID = sessionStorage.getItem('visitorLoginUID') || '' |
| | | |
| | | param.LText = md5(`${_phone}mingke${window.GLOB.appkey}${param.timestamp}`) |
| | | param.secretkey = md5(`${param.LText}mingke${param.timestamp}`) |
| | | Api.getSystemConfig(_param).then(res => { |
| | | if (!res.status || !res.n_id) { |
| | | message.warning(res.message || '验证码获取失败!') |
| | | return |
| | | } |
| | | |
| | | param.userid = sessionStorage.getItem('visitorUserID') || '' |
| | | param.LoginUID = sessionStorage.getItem('visitorLoginUID') || '' |
| | | let param = { |
| | | func: 'MSN_sms_send_code', |
| | | send_type: 'login', |
| | | mob: _phone, |
| | | timestamp: moment().format('YYYY-MM-DD HH:mm:ss'), |
| | | ID: smsId, |
| | | n_id: res.n_id |
| | | } |
| | | |
| | | param.LText = md5(`${_phone}mingke${window.GLOB.appkey}${param.timestamp}`) |
| | | param.secretkey = md5(`${param.LText}mingke${param.timestamp}`) |
| | | |
| | | this.setState({ |
| | | verdisabled: true, |
| | | delay: 60 |
| | | }) |
| | | LoginVerCodeTimer = setTimeout(this.resetVerCodeDelay, 1000) |
| | | |
| | | Api.getSystemConfig(param).then(res => { |
| | | if (res.status) { |
| | | |
| | | } else { |
| | | param.rduri = 'http://sso.mk9h.cn/webapi/dostars' |
| | | param.userid = 'bh0bapabtd45epsgra79segbch6c1ibk' |
| | | param.LoginUID = 'bh0bapabtd45epsgra79segbch6c1ibk' |
| | | |
| | | this.setState({ |
| | | verdisabled: true, |
| | | delay: 60 |
| | | }) |
| | | LoginVerCodeTimer = setTimeout(this.resetVerCodeDelay, 1000) |
| | | |
| | | Api.getLocalConfig(param).then(res => { |
| | | if (res.status) { |
| | | |
| | | } else { |
| | | if (LoginVerCodeTimer) { |
| | | clearTimeout(LoginVerCodeTimer) |
| | | } |
| | | this.setState({ |
| | | verdisabled: false, |
| | | delay: null |
| | | }) |
| | | message.warning(res.message) |
| | | } |
| | | }, () => { |
| | | if (LoginVerCodeTimer) { |
| | | clearTimeout(LoginVerCodeTimer) |
| | | } |
| | |
| | | verdisabled: false, |
| | | delay: null |
| | | }) |
| | | message.warning(res.message) |
| | | } |
| | | }, () => { |
| | | if (LoginVerCodeTimer) { |
| | | clearTimeout(LoginVerCodeTimer) |
| | | } |
| | | this.setState({ |
| | | verdisabled: false, |
| | | delay: null |
| | | }) |
| | | }) |
| | | } |
| | |
| | | } |
| | | |
| | | getSmStemp = () => { |
| | | let _sql = `select ID,TemplateCode,SignName from bd_msn_sms_temp where deleted=0 and appkey='${window.GLOB.appkey}'` |
| | | let _sql = `select ID,TemplateCode,SignName from (select * from bd_msn_sms_temp where deleted=0 and status=20 ) a |
| | | inner join (select openid from sapp where id='${window.GLOB.appkey}') b |
| | | on a.openid=b.openid` |
| | | |
| | | _sql = Utils.formatOptions(_sql) |
| | | |
| | |
| | | } |
| | | |
| | | getSmStemp = () => { |
| | | let _sql = `select ID,TemplateCode,SignName from bd_msn_sms_temp where deleted=0 and appkey='${window.GLOB.appkey}'` |
| | | let _sql = `select ID,TemplateCode,SignName from (select * from bd_msn_sms_temp where deleted=0 and status=20 ) a |
| | | inner join (select openid from sapp where id='${window.GLOB.appkey}') b |
| | | on a.openid=b.openid` |
| | | |
| | | _sql = Utils.formatOptions(_sql) |
| | | |