|
@@ -17,7 +17,6 @@ import styles from './index.less';
|
|
|
mproduct: state.mproduct,
|
|
|
}))
|
|
|
export default class CreateOrder extends Component {
|
|
|
-
|
|
|
// 终端选择弹框相关的回调方法
|
|
|
handleTerminalSelectBtnClick = () => {
|
|
|
this.props.dispatch({ type: 'orderDetail/showTerminalModal' });
|
|
@@ -26,7 +25,7 @@ export default class CreateOrder extends Component {
|
|
|
payload: {
|
|
|
pageNo: 1,
|
|
|
pageSize,
|
|
|
- }
|
|
|
+ },
|
|
|
});
|
|
|
}
|
|
|
|
|
@@ -39,7 +38,7 @@ export default class CreateOrder extends Component {
|
|
|
campusName: record.campusName,
|
|
|
merchantName: record.merchantName,
|
|
|
merchantId: record.merchantId,
|
|
|
- }
|
|
|
+ },
|
|
|
});
|
|
|
}
|
|
|
|
|
@@ -111,20 +110,20 @@ export default class CreateOrder extends Component {
|
|
|
cpPrice: 2000,
|
|
|
merchantPrice: 3000,
|
|
|
terminalPrice: 4000,
|
|
|
- },{
|
|
|
+ }, {
|
|
|
id: '2',
|
|
|
chargeUnit: '半年',
|
|
|
cpPrice: 1000,
|
|
|
merchantPrice: 2000,
|
|
|
terminalPrice: 3000,
|
|
|
- },{
|
|
|
+ }, {
|
|
|
id: '3',
|
|
|
chargeUnit: '季',
|
|
|
cpPrice: 500,
|
|
|
merchantPrice: 800,
|
|
|
terminalPrice: 1000,
|
|
|
}],
|
|
|
- },{
|
|
|
+ }, {
|
|
|
id: 'package-1',
|
|
|
code: '课程包-01',
|
|
|
name: '小学一年级语文课程包',
|
|
@@ -132,7 +131,7 @@ export default class CreateOrder extends Component {
|
|
|
coverUrl: 'https://os.alipayobjects.com/rmsportal/QBnOOoLaAfKPirc.png',
|
|
|
goods: [{
|
|
|
|
|
|
- }]
|
|
|
+ }],
|
|
|
}],
|
|
|
};
|
|
|
const { userCode, userName, campusName, merchantName, merchantId, products } = currentItem;
|
|
@@ -156,7 +155,7 @@ export default class CreateOrder extends Component {
|
|
|
render: (text, record) => (
|
|
|
<Popover
|
|
|
content={
|
|
|
- <Card hoverable style={{ width: 350, height: 550 }} cover={<img alt="" src={text}/>}>
|
|
|
+ <Card hoverable style={{ width: 350, height: 550 }} cover={<img alt="" src={text} />}>
|
|
|
<Card.Meta
|
|
|
title={`${record.name}/${record.code}`}
|
|
|
description={`类型: ${productType[record.type]}`}
|
|
@@ -167,7 +166,7 @@ export default class CreateOrder extends Component {
|
|
|
<img src={text} width={50} />
|
|
|
</Popover>
|
|
|
),
|
|
|
- },{
|
|
|
+ }, {
|
|
|
title: '价格类型',
|
|
|
dataIndex: 'goods',
|
|
|
key: 1,
|
|
@@ -181,7 +180,7 @@ export default class CreateOrder extends Component {
|
|
|
><a>付费方式<Icon type="down" /></a>
|
|
|
</Dropdown>
|
|
|
),
|
|
|
- },{
|
|
|
+ }, {
|
|
|
title: '优惠价格',
|
|
|
dataIndex: 'adjustPrice',
|
|
|
key: 2,
|
|
@@ -193,11 +192,11 @@ export default class CreateOrder extends Component {
|
|
|
parser={value => value.replace(/\¥\s?|(,*)/g, '')}
|
|
|
/>
|
|
|
),
|
|
|
- },{
|
|
|
+ }, {
|
|
|
title: '实际售价',
|
|
|
dataIndex: 'finalPrice',
|
|
|
key: 3,
|
|
|
- },{
|
|
|
+ }, {
|
|
|
title: '数量',
|
|
|
dataIndex: 'quantity',
|
|
|
key: 4,
|
|
@@ -209,7 +208,7 @@ export default class CreateOrder extends Component {
|
|
|
parser={value => value.replace(/\x\s?|(,*)/g, '')}
|
|
|
/>
|
|
|
),
|
|
|
- },{
|
|
|
+ }, {
|
|
|
title: '单位',
|
|
|
dataIndex: 'chargeUnit',
|
|
|
key: 5,
|
|
@@ -221,7 +220,7 @@ export default class CreateOrder extends Component {
|
|
|
<Form>
|
|
|
<Form.Item label="选择终端" {...formItemLayout}>
|
|
|
<Button onClick={this.handleTerminalSelectBtnClick} type="primary" size="small" icon="plus-circle-o">选择</Button>
|
|
|
- {userCode ?
|
|
|
+ {userCode ? (
|
|
|
<List
|
|
|
size="small"
|
|
|
bordered
|
|
@@ -229,16 +228,16 @@ export default class CreateOrder extends Component {
|
|
|
dataSource={[`终端编号: ${userCode}`, `终端名称: ${userName}`, `所属校区: ${campusName}`, `所属渠道: ${merchantName}`]}
|
|
|
renderItem={item => <List.Item>{item}</List.Item>}
|
|
|
/>
|
|
|
- : null}
|
|
|
+) : null}
|
|
|
</Form.Item>
|
|
|
<Form.Item label="收货地址" {...formItemLayout}>
|
|
|
- <Input.TextArea style={{ width: "50%" }} placeholder="请填写或使用默认地址"/>
|
|
|
+ <Input.TextArea style={{ width: '50%' }} placeholder="请填写或使用默认地址" />
|
|
|
</Form.Item>
|
|
|
<Form.Item label="添加备注" {...formItemLayout}>
|
|
|
- <Input.TextArea style={{ width: "50%" }} placeholder="请输入(选填)" />
|
|
|
+ <Input.TextArea style={{ width: '50%' }} placeholder="请输入(选填)" />
|
|
|
</Form.Item>
|
|
|
<Form.Item label="添加商品" {...formItemLayout}>
|
|
|
- <Button onClick={this.handleProductSelectBtnClick} disabled={merchantId ? false : true} type="primary" size="small" icon="plus-circle-o">添加</Button>
|
|
|
+ <Button onClick={this.handleProductSelectBtnClick} disabled={!merchantId} type="primary" size="small" icon="plus-circle-o">添加</Button>
|
|
|
<Table
|
|
|
size="large"
|
|
|
className={styles.table}
|
|
@@ -249,7 +248,7 @@ export default class CreateOrder extends Component {
|
|
|
/>
|
|
|
</Form.Item>
|
|
|
</Form>
|
|
|
- {/*终端选择弹框*/}
|
|
|
+ {/* 终端选择弹框 */}
|
|
|
<TerminalSelectModal
|
|
|
rowKeyName="id"
|
|
|
modalVisible={terminalModalShow}
|
|
@@ -263,7 +262,7 @@ export default class CreateOrder extends Component {
|
|
|
fsTablePagination={terminal.pagination}
|
|
|
fsTableOnChange={this.handleTerminalModalTableChange}
|
|
|
/>
|
|
|
- {/*渠道产品选择弹框*/}
|
|
|
+ {/* 渠道产品选择弹框 */}
|
|
|
<MerchantProductSelectModal
|
|
|
rowKeyName="id"
|
|
|
modalVisible={productModalShow}
|
|
@@ -287,8 +286,7 @@ export default class CreateOrder extends Component {
|
|
|
<Menu.Item>¥2000 / 季</Menu.Item>
|
|
|
</Menu>
|
|
|
}
|
|
|
- >
|
|
|
- </Dropdown.Button>
|
|
|
+ />
|
|
|
<Button>取消</Button>
|
|
|
<Button type="primary">完成</Button>
|
|
|
</FooterToolbar>
|