| | |
| | | { |
| | | "appId": "201912040924165801464FF1788654BC5AC73", |
| | | "appkey": "20191106103859640976D6E924E464D029CF0", |
| | | "appId": "202108312122504607B107A83F55B40C98CCF", |
| | | "appkey": "20210831212235413F287EC3BF489424496C8", |
| | | "mainSystemApi": "http://sso.mk9h.cn/cloud/webapi/dostars", |
| | | "systemType": "", |
| | | "externalDatabase": "", |
| | | "lineColor": "", |
| | | "filter": "false", |
| | | "defaultApp": "mk", |
| | | "defaultApp": "mkindustry", |
| | | "defaultLang": "zh-CN", |
| | | "WXAppID": "", |
| | | "WXminiAppID": "", |
| | |
| | | "transfer": "false", |
| | | "keepPassword": "true", |
| | | "platforms": ["H5", "wechat", "android", "ios", "wxMiniProgram"], |
| | | "host": "http://qingqiumarket.cn", |
| | | "service": "MKWMS/" |
| | | "host": "http://demo.mk9h.cn", |
| | | "service": "erp_new/" |
| | | } |
| | |
| | | {field: 'voucherTypeText', values: ['createVoucher', 'checkVoucher']}, |
| | | {field: 'voucherSign', values: ['createVoucher', 'checkVoucher']}, |
| | | {field: 'supModule', values: ['checkTemp', 'checkVoucher']}, |
| | | {field: 'attachStatus', values: ['createVoucher', 'checkVoucher']}, |
| | | ] |
| | | }, |
| | | { |
| | |
| | | options: modules, |
| | | allowClear: true, |
| | | }, |
| | | { |
| | | type: 'radio', |
| | | field: 'attachStatus', |
| | | label: '附件状态', |
| | | initval: wrap.attachStatus || 0, |
| | | tooltip: '添加或修改凭证时,上传附件的状态。', |
| | | required: true, |
| | | options: [ |
| | | {value: 0, label: '待审核'}, |
| | | {value: 10, label: '已审核'}, |
| | | ] |
| | | }, |
| | | ] |
| | | |
| | | return wrapForm |
| | |
| | | }) |
| | | } |
| | | |
| | | this.props.updateConfig(config) |
| | | this.props.updateConfig(config, type) |
| | | this.setState({visible: false}) |
| | | |
| | | notification.success({ |
| | |
| | | this.updateComponent(config) |
| | | } |
| | | |
| | | parseComponent = (config, type) => { |
| | | if (type === 'cols') { |
| | | this.updatecolumn(config) |
| | | } |
| | | this.updateComponent(config) |
| | | } |
| | | |
| | | render() { |
| | | const { card } = this.state |
| | | let options = ['action', 'search', 'form', 'cols'] |
| | |
| | | <EditOutlined style={{color: '#1890ff'}} title="编辑"/> |
| | | </NormalForm> |
| | | <CopyComponent type="basetable" card={card}/> |
| | | <PasteComponent config={card} options={options} updateConfig={this.updateComponent} /> |
| | | <PasteComponent config={card} options={options} updateConfig={this.parseComponent} /> |
| | | <FontColorsOutlined className="style" title="调整样式" onClick={this.changeStyle}/> |
| | | <SettingComponent config={card} updateConfig={this.updateComponent} /> |
| | | </div> |
| | |
| | | } |
| | | |
| | | let checkAll = '' |
| | | if (config.wrap.selStyle.indexOf('check') > -1) { |
| | | if (config.wrap.selStyle && config.wrap.selStyle.indexOf('check') > -1) { |
| | | if (selectedData.length > 0) { |
| | | checkAll = selectedData.length < data.length ? ' half' : ' whole' |
| | | } |
| | |
| | | title: '', |
| | | orgcode: '', |
| | | orgname: '', |
| | | status: '' // 新建时,empty、change、saved |
| | | status: '', // 新建时,empty、change、saved |
| | | saved: false |
| | | } |
| | | |
| | | UNSAFE_componentWillMount () { |
| | |
| | | voucherSave = (list, t) => { |
| | | const { type, data, config, charInt, charType, vouDate, book, remark, charName, attachments, title, orgcode, orgname } = this.state |
| | | |
| | | let err = '' |
| | | if (!book) { |
| | | err = '请选择账套!' |
| | | } else if (!vouDate) { |
| | | err = '请选择日期!' |
| | | } else if (!charName || !charInt) { |
| | | err = '请选择凭证号!' |
| | | } |
| | | |
| | | if (err) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: '请选择账套!', |
| | | message: err, |
| | | duration: 5 |
| | | }) |
| | | return |
| | |
| | | remark: '', |
| | | tbdata: [], |
| | | charInt: res.voucher_char_int + 1, |
| | | BID: Utils.getguid() |
| | | BID: Utils.getguid(), |
| | | saved: false |
| | | }) |
| | | MKEmitter.emit('cleartable', config.uuid) |
| | | } else { |
| | | this.setState({ |
| | | status: 'saved', |
| | | charInt: res.voucher_char_int || charInt, |
| | | data: fromJS(list).toJS() |
| | | data: fromJS(list).toJS(), |
| | | saved: true |
| | | }) |
| | | } |
| | | }) |
| | |
| | | this.setState({attachments: _val}) |
| | | } |
| | | |
| | | changeVouDate = (val) => { |
| | | const { type, status, saved } = this.state |
| | | this.setState({vouDate: val}) |
| | | |
| | | if (type === 'createVoucher' && val && !saved && (status === 'empty' || status === 'change')) { |
| | | this.updateVoucherChar(val) |
| | | } |
| | | } |
| | | |
| | | updateVoucherChar = (val) => { |
| | | const {book} = this.state |
| | | |
| | | if (!book) return |
| | | |
| | | let param = { |
| | | func: 's_get_fcc_account_data', |
| | | search_type: 'Y', |
| | | fcc_date: book.months ? book.months + '-01' : moment().format('YYYY-MM-DD'), |
| | | account_year_code: book.account_year_code || '', |
| | | months: moment(val).format('YYYY-MM'), |
| | | BID: book.id |
| | | } |
| | | |
| | | Api.genericInterface(param).then(res => { |
| | | if (!res.status) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: res.message, |
| | | duration: 5 |
| | | }) |
| | | return |
| | | } |
| | | |
| | | // let typeOptions = res.char || [] |
| | | // let charInt = typeOptions[0] ? typeOptions[0].voucher_char_int + 1 : 1 |
| | | |
| | | // this.setState({ |
| | | // typeOptions: typeOptions, |
| | | // charType: typeOptions[0] ? typeOptions[0].voucher_class : '', |
| | | // charName: typeOptions[0] ? typeOptions[0].voucher_char : '', |
| | | // charInt: charInt, |
| | | // orgcode: res.orgcode, |
| | | // orgname: res.orgname, |
| | | // }) |
| | | }) |
| | | } |
| | | |
| | | triggermore = () => { |
| | | |
| | | } |
| | |
| | | <InputNumber precision={0} min={1} value={charInt} autoComplete="off" onChange={(val) => this.setState({charInt: val})}/> 号 |
| | | </div> |
| | | <div className="voucher-date"> |
| | | 日期:<DatePicker value={vouDate} onChange={(val) => this.setState({vouDate: val})}/> |
| | | 日期:<DatePicker value={vouDate} onChange={this.changeVouDate}/> |
| | | </div> |
| | | <div className="voucher-text"> |
| | | <Input value={title} placeholder="凭证文本" autoComplete="off" onChange={(e) => this.setState({title: e.target.value})}/> |
| | |
| | | _resolve() |
| | | |
| | | if (res.status) { |
| | | notification.success({ |
| | | top: 92, |
| | | message: '升级成功', |
| | | duration: 2 |
| | | }) |
| | | |
| | | delete urlparam.type |
| | | delete urlparam.MenuType |
| | | |
| | | let _param = window.btoa(window.encodeURIComponent(JSON.stringify(urlparam))) |
| | | |
| | | setTimeout(() => { |
| | | window.history.replaceState(null, null, window.location.href.split('#')[0] + `#/tabledesign/${_param}`) |
| | | window.location.reload() |
| | | }, 2000) |
| | | window.history.replaceState(null, null, window.location.href.split('#')[0] + `#/tabledesign/${_param}`) |
| | | window.location.reload() |
| | | } else { |
| | | Modal.warning({ |
| | | title: res.message, |
| | |
| | | style: { backgroundColor: '#ffffff', paddingTop: '16px', paddingBottom: '80px', paddingLeft: '16px', paddingRight: '16px'}, |
| | | } |
| | | } else { |
| | | if (config.Template === 'CommonTable' && !config.components) { |
| | | let urlparam = JSON.parse(window.decodeURIComponent(window.atob(this.props.match.params.param))) |
| | | urlparam.type = 'CommonTable' |
| | | if (urlparam.PageParam) { |
| | | urlparam.PageParam.Template = 'CommonTable' |
| | | } |
| | | urlparam = window.btoa(window.encodeURIComponent(JSON.stringify(urlparam))) |
| | | |
| | | let url = `#/basedesign/${urlparam}` |
| | | |
| | | window.history.replaceState(null, null, window.location.href.split('#')[0] + url) |
| | | window.location.reload() |
| | | return |
| | | } |
| | | config.uuid = MenuId |
| | | config.MenuID = MenuId |
| | | config.Template = 'BaseTable' |