| | |
| | | height: 100%; |
| | | overflow: hidden; |
| | | >.ant-collapse { |
| | | border-top: 0; |
| | | border: 0; |
| | | background: #262E3F; |
| | | |
| | | > .ant-collapse-item > .ant-collapse-header { |
| | | padding: 10px 40px 10px 16px; |
| | | background: #262E3F; |
| | | color: rgba(255, 255, 255, 0.85); |
| | | > .ant-collapse-item { |
| | | border-color: #202735; |
| | | > .ant-collapse-header { |
| | | padding: 10px 40px 10px 16px; |
| | | background: #262E3F; |
| | | color: rgba(255, 255, 255, 0.85); |
| | | } |
| | | >.ant-collapse-content { |
| | | color: rgba(255, 255, 255, 0.85); |
| | | background-color: #202735; |
| | | border-top: 1px solid #202735; |
| | | } |
| | | } |
| | | } |
| | | } |
New file |
| | |
| | | import React, {Component} from 'react' |
| | | import PropTypes from 'prop-types' |
| | | // import { is, fromJS } from 'immutable' |
| | | import { Form, Icon, Popover, Input } from 'antd' |
| | | |
| | | import zhCN from '@/locales/zh-CN/mob.js' |
| | | import enUS from '@/locales/en-US/mob.js' |
| | | import './index.scss' |
| | | |
| | | class ContentUpdate extends Component { |
| | | static propTpyes = { |
| | | element: PropTypes.object, |
| | | updateContent: PropTypes.func |
| | | } |
| | | |
| | | state = { |
| | | dict: localStorage.getItem('lang') !== 'en-US' ? zhCN : enUS |
| | | } |
| | | |
| | | UNSAFE_componentWillMount () { |
| | | |
| | | } |
| | | |
| | | // shouldComponentUpdate (nextProps, nextState) { |
| | | // return !is(fromJS(this.props), fromJS(nextProps)) || !is(fromJS(this.state), fromJS(nextState)) |
| | | // } |
| | | |
| | | onVisibleChange = (visible) => { |
| | | let val = this.props.form.getFieldValue('content') |
| | | console.log(visible) |
| | | console.log(val) |
| | | } |
| | | |
| | | render () { |
| | | const { element } = this.props |
| | | const { getFieldDecorator } = this.props.form |
| | | |
| | | return ( |
| | | <div className="mob-content-update"> |
| | | <Popover content={ |
| | | <div> |
| | | {getFieldDecorator('content', { |
| | | initialValue: element.content |
| | | })(<Input placeholder="" autoComplete="off" onPressEnter={this.handleSubmit} />)} |
| | | </div> |
| | | } overlayClassName="mob-content-update-popover" placement="bottomRight" title="" trigger="click" onVisibleChange={this.onVisibleChange}> |
| | | <Icon type="edit" /> |
| | | </Popover> |
| | | </div> |
| | | ) |
| | | } |
| | | } |
| | | |
| | | export default Form.create()(ContentUpdate) |
New file |
| | |
| | | .mob-content-update { |
| | | position: absolute; |
| | | top: -23px; |
| | | right: -1px; |
| | | background: #2f54eb; |
| | | border-radius: 2px; |
| | | color: #ffffff; |
| | | font-size: 14px; |
| | | |
| | | i { |
| | | padding: 2px 5px; |
| | | cursor: pointer; |
| | | } |
| | | |
| | | } |
| | | .mob-content-update-popover { |
| | | .ant-popover-content { |
| | | margin-top: -5px; |
| | | .ant-popover-arrow { |
| | | top: 1px; |
| | | } |
| | | } |
| | | input { |
| | | width: 200px; |
| | | } |
| | | } |
| | |
| | | |
| | | import zhCN from '@/locales/zh-CN/mob.js' |
| | | import enUS from '@/locales/en-US/mob.js' |
| | | // import mklogo from '@/assets/mobimg/mklogo.png' |
| | | import ContentUpdate from '@/mob/contupdate' |
| | | import './index.scss' |
| | | |
| | | const CheckboxItem = Checkbox.CheckboxItem |
| | | // const PlaceHolder = ({ active = false, children}) => ( |
| | | // <div>{active ? <div></div> : null}{children}</div> |
| | | // ) |
| | | |
| | | class MobLogin extends Component { |
| | | static propTpyes = { |
| | |
| | | this.props.triggerEdit(element) |
| | | } |
| | | |
| | | updateContent = () => { |
| | | |
| | | } |
| | | |
| | | render () { |
| | | const { card, editId } = this.props |
| | | const { getFieldProps } = this.props.form |
| | |
| | | <div className={'logo ' + (editId === card.logo.uuid ? 'editing' : '')} onClick={this.editLogo}> |
| | | <img src={card.logo.content} alt=""/> |
| | | </div> |
| | | <div className={'plat-name ' + (editId === card.title.uuid ? 'editing' : '')} onClick={this.editTitle}>明科商业智能开放平台</div> |
| | | <div className={'plat-name ' + (editId === card.title.uuid ? 'editing' : '')} onClick={this.editTitle}> |
| | | {editId === card.title.uuid ? <ContentUpdate element={card.title} updateContent={this.updateContent}/> : null} |
| | | {card.title.content} |
| | | </div> |
| | | <InputItem |
| | | placeholder="UserName" |
| | | prefixListCls="mk-login-item am-list" |
| | |
| | | </div> |
| | | <Button type="primary" onDoubleClick={() => this.props.doubleClickCard(card.login)}>登录</Button> |
| | | <div className={'company-msg ' + (editId === card.copyright.uuid ? 'editing' : '')} onClick={this.editMsg}> |
| | | <p>Copyright©2017 所有相关版权归 北京明科普华信息技术有限公司</p> |
| | | <p>{card.copyright.content}</p> |
| | | </div> |
| | | </div> |
| | | ) |
| | |
| | | } |
| | | |
| | | .plat-name { |
| | | position: relative; |
| | | max-width: 280px; |
| | | min-height: 10px; |
| | | margin: 0 auto; |
| | |
| | | let DateCount = '' |
| | | |
| | | if (setting.default !== 'false' && setting.laypage !== 'false') { |
| | | LText = `select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows` |
| | | LText = ` select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows ` |
| | | DateCount = `select count(1) as total from ${_dataresource} ${_search}` |
| | | } else if (setting.default !== 'false') { |
| | | LText = `select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable order by tmptable.rows` |
| | | LText = ` select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable order by tmptable.rows ` |
| | | DateCount = '' |
| | | } |
| | | |
| | |
| | | LText += ` |
| | | aaa: |
| | | if @ErrorCode!='' |
| | | insert into tmp_err_retmsg (ID, ErrorCode, retmsg, CreateUserID) select @time_id@,@ErrorCode, @retmsg,@UserID@ |
| | | insert into tmp_err_retmsg (ID, ErrorCode, retmsg, CreateUserID) select @time_id@,@ErrorCode, @retmsg,@UserID@ |
| | | ` |
| | | } else { |
| | | param.custom_script += ` |
| | |
| | | |
| | | } else if (btn.sql && btn.sqlType === 'insert') { // 系统函数添加时,生成uuid |
| | | param.ID = Utils.getguid() |
| | | param.LText = Utils.formatOptions(Utils.getSysDefaultSql(btn, setting, formdata, param, data, logcolumns)) // 数据源 |
| | | param.LText = Utils.getSysDefaultSql(btn, setting, formdata, param, data, logcolumns) // 数据源 |
| | | |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | |
| | | _primaryId = param.ID |
| | | } else if (btn.sql && btn.sqlType === 'insertOrUpdate') { // 系统函数添加或修改时 |
| | | param.ID = primaryId || Utils.getguid() |
| | | param.LText = Utils.formatOptions(Utils.getSysDefaultSql(btn, setting, formdata, param, data, logcolumns)) // 数据源 |
| | | param.LText = Utils.getSysDefaultSql(btn, setting, formdata, param, data, logcolumns) // 数据源 |
| | | |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | |
| | | _primaryId = param.ID |
| | | } else if (btn.sql) { |
| | | param.ID = primaryId |
| | | param.LText = Utils.formatOptions(Utils.getSysDefaultSql(btn, setting, formdata, param, data, logcolumns)) // 数据源 |
| | | param.LText = Utils.getSysDefaultSql(btn, setting, formdata, param, data, logcolumns) // 数据源 |
| | | |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } |
| | |
| | | let DateCount = '' |
| | | |
| | | if (setting.default !== 'false' && setting.laypage !== 'false') { |
| | | LText = `select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows` |
| | | LText = ` select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows ` |
| | | DateCount = `select count(1) as total from ${_dataresource} ${_search}` |
| | | } else if (setting.default !== 'false') { |
| | | LText = `select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable order by tmptable.rows` |
| | | LText = ` select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable order by tmptable.rows ` |
| | | DateCount = '' |
| | | } |
| | | |
| | |
| | | LText += ` |
| | | aaa: |
| | | if @ErrorCode!='' |
| | | insert into tmp_err_retmsg (ID, ErrorCode, retmsg, CreateUserID) select @time_id@,@ErrorCode, @retmsg,@UserID@ |
| | | insert into tmp_err_retmsg (ID, ErrorCode, retmsg, CreateUserID) select @time_id@,@ErrorCode, @retmsg,@UserID@ |
| | | ` |
| | | } else { |
| | | param.custom_script += ` |
| | |
| | | let DateCount = '' |
| | | |
| | | if (setting.default !== 'false' && setting.laypage !== 'false') { |
| | | LText = `select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows` |
| | | LText = ` select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows ` |
| | | DateCount = `select count(1) as total from ${_dataresource} ${_search}` |
| | | } else if (setting.default !== 'false') { |
| | | LText = `select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable order by tmptable.rows` |
| | | LText = ` select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable order by tmptable.rows ` |
| | | DateCount = '' |
| | | } |
| | | |
| | |
| | | LText += ` |
| | | aaa: |
| | | if @ErrorCode!='' |
| | | insert into tmp_err_retmsg (ID, ErrorCode, retmsg, CreateUserID) select @time_id@,@ErrorCode, @retmsg,@UserID@ |
| | | insert into tmp_err_retmsg (ID, ErrorCode, retmsg, CreateUserID) select @time_id@,@ErrorCode, @retmsg,@UserID@ |
| | | ` |
| | | } else { |
| | | param.custom_script += ` |
| | |
| | | let LText = '' |
| | | |
| | | if (setting.default !== 'false') { |
| | | LText = `select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${setting.order}) as rows from ${_dataresource}) tmptable order by tmptable.rows` |
| | | LText = ` select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${setting.order}) as rows from ${_dataresource}) tmptable order by tmptable.rows ` |
| | | } |
| | | |
| | | if (param.custom_script) { |
| | |
| | | LText += ` |
| | | aaa: |
| | | if @ErrorCode!='' |
| | | insert into tmp_err_retmsg (ID, ErrorCode, retmsg, CreateUserID) select @time_id@,@ErrorCode, @retmsg,@UserID@ |
| | | insert into tmp_err_retmsg (ID, ErrorCode, retmsg, CreateUserID) select @time_id@,@ErrorCode, @retmsg,@UserID@ |
| | | ` |
| | | } else { |
| | | param.custom_script += ` |
| | |
| | | } |
| | | } else if (btn.sql) { |
| | | param.ID = primaryId |
| | | param.LText = Utils.formatOptions(Utils.getSysDefaultSql(btn, setting, '', param, data[0], logcolumns)) // 数据源 |
| | | param.LText = Utils.getSysDefaultSql(btn, setting, '', param, data[0], logcolumns) // 数据源 |
| | | |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } |
| | |
| | | } |
| | | } |
| | | param.ID = primaryId || Utils.getguid() |
| | | param.LText = Utils.formatOptions(Utils.getSysDefaultSql(btn, setting, formdata, param, data[0], logcolumns)) // 数据源 |
| | | param.LText = Utils.getSysDefaultSql(btn, setting, formdata, param, data[0], logcolumns) // 数据源 |
| | | |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } else if (btn.sql) { |
| | | param.ID = primaryId |
| | | param.LText = Utils.formatOptions(Utils.getSysDefaultSql(btn, setting, formdata, param, data[0], logcolumns)) // 数据源 |
| | | param.LText = Utils.getSysDefaultSql(btn, setting, formdata, param, data[0], logcolumns) // 数据源 |
| | | |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } |
| | |
| | | } |
| | | } else if (btn.sql) { |
| | | param.ID = primaryId |
| | | param.LText = Utils.formatOptions(Utils.getSysDefaultSql(btn, setting, '', param, cell, logcolumns)) // 数据源 |
| | | param.LText = Utils.getSysDefaultSql(btn, setting, '', param, cell, logcolumns) // 数据源 |
| | | |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } |
| | |
| | | } |
| | | } else if (btn.sql && btn.sqlType === 'insert') { // 系统函数添加时,生成uuid |
| | | param.ID = _formPrimaryId || Utils.getguid() |
| | | param.LText = Utils.formatOptions(Utils.getSysDefaultSql(btn, setting, formdata, param, cell, logcolumns)) // 数据源 |
| | | param.LText = Utils.getSysDefaultSql(btn, setting, formdata, param, cell, logcolumns) // 数据源 |
| | | |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } else if (btn.sql) { |
| | |
| | | } |
| | | |
| | | param.ID = primaryId |
| | | param.LText = Utils.formatOptions(Utils.getSysDefaultSql(btn, setting, formdata, param, cell, logcolumns)) // 数据源 |
| | | param.LText = Utils.getSysDefaultSql(btn, setting, formdata, param, cell, logcolumns) // 数据源 |
| | | |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } |
| | |
| | | _search = '' |
| | | } |
| | | |
| | | let LText = `select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows` |
| | | let LText = ` select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows ` |
| | | let DateCount = `select count(1) as total from ${_dataresource} ${_search}` |
| | | |
| | | param.LText = Utils.formatOptions(LText) |
| | |
| | | _search = '' |
| | | } |
| | | |
| | | let LText = `select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows` |
| | | let LText = ` select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${_orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows ` |
| | | let DateCount = `select count(1) as total from ${_dataresource} ${_search}` |
| | | |
| | | param.LText = Utils.formatOptions(LText) |
| | |
| | | } |
| | | |
| | | param.excel_in_type = 'true' |
| | | param.LText_insert = Utils.formatOptions(result.insert) |
| | | param.LText_bottom = Utils.formatOptions(result.bottom) |
| | | param.LText1 = Utils.formatOptions(result.insert) |
| | | param.LText2 = Utils.formatOptions(result.bottom) |
| | | param.LText = Utils.formatOptions(result.sql) |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | |
| | | param.BID = this.props.BID |
| | | } |
| | | |
| | | param.LText = Utils.formatOptions(script) |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(script) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | |
| | |
| | | let LText = '' |
| | | |
| | | if (setting.default !== 'false' && !pagination) { |
| | | LText = `select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${orderBy}) as rows from ${_dataresource} ${_search}) tmptable order by tmptable.rows` |
| | | LText = ` select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${orderBy}) as rows from ${_dataresource} ${_search}) tmptable order by tmptable.rows ` |
| | | } else if (setting.default !== 'false') { |
| | | LText = `select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows` |
| | | LText = ` select top ${pageSize} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${orderBy}) as rows from ${_dataresource} ${_search}) tmptable where rows > ${pageSize * (pageIndex - 1)} order by tmptable.rows ` |
| | | } |
| | | |
| | | if (param.custom_script) { |
| | |
| | | LText += ` |
| | | aaa: |
| | | if @ErrorCode!='' |
| | | insert into tmp_err_retmsg (ID, ErrorCode, retmsg, CreateUserID) select @time_id@,@ErrorCode, @retmsg,@UserID@ |
| | | insert into tmp_err_retmsg (ID, ErrorCode, retmsg, CreateUserID) select @time_id@,@ErrorCode, @retmsg,@UserID@ |
| | | ` |
| | | } else { |
| | | param.custom_script += ` |
| | |
| | | param.LText = param.LText.replace(/@\$|\$@/ig, '') |
| | | } |
| | | |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } |
| | |
| | | param.LText = param.LText.replace(/@\$|\$@/ig, '') |
| | | } |
| | | |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } else if (btn.sql) { |
| | |
| | | } else { |
| | | param.LText = param.LText.replace(/@\$|\$@/ig, '') |
| | | } |
| | | |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } |
| | |
| | | param.LText = param.LText.replace(/@\$|\$@/ig, '') |
| | | } |
| | | |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } |
| | |
| | | param.LText = param.LText.replace(/@\$|\$@/ig, '') |
| | | } |
| | | |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } else if (btn.sql) { |
| | |
| | | param.LText = param.LText.replace(/@\$|\$@/ig, '') |
| | | } |
| | | |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | let { LText, LText1, LText2 } = Utils.sPCInUpDeFormatOptions(param.LText) |
| | | |
| | | param.LText2 = LText2 |
| | | param.LText1 = LText1 |
| | | param.LText = LText |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000' |
| | | param.secretkey = Utils.encrypt(param.LText, param.timestamp) |
| | | } |
| | |
| | | } |
| | | |
| | | let _sql = `Declare @${btn.sheet} table (${usefulfields.map(item => item.Column + ' ' + item.type).join(',')},jskey nvarchar(50) ) |
| | | Declare @UserName nvarchar(50),@FullName nvarchar(50),@ErrorCode nvarchar(50), @retmsg nvarchar(4000) |
| | | Declare @UserName nvarchar(50),@FullName nvarchar(50),@ErrorCode nvarchar(50), @retmsg nvarchar(4000),@tbid Nvarchar(512) |
| | | Select @ErrorCode='', @retmsg='' |
| | | ` |
| | | |
| | |
| | | static getuuid () { |
| | | let uuid = [] |
| | | let timestamp = new Date().getTime() |
| | | let options = '0123456789abcdefghigklmnopqrstuv' |
| | | let _options = '0123456789abcdefghigklmnopqrstuv' |
| | | for (let i = 0; i < 19; i++) { |
| | | uuid.push(options.substr(Math.floor(Math.random() * 0x20), 1)) |
| | | uuid.push(_options.substr(Math.floor(Math.random() * 0x20), 1)) |
| | | } |
| | | uuid = timestamp + uuid.join('') |
| | | return uuid |
| | |
| | | } |
| | | |
| | | return value |
| | | } |
| | | |
| | | /** |
| | | * @description sPC_TableData_InUpDe sql加密 |
| | | * @return {String} value |
| | | */ |
| | | static sPCInUpDeFormatOptions (value) { |
| | | if (!value) return {LText: '', LText1: '', LText2: ''} |
| | | |
| | | let salt = 'minKe' // 盐值 |
| | | // 关键字转换规则 |
| | | let format = [ |
| | | { key: 'select', value: ' msltk ' }, |
| | | { key: 'from', value: ' mfrmk ' }, |
| | | { key: 'where', value: ' mwhrk ' }, |
| | | { key: 'order by', value: ' modbk ' }, |
| | | { key: 'asc', value: ' modack ' }, |
| | | { key: 'desc', value: ' moddesk ' }, |
| | | { key: 'top', value: ' mtpk ' }, |
| | | { key: 'like', value: ' mlkk ' }, |
| | | { key: 'not like', value: ' mnlkk ' }, |
| | | { key: 'between', value: ' mbtnk ' }, |
| | | { key: 'and', value: ' madk ' }, |
| | | { key: 'insert', value: ' mistk ' }, |
| | | { key: 'into', value: ' mitk ' }, |
| | | { key: 'update', value: ' muptk ' }, |
| | | { key: 'delete', value: ' mdelk ' }, |
| | | { key: 'begin', value: ' mbgink ' }, |
| | | { key: 'end', value: ' medk ' }, |
| | | { key: 'if', value: ' mefk ' }, |
| | | { key: 'while', value: ' mwilk ' }, |
| | | { key: 'create', value: ' mcrtk ' }, |
| | | { key: 'alter', value: ' matek ' }, |
| | | { key: 'len', value: ' mlnk ' }, |
| | | { key: 'left', value: ' mlftk ' }, |
| | | { key: 'right', value: ' mritk ' }, |
| | | { key: 'union', value: ' munok ' }, |
| | | { key: 'varchar', value: ' mvcrk ' }, |
| | | { key: 'getdate', value: ' mgtdtk ' }, |
| | | { key: 'TRY', value: ' mtryonek ' }, |
| | | { key: 'TRAN', value: ' mtrnk ' }, |
| | | { key: 'goto', value: ' mgtk ' }, |
| | | { key: 'set', value: ' mstk ' }, |
| | | { key: 'ROLLBACK', value: ' mrlbkk ' } |
| | | ] |
| | | |
| | | value = value.replace(/\n/ig, ' \n ') |
| | | // 替换关键字 |
| | | format.forEach(item => { |
| | | let reg = new RegExp('(^|\\s)' + item.key + '(\\s|$)', 'ig') |
| | | value = value.replace(reg, item.value) |
| | | }) |
| | | |
| | | // 1、替换%符(数据库中解析后sql报错) |
| | | value = value.replace(/%/ig, ' mpercent ') |
| | | |
| | | let encodesql = (val) => { |
| | | if (!val) return '' |
| | | |
| | | let _value = window.btoa(window.encodeURIComponent(val)) |
| | | |
| | | // 插入字符 |
| | | let index = Math.floor(_value.length / 2) |
| | | _value = _value.slice(0, index) + salt + _value.slice(index) |
| | | |
| | | // base64加密 |
| | | return window.btoa(_value) |
| | | } |
| | | |
| | | // 注:LText 与 LText1 顺序颠倒 |
| | | return { |
| | | LText: encodesql(value.substring(5000, 10000)), |
| | | LText1: encodesql(value.substring(0, 5000)), |
| | | LText2: encodesql(value.substring(10000)) |
| | | } |
| | | } |
| | | |
| | | /** |
| | |
| | | Delete @${item.sheet} |
| | | |
| | | aaa: select @ErrorCode as ErrorCode,@retmsg as retmsg` |
| | | |
| | | let fsql = `${_sql}${_sqlInsert}${_sqlBottom}` |
| | | fsql = fsql.replace(/\n\s{8}/ig, '\n') |
| | | console.log(fsql) |
| | | |
| | | if (window.GLOB.systemType !== 'official') { |
| | | let fsql = ` |
| | | ${_sql} |
| | | ${_sqlInsert} |
| | | |
| | | /* excel数据(前40条) */ |
| | | ${_Ltext.slice(0, 40).join(' Union all ')} |
| | | ${_sqlBottom} |
| | | ` |
| | | fsql = fsql.replace(/\n\s{8}/ig, '\n') |
| | | console.log(fsql) |
| | | } |
| | | } else { // s_sDataDictb_excelIn 云端密钥验证参数 |
| | | _sql = ` |
| | | /* 系统生成 */ |
| | |
| | | _sql += ` |
| | | aaa: select @ErrorCode as ErrorCode,@retmsg as retmsg` |
| | | |
| | | _sql = _sql.replace(/\n\s{8}/ig, '\n') |
| | | console.log(_sql) |
| | | if (window.GLOB.systemType !== 'official') { |
| | | _sql = _sql.replace(/\n\s{8}/ig, '\n') |
| | | console.log(_sql) |
| | | } |
| | | |
| | | return _sql |
| | | } |
| | | } |
| | |
| | | >.ant-tabs { |
| | | >.ant-tabs-bar { |
| | | border-bottom: 1px solid #181F29; |
| | | margin-bottom: 0px; |
| | | .ant-tabs-tab { |
| | | color: rgba(255, 255, 255, 0.85); |
| | | } |