订单列表新增下拉筛选状态
This commit is contained in:
parent
4c347bf71e
commit
8670b0b8ca
|
@ -203,19 +203,32 @@ export default class orderlist extends React.Component {
|
|||
{ id: 4, name: "直充-已取消" },
|
||||
{ id: 111, name: "立减金-待领取" },
|
||||
{ id: 222, name: "立减金-已领取" },
|
||||
{ id: 5, name: "立减金-已过期" },
|
||||
{ id: 6, name: "优惠券-待支付" }
|
||||
{ id: 5, name: "立减金-已过期" }
|
||||
]
|
||||
},
|
||||
{
|
||||
id: 1,
|
||||
label: "支付状态",
|
||||
prop: "pay_status",
|
||||
menuList: [
|
||||
{ id: 1, name: "待支付" },
|
||||
{ id: 2, name: "已支付" },
|
||||
{ id: 3, name: "已退款" }
|
||||
]
|
||||
}
|
||||
],
|
||||
|
||||
selectiondata: [],
|
||||
menuList: [{ id: 0, name: "订单状态", check: false }],
|
||||
menuList: [
|
||||
{ id: 0, name: "订单状态", check: false },
|
||||
{ id: 1, name: "支付状态", check: false }
|
||||
],
|
||||
allcheck: false,
|
||||
itemcheck: false,
|
||||
combinedValue: [],
|
||||
tableHeight: 500,
|
||||
status: null,
|
||||
pay_status: null,
|
||||
page: 1,
|
||||
limit: 10,
|
||||
key_word: "",
|
||||
|
@ -286,7 +299,7 @@ export default class orderlist extends React.Component {
|
|||
//导出订单
|
||||
exportFn() {
|
||||
let _self = this
|
||||
let { key_word, key, status, option, orderType } = _self.state
|
||||
let { key_word, status, option, orderType } = _self.state
|
||||
let data = {}
|
||||
if (orderType) {
|
||||
//区分立减金和商品
|
||||
|
@ -522,7 +535,8 @@ export default class orderlist extends React.Component {
|
|||
//获取订单列表
|
||||
getOrderFn(time = {}) {
|
||||
let _self = this
|
||||
let { page, limit, option, key_word, status, orderType } = _self.state
|
||||
let { page, limit, option, key_word, status, orderType, pay_status } =
|
||||
_self.state
|
||||
let data = { page, limit }
|
||||
if (orderType) {
|
||||
//区分立减金和商品
|
||||
|
@ -532,9 +546,29 @@ export default class orderlist extends React.Component {
|
|||
data.begin_time = this.state.combinedValue[0]
|
||||
data.end_time = this.state.combinedValue[1]
|
||||
}
|
||||
|
||||
if (status || status === 0) {
|
||||
data.status = status
|
||||
}
|
||||
|
||||
if (pay_status) {
|
||||
data.pay_status = pay_status
|
||||
}
|
||||
|
||||
if (status === 6) {
|
||||
data.pay_status = 1
|
||||
data.use_coupon = 1
|
||||
}
|
||||
if (status === 7) {
|
||||
data.pay_status = 2
|
||||
data.use_coupon = 1
|
||||
}
|
||||
|
||||
if (status === 8) {
|
||||
data.pay_status = 3
|
||||
data.use_coupon = 1
|
||||
}
|
||||
|
||||
if (time && time[0]) {
|
||||
data.begin_time = time[0]
|
||||
data.end_time = time[1]
|
||||
|
@ -568,7 +602,6 @@ export default class orderlist extends React.Component {
|
|||
data.channel_activity_id = key_word
|
||||
}
|
||||
}
|
||||
|
||||
getOrderList(data)
|
||||
.then((res) => {
|
||||
handelResponse(
|
||||
|
@ -653,6 +686,9 @@ export default class orderlist extends React.Component {
|
|||
if (prevState.status != this.state.status) {
|
||||
this.getOrderFn()
|
||||
}
|
||||
if (prevState.pay_status != this.state.pay_status) {
|
||||
this.getOrderFn()
|
||||
}
|
||||
}
|
||||
//过滤表格枚举状态
|
||||
render() {
|
||||
|
@ -669,7 +705,6 @@ export default class orderlist extends React.Component {
|
|||
/>
|
||||
)
|
||||
|
||||
const { current, pageSize } = this.state
|
||||
return (
|
||||
<div id='dislist' className='orderList'>
|
||||
<TabPage tabs={this.state.tabList} slot={date}>
|
||||
|
@ -787,7 +822,7 @@ export default class orderlist extends React.Component {
|
|||
</p>
|
||||
)
|
||||
}
|
||||
if (com == "pay_status") {
|
||||
if (com == "pay_status" && rowData.use_coupon === 1) {
|
||||
return (
|
||||
<p className='dflexa'>
|
||||
<span>
|
||||
|
|
Loading…
Reference in New Issue