Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-platform
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
陈智峰
jinfa-platform
Commits
578e3fe8
Commit
578e3fe8
authored
Apr 27, 2021
by
前端-黄佳鑫
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
🐞
fix: 修复待确认物流单bug
parent
8df1e773
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
55 additions
and
37 deletions
+55
-37
orderSearchDetail.tsx
src/pages/logistics/components/orderSearchDetail.tsx
+54
-36
addCompany.tsx
src/pages/logistics/list/addCompany.tsx
+1
-1
No files found.
src/pages/logistics/components/orderSearchDetail.tsx
View file @
578e3fe8
import
React
,
{
useEffect
,
useState
,
ReactNode
,
useRef
}
from
'react'
;
import
React
,
{
useEffect
,
useState
,
ReactNode
,
useRef
}
from
'react'
;
import
{
Row
,
Col
,
Table
,
Input
,
Button
,
Tag
,
Badge
,
Steps
,
message
}
from
'antd'
import
{
Row
,
Col
,
Table
,
Input
,
Button
,
Tag
,
Badge
,
Steps
,
message
,
Form
,
Typography
}
from
'antd'
import
{
PageHeaderWrapper
}
from
'@ant-design/pro-layout'
import
{
PageHeaderWrapper
}
from
'@ant-design/pro-layout'
import
{
CheckSquareOutlined
}
from
'@ant-design/icons'
import
{
CheckSquareOutlined
}
from
'@ant-design/icons'
import
{
ColumnType
}
from
'antd/lib/table/interface'
import
{
ColumnType
}
from
'antd/lib/table/interface'
...
@@ -8,11 +8,19 @@ import { history } from 'umi'
...
@@ -8,11 +8,19 @@ import { history } from 'umi'
import
{
PublicApi
}
from
'@/services/api'
import
{
PublicApi
}
from
'@/services/api'
import
moment
from
'moment'
import
moment
from
'moment'
import
style
from
'./index.less'
import
style
from
'./index.less'
import
statuStyle
from
'../colorTag'
import
statuStyle
from
'../colorTag'
;
const
{
Step
}
=
Steps
const
{
Step
}
=
Steps
const
layout
:
any
=
{
colon
:
false
,
labelCol
:
{
style
:
{
width
:
'150px'
}
},
wrapperCol
:
{
style
:
{
width
:
'500px'
}
},
labelAlign
:
"left"
}
const
detailInfo
:
React
.
FC
<
{}
>
=
()
=>
{
const
detailInfo
:
React
.
FC
<
{}
>
=
()
=>
{
const
ref
=
useRef
<
any
>
({})
const
ref
=
useRef
<
any
>
({})
const
[
form
]
=
Form
.
useForm
();
const
[
freightPrice
,
setfreightPrice
]
=
useState
<
any
>
(
null
);
const
[
freightPrice
,
setfreightPrice
]
=
useState
<
any
>
(
null
);
let
[
isextraOption
,
setIsextraOption
]
=
useState
(
false
)
let
[
isextraOption
,
setIsextraOption
]
=
useState
(
false
)
let
[
dataInfo
,
setdataInfo
]
=
useState
<
any
>
({
let
[
dataInfo
,
setdataInfo
]
=
useState
<
any
>
({
...
@@ -75,7 +83,7 @@ const detailInfo: React.FC<{}> = () => {
...
@@ -75,7 +83,7 @@ const detailInfo: React.FC<{}> = () => {
title
:
'运费'
,
title
:
'运费'
,
leftElem
:
[
leftElem
:
[
{
title
:
'运费:'
,
key
:
'freight'
,
value
:
dataInfo
.
freightPrice
||
''
},
{
title
:
'运费:'
,
key
:
'freight'
,
value
:
dataInfo
.
freightPrice
||
''
},
{
title
:
'结算方式:'
,
key
:
''
,
value
:
dataInfo
.
settlementWay
||
''
}
{
title
:
'结算方式:'
,
key
:
'
settlement
'
,
value
:
dataInfo
.
settlementWay
||
''
}
]
]
}
}
}
}
...
@@ -246,11 +254,13 @@ const detailInfo: React.FC<{}> = () => {
...
@@ -246,11 +254,13 @@ const detailInfo: React.FC<{}> = () => {
setfreightPrice
(
value
);
setfreightPrice
(
value
);
}
}
const
handleAudit
=
()
=>
{
const
handleAudit
=
async
()
=>
{
if
(
freightPrice
)
{
try
{
setvisible
(
true
)
const
value
=
await
form
.
validateFields
();
}
else
{
setfreightPrice
(
value
.
freight
);
message
.
error
(
'请输入运费'
)
setvisible
(
true
);
}
catch
{
message
.
error
(
'请下拉到运费模块输入运费!'
)
}
}
}
}
...
@@ -420,35 +430,43 @@ const detailInfo: React.FC<{}> = () => {
...
@@ -420,35 +430,43 @@ const detailInfo: React.FC<{}> = () => {
{
infoTem
[
'freight'
].
leftElem
.
map
(
{
infoTem
[
'freight'
].
leftElem
.
map
(
(
item
:
any
,
index
:
number
)
=>
{
(
item
:
any
,
index
:
number
)
=>
{
return
(
return
(
<
div
className=
{
style
[
'cols-main'
]
}
key=
{
`freight${index + 1}`
}
>
<
Form
{
...
layout
}
form=
{
form
}
>
<
div
className=
{
style
[
'cols-main-options'
]
}
>
{
item
.
key
===
'freight'
&&
{
item
.
title
}
<>
</
div
>
{
type
===
'option'
?
(
{
<
Form
.
Item
item
.
key
===
'freight'
?
label=
{
item
.
title
}
<>
name=
{
item
.
key
}
{
type
===
'option'
?
rules=
{
[
<
div
className=
{
style
[
'cols-main-options'
]
}
>
{
<
Input
required
:
true
,
value=
{
freightPrice
}
message
:
'请正确输入运费'
,
addonBefore=
"¥"
},
onChange=
{
inputOnchange
}
{
type=
'number'
pattern
:
/^
\d
+
(\.\d
{1,2}
)?
$/
,
maxLength=
{
25
}
message
:
'运费数值小数点后仅限两位'
,
style=
{
{
width
:
'300px'
}
}
}
/>
]
}
</
div
>
>
:
<
Input
<
div
className=
{
style
[
'cols-main-options'
]
}
>
type=
'number'
{
dataInfo
.
status
<
3
?
'未报价'
:
item
.
value
}
addonBefore=
"¥"
</
div
>
maxLength=
{
25
}
}
style=
{
{
width
:
'300px'
}
}
</>
/>
:
<
div
className=
{
style
[
'cols-main-options'
]
}
>
</
Form
.
Item
>
{
item
.
value
}
)
:
(
</
div
>
<
Form
.
Item
label=
{
item
.
title
}
name=
{
item
.
key
}
rules=
{
[{
required
:
true
,
message
:
'请输入运费'
}]
}
>
{
dataInfo
.
status
<
3
?
<
Typography
.
Text
>
未报价
</
Typography
.
Text
>
:
<
Typography
.
Text
>
{
item
.
value
&&
`¥${(item.value).toFixed(2)}`
}
</
Typography
.
Text
>
}
</
Form
.
Item
>
)
}
</>
}
}
</
div
>
{
item
.
key
===
'settlement'
&&
<
Form
.
Item
label=
{
item
.
title
}
name=
{
item
.
key
}
>
<
span
>
{
item
.
value
}
</
span
>
</
Form
.
Item
>
}
</
Form
>
);
);
},
},
)
}
)
}
...
...
src/pages/logistics/list/addCompany.tsx
View file @
578e3fe8
...
@@ -196,7 +196,7 @@ const company: React.FC<parmas> = (props) => {
...
@@ -196,7 +196,7 @@ const company: React.FC<parmas> = (props) => {
backIcon=
{
<
ReutrnEle
description=
"返回"
/>
}
backIcon=
{
<
ReutrnEle
description=
"返回"
/>
}
title=
{
headerTitle
}
title=
{
headerTitle
}
>
>
<
Row
gutter=
{
[
36
,
36
]
}
>
<
Row
>
<
Col
span=
{
24
}
>
<
Col
span=
{
24
}
>
<
Card
>
<
Card
>
{
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment