Commit 3c13ba52 by YuMengShuai

出口保函开例

parent c8b0d3ea
import React,{Component,Fragment} from 'react'
import PropTypes from 'prop-types'
import {Page, Validator, Notification, BottomBtn,FormItem, DatePickerItem, TextAreaItem, CheckboxItem, Checkbox,
InputItem, Input, Bind, SelectItem, Button, Label, Image, Table} from '@/components/Common-Library'
import Api from '@/service/api'
import CodeTableFactory from '@/components/CodeTable'
import "./index.less"
import Business from '@/views/Public/Business'
import { inject, observer } from 'mobx-react'
import { action, observable,runInAction } from 'mobx'
import { Row, Col } from 'antd'
const CodeTable = CodeTableFactory.getInstance()
@inject('UserContext')
@inject('i18n')
@observer
export default class GetopnScreen extends Page
{
static childContextTypes = {
trn: PropTypes.string,
}
getChildContext () {
return {trn:'getopn'}
}
@observable
formBlur=false
constructor(props)
{
super(props)
this.model = props.model
this.bind = Bind.bind(this)
}
async componentWillMount()
{
/*
*添加初始化代码
*/
const rtnmsg = await Api.post('getopn/init',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
const {data} = rtnmsg
runInAction(()=>{
Object.assign(this.model,data)
})
}
//快照模式下,不必开启校验,否则,静默校验,和记录变动
!this.loadDisplay() && this.model.openMonitor && this.model.openMonitor() //开启校验
}
componentWillUnmount()
{
this.model.stopMonitor&&this.model.stopMonitor()//关闭校验
}
//按钮事件
onAplp_sel= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/aplp_sel',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onChk= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/chk',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onSetmod_ast= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/setmod_ast',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onSav= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/sav',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onSetmod_recal= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/setmod_recal',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onAdvp_sel= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/advp_sel',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onPed= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/ped',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onPts4_adrblk= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/pts4_adrblk',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onPts2_adrblk= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/pts2_adrblk',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onBenp_sel= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/benp_sel',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onGetref= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/getref',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onPts_adrblk= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/pts_adrblk',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onPts1_adrblk= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/pts1_adrblk',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onPts3_adrblk= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/pts3_adrblk',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onExi= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/exi',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onMax_amt= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/max_amt',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onGlemod_rebook= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/glemod_rebook',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onTrndoc_butshw= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/trndoc_butshw',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onSetmod_feedet= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/setmod_feedet',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onTrndoc_reldoc= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/trndoc_reldoc',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onConp_sel= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/conp_sel',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onIssp_sel= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/issp_sel',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
//交易内实现
renderPage(){
const bind = this.bind
const {i18n} = this.props
return (
<div className="transPage">
<Business wrappedComponentRef={ref => (this.com = ref)} extra={this.props.extra} model={this.model} />
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Text of Undertaking" trn="getopn" />
</Col>
</Row>
</Col>
</Row>
{/* 第16行 */}
<Row>
<Col span={20}>
<Row className="row">
<Col span={20} offset={1}>
<TextAreaItem InputProps={bind("blk_gidtxt")} desp="Guarantee Text" path="/gidgrp/blk/gidtxt" style={{height:'255px'}}/>
</Col>
</Row>
</Col>
<Col span={4}>
<Row className="row">
<Col span={16} offset={1}>
<CheckboxItem InputProps={bind("gitp_gidtxtmodflg")} desp="Modify Guarantee Text" path="/gitp/gidtxtmodflg" />
</Col>
</Row>
<Row className="row">
<Col span={16} offset={1}>
<Button type="primary" onClick={this.onGitp_butdif} desp="Diff. syst.text" path="/gitp/butdif">
<Label itext="vs. S&ystem"/>
</Button>
</Col>
</Row>
<Row className="row">
<Col span={16} offset={1}>
<Button type="primary" onClick={this.onGitp_butdifhis} desp="Diff. prev.text" path="/gitp/butdifhis">
<Label itext="vs. &History"/>
</Button>
</Col>
</Row>
<Row className="row">
<Col span={16} offset={1}>
<Button type="primary" onClick={this.onGitp_shwgidtxt} desp="Show Text" path="/gitp/shwgidtxt">
<Label itext="Sho&w Text"/>
</Button>
</Col>
</Row>
<Row className="row">
<Col span={16} offset={1}>
<Button type="primary" onClick={this.onGitp_butgetref} desp="Get Ref." path="/gitp/butgetref">
<Label itext="Get &Ref."/>
</Button>
</Col>
</Row>
</Col>
</Row>
{/* 底部按钮 */}
<BottomBtn _this={this} />
</div>
)
}
}
\ No newline at end of file
import React,{Component,Fragment} from 'react'
import PropTypes from 'prop-types'
import {Page, Validator, Notification, BottomBtn,FormItem, DatePickerItem, TextAreaItem, CheckboxItem, Checkbox,
InputItem, Input, Bind, SelectItem, Button, Label, Image, Table} from '@/components/Common-Library'
import Api from '@/service/api'
import Business from '@/views/Public/Business'
import CodeTableFactory from '@/components/CodeTable'
import "./index.less"
import { inject, observer } from 'mobx-react'
import { action, observable,runInAction } from 'mobx'
import { Row, Col } from 'antd'
const CodeTable = CodeTableFactory.getInstance()
@inject('UserContext')
@inject('i18n')
@observer
export default class GetopnScreen extends Page
{
static childContextTypes = {
trn: PropTypes.string,
}
getChildContext () {
return {trn:'getopn'}
}
@observable
formBlur=false
constructor(props)
{
super(props)
this.model = props.model
this.bind = Bind.bind(this)
}
async componentWillMount()
{
/*
*添加初始化代码
*/
const rtnmsg = await Api.post('getopn/init',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
const {data} = rtnmsg
runInAction(()=>{
Object.assign(this.model,data)
})
}
//快照模式下,不必开启校验,否则,静默校验,和记录变动
!this.loadDisplay() && this.model.openMonitor && this.model.openMonitor() //开启校验
}
componentWillUnmount()
{
this.model.stopMonitor&&this.model.stopMonitor()//关闭校验
}
//
onGetref = () => {
this.formBlur = true //已触发表单提交处理
Validator.validate(this.model, this.model.descriptor, async (errors, values) => {
if (errors)
return
const rtnmsg = await Api.post('getopn/getref', { data: this.model })
if (rtnmsg.retcod == SUCCESS) {
this.model.ownref = rtnmsg.data.ownref;
}
else {
Notification.error({ message: '服务端请求失败!' })
}
//余下逻辑处理
})
}
onAplp_sel = () => {
this.formBlur = true //已触发表单提交处理
Validator.validate(this.model, this.model.descriptor, async (errors, values) => {
if (errors)
return
const rtnmsg = await Api.post('getopn/aplp_sel', { data: this.model })
if (rtnmsg.retcod == SUCCESS) {
console.log(rtnmsg)
this.model.pts1_extkey = rtnmsg.data.pts1_extkey;
}
else {
Notification.error({ message: '服务端请求失败!' })
}
//余下逻辑处理
})
}
onAdvp_sel = () => {
this.formBlur = true //已触发表单提交处理
Validator.validate(this.model, this.model.descriptor, async (errors, values) => {
if (errors)
return
const rtnmsg = await Api.post('getopn/advp_sel', { data: this.model })
if (rtnmsg.retcod == SUCCESS) {
console.log(rtnmsg)
this.model.pts_extkey = rtnmsg.data.pts_extkey;
}
else {
Notification.error({ message: '服务端请求失败!' })
}
//余下逻辑处理
})
}
onBenp_sel = () => {
this.formBlur = true //已触发表单提交处理
Validator.validate(this.model, this.model.descriptor, async (errors, values) => {
if (errors)
return
const rtnmsg = await Api.post('getopn/benp_sel', { data: this.model })
if (rtnmsg.retcod == SUCCESS) {
console.log(rtnmsg)
this.model.pts2_extkey = rtnmsg.data.pts2_extkey;
}
else {
Notification.error({ message: '服务端请求失败!' })
}
//余下逻辑处理
})
}
//交易内实现
renderPage(){
const bind = this.bind
const {i18n} = this.props
return (
<div className="transPage">
<Business wrappedComponentRef={ref => (this.com = ref)} extra={this.props.extra} model={this.model} />
{/* 第1行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Reference" trn="getopn" />
</Col>
<Col span={11} >
<InputItem InputProps={bind("ownref")} maxLength={16} desp="Reference" path="/gidgrp/rec/ownref" />
</Col>
<Col span={2} offset={1}>
<Button type="primary" onClick={this.onGetref} desp="Get Ref." path="/mtabut/getref">
<Label itext="获取" />
</Button>
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Name" trn="getopn" />
</Col>
<Col span={14}>
<InputItem InputProps={bind("nam")} maxLength={40} desp="Externally Displayed Name to Identify the Contract" path="/gidgrp/rec/nam" />
</Col>
</Row>
</Col>
</Row>
{/* 第2行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Responsible" trn="getopn" />
</Col>
<Col span={14}>
<InputItem InputProps={bind("usr_nam")} maxLength={8} desp="用户ID" path="/gitp//sysmod/usr/nam" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Reserved Contract" trn="getopn" />
</Col>
<Col span={14}>
<CheckboxItem InputProps={bind("resflg")} desp="Reserved Contract" path="/gidgrp/rec/resflg" />
</Col>
</Row>
</Col>
</Row>
{/* 第3行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Guarantee Amount" trn="getopn" />
</Col>
<Col span={6}>
<SelectItem InputProps={bind("max_cur")} code={CodeTable.curtxt} desp="Currency" path="/gidgrp/cbs/max/cur" />
</Col>
<Col span={7} offset={1}>
<InputItem InputProps={bind("max_amt")} desp="Balance" path="/gidgrp/cbs/max/amt" />
</Col>
</Row>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="drprtflglab" trn="getopn" />
<Label value={this.model.gitp_drpreflglab} desp="Label for Type of Request" path="/gitp/drpreflglab" />
</Col>
<Col span={14} >
<SelectItem InputProps={bind("gitp_drpreflg")} code={CodeTable.drpreflg} desp="Type of Request" path="/gitp/drpreflg" />
</Col>
</Row>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Handling Type" trn="getopn" />
</Col>
<Col span={14} >
<SelectItem InputProps={bind("hndtyp")} code={CodeTable.hndtyp} desp="Handling Type" path="/gidgrp/rec/hndtyp" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Applicant Ref." trn="getopn" />
</Col>
<Col span={14}>
<InputItem InputProps={bind("pts1_ref")} maxLength={16} desp="参考号" path="/gidgrp/apl/pts/ref" />
</Col>
</Row>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="客户编号" trn="getopn" />
</Col>
<Col span={11} >
<InputItem InputProps={bind("pts1_extkey")} maxLength={16} desp="客户编号" path="/gidgrp/apl/pts/extkey" />
</Col>
<Col span={2} offset={1} >
<Button type="primary" icon="search" onClick={this.onAplp_sel} desp="查询" path="/gitp/aplp/sel">
<Label itext="查询" />
</Button>
</Col>
</Row>
<Row className="row">
<Col span={11} offset={7}>
<TextAreaItem InputProps={bind("pts3_adrblk")} desp="SWIFT地址" path="/gidgrp/con/pts/adrblk" />
</Col>
</Row>
</Col>
</Row>
<Row>
<Col span={12}>
<Row className='row'>
<Col span={5} offset={2}>
<Label itext="Open Amount" trn="getopn" />
</Col>
<Col span={6} >
<SelectItem InputProps={bind("opn1_cur")} code={CodeTable.curtxt} desp="Currency" path="/gidgrp/cbs/opn1/cur" />
</Col>
<Col span={7} offset={1}>
<InputItem InputProps={bind("opn1_amt")} desp="Balance" path="/gidgrp/cbs/opn1/amt" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className='row'>
<Col span={5} offset={2}>
<Label itext="Add. Amount" trn="getopn" />
</Col>
<Col span={1}>
<CheckboxItem InputProps={bind("aammod_addamtflg")} desp="Add. Amount" path="/gitp/aamp/aammod/addamtflg" />
</Col>
</Row>
</Col>
</Row>
{/* 第5行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Type of Undertaking" trn="getopn" />
</Col>
<Col span={14} >
<SelectItem InputProps={bind("gartyp")} code={CodeTable.typgar} desp="Type of Undertaking" path="/gidgrp/rec/gartyp" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="境内外对手行代码" trn="getopn" />
</Col>
<Col span={14} >
<InputItem InputProps={bind("oppbnk")} maxLength={12} desp="境内外对手行代码" path="/gidgrp/rec/oppbnk" />
</Col>
</Row>
</Col>
</Row>
{/* 第8行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="面函标题" trn="getopn" />
</Col>
<Col span={14} >
<InputItem InputProps={bind("gitp_lettername")} maxLength={60} desp="面函标题" path="/gitp/lettername" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Applicable Rules" trn="getopn" />
</Col>
<Col span={6} >
<SelectItem InputProps={bind("blk_apprul")} code={CodeTable.gitapprul} desp="Applicable Rules" path="/gidgrp/blk/apprul" />
</Col>
<Col span={7} offset={1}>
<InputItem InputProps={bind("blk_apprultxt")} maxLength={35} desp="Specification of Applicable Rule" path="/gidgrp/blk/apprultxt" />
</Col>
</Row>
</Col>
</Row>
{/* 第8-11行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
{/* <Label itext="Language of Undertak." trn="getopn" /> */}
<Label itext="LOU" trn="getopn" />
</Col>
<Col span={14} >
<SelectItem InputProps={bind("giduil")} code={CodeTable.uiltxt} desp="Guarantee Language" path="/gidgrp/rec/giduil" />
</Col>
</Row>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Choice of Text" trn="getopn" />
</Col>
<Col span={14} >
<SelectItem InputProps={bind("gtxinr")} desp="INR of Generating Text" path="/gidgrp/rec/gtxinr" />
</Col>
</Row>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="特殊保函类型" trn="getopn" />
</Col>
<Col span={14} >
<SelectItem InputProps={bind("ghd_segtyp")} desp="特殊保函类型" path="/gidgrp/ghd/segtyp" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Adv\Rcv bank Ref." trn="getopn" />
</Col>
<Col span={14} >
<InputItem InputProps={bind("pts_ref")} maxLength={16} desp="参考号" path="/gidgrp/adv/pts/ref" />
</Col>
</Row>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="客户编号" trn="getopn" />
</Col>
<Col span={11} >
<InputItem InputProps={bind("pts_extkey")} maxLength={16} desp="客户编号" path="/gidgrp/adv/pts/extkey" />
</Col>
<Col span={2} offset={1}>
<Button type="primary" icon="search" onClick={this.onAdvp_sel} desp="查询" path="/gitp/advp/sel">
<Label itext="查询" />
</Button>
</Col>
</Row>
<Row className="row">
<Col span={11} offset={7}>
<TextAreaItem InputProps={bind("pts_adrblk")} desp="SWIFT地址" path="/gidgrp/adv/pts/adrblk" />
</Col>
</Row>
</Col>
</Row>
{/* 第12行 */}
<Row>
<Col span={12}>
<Row className='row'>
<Col span={5} offset={2}>
<Label itext="是否分离式保函" trn="getopn" />
</Col>
<Col span={14} >
<SelectItem InputProps={bind("fenlishi")} code={CodeTable.fenlishi} desp="是否分离式保函" path="/gidgrp/rec/fenlishi" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Order Date" trn="getopn" />
</Col>
<Col span={14} >
<DatePickerItem InputProps={bind("orddat")} desp="Date of Customer's Order" path="/gidgrp/rec/orddat" />
</Col>
</Row>
</Col>
</Row>
{/* 第13-15行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Issuance Date" trn="getopn" />
</Col>
<Col span={14} >
<DatePickerItem InputProps={bind("opndat")} desp="Valid from" path="/gidgrp/rec/opndat" />
</Col>
</Row>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Old Reference" trn="getopn" />
</Col>
<Col span={14} >
<InputItem InputProps={bind("oldref")} maxLength={16} desp="Old Reference" path="/gidgrp/rec/oldref" />
</Col>
</Row>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="保函生效日" trn="getopn" />
</Col>
<Col span={14} >
<DatePickerItem InputProps={bind("inudat")} desp="Inure Date" path="/gidgrp/rec/inudat" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Beneficiary Ref." trn="getopn" />
</Col>
<Col span={14} >
<InputItem InputProps={bind("pts2_ref")} maxLength={16} desp="参考号" path="/gidgrp/ben/pts/ref" />
</Col>
</Row>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="客户编号" trn="getopn" />
</Col>
<Col span={11} >
<InputItem InputProps={bind("pts2_extkey")} maxLength={16} desp="客户编号" path="/gidgrp/ben/pts/extkey" />
</Col>
<Col span={2} offset={1} >
<Button type="primary" icon="search" onClick={this.onBenp_sel} desp="查询" path="/gitp/benp/sel">
<Label itext="查询" />
</Button>
</Col>
</Row>
<Row className="row">
<Col span={11} offset={7}>
<TextAreaItem InputProps={bind("pts2_adrblk")} desp="SWIFT地址" path="/gidgrp/ben/pts/adrblk" />
</Col>
</Row>
</Col>
</Row>
{/* 第16行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Validity until" trn="getopn" />
</Col>
<Col span={12} >
<DatePickerItem InputProps={bind("expdat")} desp="Valid until" path="/gidgrp/rec/expdat" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Unlimited Guarantee" trn="getopn" />
</Col>
<Col span={1} >
<CheckboxItem InputProps={bind("expflg")} desp="Unlimited Guarantee" path="/gidgrp/rec/expflg" />
</Col>
</Row>
</Col>
</Row>
{/* 第17行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Our Liability until" trn="getopn" />
</Col>
<Col span={14} >
<DatePickerItem InputProps={bind("liadat")} desp="Liability until" path="/gidgrp/rec/liadat" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Unlimited Liability" trn="getopn" />
</Col>
<Col span={1} >
<CheckboxItem InputProps={bind("liaflg")} desp="Unlimited Liability" path="/gidgrp/rec/liaflg" />
</Col>
</Row>
</Col>
</Row>
{/* 第18行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Mortgage Flag" trn="getopn" />
</Col>
<Col span={14} >
<SelectItem InputProps={bind("guaflg")} code={CodeTable.guaflg} desp="Mortgage Flag" path="/gidgrp/rec/guaflg" />
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Test Key Unconfirmity" trn="getopn" />
</Col>
<Col span={1} >
<CheckboxItem InputProps={bind("teskeyunc")} desp="Test Key Unconfirmity" path="/gidgrp/rec/teskeyunc" />
</Col>
</Row>
</Col>
</Row>
{/* 第19行 */}
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="是否对外担保" trn="getopn" />
</Col>
<Col span={14} >
<SelectItem InputProps={bind("fingua")} code={CodeTable.fingua} desp="是否对外担保" path="/gidgrp/rec/fingua"/>
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="担保类型" trn="getopn" />
</Col>
<Col span={12} >
<InputItem InputProps={bind("cfaguatyp")} maxLength={4} desp="对外担保类型" path="/gidgrp/rec/cfaguatyp" />
</Col>
<Col span={1} offset={1}>
<CheckboxItem InputProps={bind("cmtflg")} desp="跨境人民币保函" path="/gidgrp/rec/cmtflg" />
</Col>
</Row>
</Col>
</Row>
<BottomBtn _this={this} />
</div>
)
}
}
import React,{Component,Fragment} from 'react'
import PropTypes from 'prop-types'
import {Page, Validator, Notification, BottomBtn,FormItem, DatePickerItem, TextAreaItem, CheckboxItem, Checkbox,
InputItem, Input, Bind, SelectItem, Button, Label, Image, Table} from '@/components/Common-Library'
import Api from '@/service/api'
import Business from '@/views/Public/Business'
import CodeTableFactory from '@/components/CodeTable'
import "./index.less"
import { inject, observer } from 'mobx-react'
import { action, observable,runInAction } from 'mobx'
import { Row, Col } from 'antd'
const CodeTable = CodeTableFactory.getInstance()
@inject('UserContext')
@inject('i18n')
@observer
export default class GetopnScreen extends Page
{
static childContextTypes = {
trn: PropTypes.string,
}
getChildContext () {
return {trn:'getopn'}
}
@observable
formBlur=false
constructor(props)
{
super(props)
this.model = props.model
this.bind = Bind.bind(this)
}
async componentWillMount()
{
/*
*添加初始化代码
*/
const rtnmsg = await Api.post('getopn/init',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
const {data} = rtnmsg
runInAction(()=>{
Object.assign(this.model,data)
})
}
//快照模式下,不必开启校验,否则,静默校验,和记录变动
!this.loadDisplay() && this.model.openMonitor && this.model.openMonitor() //开启校验
}
componentWillUnmount()
{
this.model.stopMonitor&&this.model.stopMonitor()//关闭校验
}
onConp_sel= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/conp_sel',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
onIssp_sel= ()=>{
this.formBlur=true //已触发表单提交处理
Validator.validate(this.model,this.model.descriptor,async(errors,values)=>{
if(errors)
return
const rtnmsg = await Api.post('getopn/issp_sel',{data:this.model})
if(rtnmsg.retcod == SUCCESS)
{
Notification.success({message:'数据提交成功!'})
}
else
{
Notification.error({message:'服务端请求失败!'})
}
//余下逻辑处理
})
}
//交易内实现
renderPage(){
const bind = this.bind
const {i18n} = this.props
return (
<div className="transPage">
<Business wrappedComponentRef={ref => (this.com = ref)} extra={this.props.extra} model={this.model} />
<Row>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Confirming Bank's Ref. " trn="getopn" />
</Col>
<Col span={14} >
<InputItem InputProps={bind("pts3_ref")} maxLength={16} desp="参考号" path="/gidgrp/con/pts/ref" />
</Col>
</Row>
<Row className='row'>
<Col span={11} offset={7} >
<InputItem InputProps={bind("pts3_extkey")} maxLength={16} desp="客户编号" path="/gidgrp/con/pts/extkey" />
</Col>
<Col span={2} offset={1} >
<Button type="primary" icon="search" onClick={this.onConp_sel} desp="查询" path="/gitp/conp/sel">
<Label itext="查询" />
</Button>
</Col>
</Row>
<Row className='row'>
<Col span={11} offset={7}>
<TextAreaItem InputProps={bind("pts3_adrblk")} desp="SWIFT地址" path="/gidgrp/con/pts/adrblk"/>
</Col>
</Row>
</Col>
<Col span={12}>
<Row className="row">
<Col span={5} offset={2}>
<Label itext="Confirming Bank's Ref. " trn="getopn" />
</Col>
<Col span={14} >
<InputItem InputProps={bind("pts4_ref")} maxLength={16} desp="参考号" path="/gidgrp/iss/pts/ref" />
</Col>
</Row>
<Row className="row">
<Col span={11} offset={7}>
<InputItem InputProps={bind("pts4_extkey")} maxLength={16} desp="客户编号" path="/gidgrp/iss/pts/extkey" />
</Col>
<Col span={2} offset={1}>
<Button type="primary" icon="search" onClick={this.onIssp_sel} desp="查询" path="/gitp/issp/sel">
<Label itext="查询" />
</Button>
</Col>
</Row>
<Row className="row">
<Col span={11} offset={7}>
<TextAreaItem InputProps={bind("pts4_adrblk")} desp="SWIFT地址" path="/gidgrp/iss/pts/adrblk"/>
</Col>
</Row>
</Col>
</Row>
{/* 底部按钮 */}
<BottomBtn _this={this} />
</div>
)
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment