Commit 98c01432 authored by 李腾's avatar 李腾

fix: 修改筛选条件样式&商品信息添加规格

parent 900510e1
...@@ -147,7 +147,7 @@ const LogisticsForm = props => { ...@@ -147,7 +147,7 @@ const LogisticsForm = props => {
message: '请填写物流单号!', message: '请填写物流单号!',
}, },
], ],
})(<Input placeholder="请填写物流单号" />)} })(<Input maxLength={30} placeholder="请填写物流单号" />)}
</FormItem> </FormItem>
<FormItem> <FormItem>
{getFieldDecorator(`${i}-serialNumber`, { {getFieldDecorator(`${i}-serialNumber`, {
......
...@@ -36,11 +36,14 @@ const DetailModal = (props, ref) => { ...@@ -36,11 +36,14 @@ const DetailModal = (props, ref) => {
dataIndex: 'skuName', dataIndex: 'skuName',
width: 350, width: 350,
render: (value, record) => { render: (value, record) => {
const { primaryImage } = record; const { primaryImage, skuSpec } = record;
return ( return (
<div className={style['sku-info']}> <div className={style['sku-info']}>
<img src={primaryImage} width="50px" height="50px" alt="" /> <img src={primaryImage} width="50px" height="50px" alt="" />
<span className={style['sku-info__name']}>{value}</span> <div className={style['sku-info__box']}>
<p className={style['sku-info__box--name']}>{value}</p>
<p className={style['sku-info__box--spec']}>{skuSpec}</p>
</div>
</div> </div>
); );
}, },
......
...@@ -23,8 +23,15 @@ ...@@ -23,8 +23,15 @@
.sku-info { .sku-info {
display: flex; display: flex;
.sku-info__name { .sku-info__box {
margin-left: 10px; margin-left: 10px;
p {
margin: 0;
padding: 0;
}
&--spec {
color: #999;
}
} }
} }
......
...@@ -22,10 +22,10 @@ const FormSearch = props => { ...@@ -22,10 +22,10 @@ const FormSearch = props => {
} = props; } = props;
const FormItemBox = ({ bindKey, label, column, children, afterRender }) => { const FormItemBox = ({ bindKey, label, column, children, afterRender }) => {
let columnValue = column; const columnValue = column;
if (afterRender) { // if (afterRender) {
columnValue = ''; // columnValue = '';
} // }
return ( return (
<Form.Item <Form.Item
className={style['custom-form-item']} className={style['custom-form-item']}
...@@ -46,6 +46,7 @@ const FormSearch = props => { ...@@ -46,6 +46,7 @@ const FormSearch = props => {
originOptions = {}, originOptions = {},
afterRender = null, afterRender = null,
afterOptions = {}, afterOptions = {},
column,
} = config; } = config;
// 提取公共部分 // 提取公共部分
...@@ -63,10 +64,14 @@ const FormSearch = props => { ...@@ -63,10 +64,14 @@ const FormSearch = props => {
if (afterRender) { if (afterRender) {
return ( return (
<div className={style['custom-form-item-group']}> <>
{/* // <div className={style['custom-form-item-group']}> */}
<BaseSelectElement /> <BaseSelectElement />
<FormItemBox {...afterOptions}>{afterRender()}</FormItemBox> <FormItemBox column={column} {...afterOptions}>
</div> {afterRender()}
</FormItemBox>
{/* // </div> */}
</>
); );
} }
......
...@@ -27,6 +27,6 @@ ...@@ -27,6 +27,6 @@
width: 100%; width: 100%;
} }
.custom-form-item-group { // .custom-form-item-group {
display: flex; // display: flex;
} // }
...@@ -75,7 +75,7 @@ export const ORDER_STATUS = [ ...@@ -75,7 +75,7 @@ export const ORDER_STATUS = [
]; ];
export const COUPON_CODE_STATUS = { export const COUPON_CODE_STATUS = {
1: '待核销', 1: '未使用',
2: '核销', 2: '使用',
3: '取消', 3: '退款',
}; };
...@@ -124,11 +124,11 @@ const OrderList = ref => { ...@@ -124,11 +124,11 @@ const OrderList = ref => {
const baseStyle = { const baseStyle = {
style: { style: {
width: '250px', // width: '250px',
}, },
}; };
const FormSearchProps = { const FormSearchProps = {
width: '1200px', // width: '1200px',
form, form,
initialValues: { initialValues: {
orderSearch: 'orderNo', orderSearch: 'orderNo',
...@@ -141,15 +141,13 @@ const OrderList = ref => { ...@@ -141,15 +141,13 @@ const OrderList = ref => {
type: SEARCH_TYPE.SELECT, type: SEARCH_TYPE.SELECT,
label: '订单搜索', label: '订单搜索',
bindKey: 'orderSearch', bindKey: 'orderSearch',
column: 1, column: 5,
options: ORDER_SEARCH_TYPE, options: ORDER_SEARCH_TYPE,
originOptions: { originOptions: {
placeholder: '请选择', placeholder: '请选择',
...baseStyle, ...baseStyle,
}, },
afterRender: () => ( afterRender: () => <Input style={{ width: '100%' }} type="text"></Input>,
<Input style={{ width: '300px', marginLeft: '10px' }} type="text"></Input>
),
afterOptions: { afterOptions: {
bindKey: 'orderSearchValue', bindKey: 'orderSearchValue',
}, },
...@@ -157,7 +155,7 @@ const OrderList = ref => { ...@@ -157,7 +155,7 @@ const OrderList = ref => {
{ {
type: SEARCH_TYPE.RANGE_PICKER, type: SEARCH_TYPE.RANGE_PICKER,
label: '下单时间', label: '下单时间',
column: 1, column: 5,
bindKey: 'orderTime', bindKey: 'orderTime',
originOptions: { originOptions: {
placeholder: ['请选择', '请选择'], placeholder: ['请选择', '请选择'],
...@@ -167,7 +165,7 @@ const OrderList = ref => { ...@@ -167,7 +165,7 @@ const OrderList = ref => {
{ {
type: SEARCH_TYPE.INPUT, type: SEARCH_TYPE.INPUT,
label: '商品名称', label: '商品名称',
column: 4, column: 5,
bindKey: 'skuName', bindKey: 'skuName',
originOptions: { originOptions: {
placeholder: '请输入', placeholder: '请输入',
...@@ -178,7 +176,7 @@ const OrderList = ref => { ...@@ -178,7 +176,7 @@ const OrderList = ref => {
// 1-普通商品订单 2-虚拟商品订单 3-电子卡券 4-服务商品 // 1-普通商品订单 2-虚拟商品订单 3-电子卡券 4-服务商品
type: SEARCH_TYPE.SELECT, type: SEARCH_TYPE.SELECT,
label: '订单类型', label: '订单类型',
column: 4, column: 5,
bindKey: 'productType', bindKey: 'productType',
options: ORDER_TYPE, options: ORDER_TYPE,
originOptions: { originOptions: {
...@@ -189,7 +187,7 @@ const OrderList = ref => { ...@@ -189,7 +187,7 @@ const OrderList = ref => {
{ {
type: SEARCH_TYPE.SELECT, type: SEARCH_TYPE.SELECT,
label: '订单状态', label: '订单状态',
column: 1, column: 5,
bindKey: 'orderStatus', bindKey: 'orderStatus',
options: ORDER_STATUS, options: ORDER_STATUS,
originOptions: { originOptions: {
...@@ -225,11 +223,14 @@ const OrderList = ref => { ...@@ -225,11 +223,14 @@ const OrderList = ref => {
align: 'left', align: 'left',
width: 350, width: 350,
render: ({ value, subRecord }) => { render: ({ value, subRecord }) => {
const { primaryImage } = subRecord; const { primaryImage, skuSpec } = subRecord;
return ( return (
<div className={style['sku-info']}> <div className={style['sku-info']}>
<img src={primaryImage} width="50px" height="50px" alt="" /> <img src={primaryImage} width="50px" height="50px" alt="" />
<span className={style['sku-info__name']}>{value}</span> <div className={style['sku-info__box']}>
<p className={style['sku-info__box--name']}>{value}</p>
<p className={style['sku-info__box--spec']}>{skuSpec}</p>
</div>
</div> </div>
); );
}, },
......
...@@ -33,8 +33,15 @@ ...@@ -33,8 +33,15 @@
.sku-info { .sku-info {
display: flex; display: flex;
.sku-info__name { .sku-info__box {
margin-left: 10px; margin-left: 10px;
p {
margin: 0;
padding: 0;
}
&--spec {
color: #999;
}
} }
} }
......
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