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
linweijiong
jinfa-platform
Commits
0d9d9434
Commit
0d9d9434
authored
Apr 29, 2021
by
前端-黄佳鑫
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
🐞
fix: 修复采购询价bug
parent
5a5d1f3a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
39 additions
and
36 deletions
+39
-36
orderSearchDetail.tsx
src/pages/logistics/components/orderSearchDetail.tsx
+36
-36
index.tsx
...saction/purchaseAbility/components/modalOperate/index.tsx
+3
-0
No files found.
src/pages/logistics/components/orderSearchDetail.tsx
View file @
0d9d9434
import
React
,
{
useEffect
,
useState
,
ReactNode
,
useRef
}
from
'react'
;
import
{
Row
,
Col
,
Table
,
Input
,
Button
,
Tag
,
Badge
,
Steps
,
message
,
Form
,
Typography
}
from
'antd'
import
React
,
{
useEffect
,
useState
,
ReactNode
,
useRef
,
Fragment
}
from
'react'
;
import
{
Row
,
Col
,
Table
,
Input
,
Button
,
Tag
,
Badge
,
Steps
,
message
,
Form
,
Checkbox
}
from
'antd'
import
{
PageHeaderWrapper
}
from
'@ant-design/pro-layout'
import
{
CheckSquareOutlined
}
from
'@ant-design/icons'
import
{
ColumnType
}
from
'antd/lib/table/interface'
...
...
@@ -8,7 +8,7 @@ import { history } from 'umi'
import
{
PublicApi
}
from
'@/services/api'
import
moment
from
'moment'
import
style
from
'./index.less'
import
statuStyle
from
'../colorTag'
;
import
statuStyle
from
'../colorTag'
const
{
Step
}
=
Steps
const
layout
:
any
=
{
...
...
@@ -22,7 +22,7 @@ const detailInfo: React.FC<{}> = () => {
const
ref
=
useRef
<
any
>
({})
const
[
form
]
=
Form
.
useForm
();
const
[
freightPrice
,
setfreightPrice
]
=
useState
<
any
>
(
null
);
const
[
taxRate
,
setTaxRate
]
=
useState
<
any
>
(
null
);
const
[
taxRate
,
setTaxRate
]
=
useState
<
any
>
(
null
);
let
[
isextraOption
,
setIsextraOption
]
=
useState
(
false
)
let
[
dataInfo
,
setdataInfo
]
=
useState
<
any
>
({
status
:
''
,
...
...
@@ -251,7 +251,6 @@ const detailInfo: React.FC<{}> = () => {
// 输入报价价格
const
inputOnchange
=
(
e
:
any
)
=>
{
console
.
log
(
e
.
target
.
value
)
const
value
=
e
.
target
.
value
;
setfreightPrice
(
value
);
}
...
...
@@ -260,9 +259,10 @@ const detailInfo: React.FC<{}> = () => {
try
{
const
value
=
await
form
.
validateFields
();
setfreightPrice
(
value
.
freight
);
setTaxRate
(
value
.
taxRate
);
setvisible
(
true
);
}
catch
{
message
.
error
(
'请下拉到运费模块输入运费!'
)
message
.
error
(
'请下拉到运费模块输入
税率和
运费!'
)
}
}
...
...
@@ -433,37 +433,37 @@ const detailInfo: React.FC<{}> = () => {
(
item
:
any
,
index
:
number
)
=>
{
return
(
<
Form
{
...
layout
}
form=
{
form
}
>
{
item
.
key
===
'taxRate'
&&
<
Form
.
Item
label=
{
item
.
title
}
style=
{
{
marginBottom
:
0
,
position
:
'relative'
}
}
>
<
div
style=
{
{
position
:
'absolute'
,
top
:
'7px'
,
}
}
>
<
Checkbox
checked
>
是
</
Checkbox
>
</
div
>
<
Form
.
Item
label=
'税率'
name=
'taxRate'
rules=
{
[{
required
:
true
,
message
:
'请输入税率'
}]
}
style=
{
{
paddingLeft
:
'60px'
}
}
>
<
Input
type=
'number'
addonAfter=
'%'
maxLength=
{
25
}
style=
{
{
width
:
'200px'
}
}
/>
</
Form
.
Item
>
</
Form
.
Item
>
}
{
item
.
key
===
'freight'
&&
<>
{
type
===
'option'
?
(
<
Form
.
Item
label=
{
item
.
title
}
name=
{
item
.
key
}
rules=
{
[
{
required
:
true
,
message
:
'请正确输入运费'
,
},
{
pattern
:
/^
\d
+
(\.\d
{1,2}
)?
$/
,
message
:
'运费数值小数点后仅限两位'
,
}
]
}
>
<
Input
type=
'number'
addonBefore=
"¥"
maxLength=
{
25
}
style=
{
{
width
:
'300px'
}
}
/>
</
Form
.
Item
>
)
:
(
<
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
>
)
}
</>
}
<
Form
.
Item
label=
{
item
.
title
}
name=
{
item
.
key
}
rules=
{
[{
required
:
true
,
message
:
'请输入运费'
}]
}
>
<
Input
type=
'number'
addonBefore=
"¥"
maxLength=
{
25
}
style=
{
{
width
:
'300px'
}
}
/>
</
Form
.
Item
>
}
{
item
.
key
===
'settlement'
&&
<
Form
.
Item
label=
{
item
.
title
}
name=
{
item
.
key
}
>
<
span
>
{
item
.
value
}
</
span
>
...
...
src/pages/transaction/purchaseAbility/components/modalOperate/index.tsx
View file @
0d9d9434
...
...
@@ -142,6 +142,9 @@ const ModalOperate: React.FC<IProps> = (props: any) => {
if
(
modalType
===
'next'
)
{
actions
.
setFieldValue
(
'quotedPriceTime'
,
moment
().
format
())
}
if
(
modalType
===
'abandon'
)
{
actions
.
setFieldValue
(
'reasonTime'
,
moment
().
format
())
}
},
[
visible
])
const
handleSubmit
=
(
val
:
any
)
=>
{
...
...
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