♻️ refactor: 更改订单状态
This commit is contained in:
parent
e3105bd922
commit
5a3d09c58f
|
@ -43,7 +43,11 @@ const menu = {
|
||||||
},
|
},
|
||||||
|
|
||||||
orderStatusBg(params) {
|
orderStatusBg(params) {
|
||||||
switch (params) {
|
/* 立减金 */
|
||||||
|
if (params.status === 1 && params.type === 2) {
|
||||||
|
return "#43A65D"
|
||||||
|
}
|
||||||
|
switch (params.status) {
|
||||||
case 0:
|
case 0:
|
||||||
return "#3575C7"
|
return "#3575C7"
|
||||||
case 1:
|
case 1:
|
||||||
|
|
|
@ -667,11 +667,11 @@ export default class orderList extends React.Component {
|
||||||
<font
|
<font
|
||||||
className="icon"
|
className="icon"
|
||||||
style={{
|
style={{
|
||||||
background: menu.orderStatusBg(parseInt(rowData.status))
|
background: menu.orderStatusBg(rowData)
|
||||||
}}
|
}}
|
||||||
></font>
|
></font>
|
||||||
{rowData.status_text}
|
{rowData.status_text}
|
||||||
{rowData.type === 2 && rowData.status === 2
|
{rowData.type === 2 && [1, 2].includes(rowData.status)
|
||||||
? `(${rowData.received_num}/${rowData.num})`
|
? `(${rowData.received_num}/${rowData.num})`
|
||||||
: ""}
|
: ""}
|
||||||
</span>
|
</span>
|
||||||
|
@ -798,7 +798,7 @@ export default class orderList extends React.Component {
|
||||||
</>
|
</>
|
||||||
) : null}
|
) : null}
|
||||||
{rowData.type === 2 &&
|
{rowData.type === 2 &&
|
||||||
rowData.status === 2 &&
|
[1, 2].includes(rowData.status) &&
|
||||||
rowData.received_num !== rowData.num ? (
|
rowData.received_num !== rowData.num ? (
|
||||||
<span
|
<span
|
||||||
className="grid-link"
|
className="grid-link"
|
||||||
|
|
Loading…
Reference in New Issue