Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
JSH ERP
Commits
344f35b6
Commit
344f35b6
authored
Jun 30, 2021
by
季圣华
Browse files
优化收款单
parent
4e66aeb9
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
jshERP-web/src/components/jeecg/JUpload.vue
View file @
344f35b6
This diff is collapsed.
Click to expand it.
jshERP-web/src/views/bill/PurchaseInList.vue
View file @
344f35b6
...
...
@@ -152,8 +152,14 @@
return
(
record
.
discountMoney
+
record
.
discountLastMoney
).
toFixed
(
2
);
}
},
{
title
:
'
优惠后金额
'
,
dataIndex
:
'
discountLastMoney
'
,
width
:
100
},
{
title
:
'
付款
'
,
dataIndex
:
'
changeAmount
'
,
width
:
50
},
{
title
:
'
优惠后金额
'
,
dataIndex
:
'
discountLastMoney
'
,
width
:
80
},
{
title
:
'
付款
'
,
dataIndex
:
'
changeAmount
'
,
width
:
60
},
{
title
:
'
欠款
'
,
dataIndex
:
'
debt
'
,
width
:
60
,
customRender
:
function
(
text
,
record
,
index
)
{
let
debt
=
record
.
discountLastMoney
-
record
.
changeAmount
return
debt
?
debt
.
toFixed
(
2
):
''
}
},
{
title
:
'
操作
'
,
dataIndex
:
'
action
'
,
...
...
jshERP-web/src/views/bill/SaleOutList.vue
View file @
344f35b6
...
...
@@ -152,8 +152,14 @@
return
(
record
.
discountMoney
+
record
.
discountLastMoney
).
toFixed
(
2
);
}
},
{
title
:
'
优惠后金额
'
,
dataIndex
:
'
discountLastMoney
'
,
width
:
100
},
{
title
:
'
收款
'
,
dataIndex
:
'
changeAmount
'
,
width
:
50
},
{
title
:
'
优惠后金额
'
,
dataIndex
:
'
discountLastMoney
'
,
width
:
80
},
{
title
:
'
收款
'
,
dataIndex
:
'
changeAmount
'
,
width
:
60
},
{
title
:
'
欠款
'
,
dataIndex
:
'
debt
'
,
width
:
60
,
customRender
:
function
(
text
,
record
,
index
)
{
let
debt
=
record
.
discountLastMoney
-
record
.
changeAmount
return
debt
?
debt
.
toFixed
(
2
):
''
}
},
{
title
:
'
操作
'
,
dataIndex
:
'
action
'
,
...
...
jshERP-web/src/views/financial/dialog/DebtBillList.vue
View file @
344f35b6
<
template
>
<a-modal
:title=
"title"
:width=
"1
00
0"
:width=
"1
15
0"
:visible=
"visible"
@
ok=
"handleOk"
@
cancel=
"handleCancel"
cancelText=
"关闭"
wrapClassName=
"ant-modal-cust-warp"
style=
"top:5%;height: 100%;overflow-y: hidden"
>
<!-- 查询区域 -->
<div
class=
"table-page-search-wrapper"
>
<!-- 搜索区域 -->
<a-form
layout=
"inline"
@
keyup.enter.native=
"searchQuery"
>
<a-row
:gutter=
"24"
>
<a-col
:md=
"6"
:sm=
"8"
>
<a-form-item
label=
"单据编号"
:labelCol=
"
{span: 5}" :wrapperCol="{span: 18, offset: 1}">
<a-input
placeholder=
"请输入单据编号查询"
v-model=
"queryParam.number"
></a-input>
</a-form-item>
</a-col>
<a-col
:md=
"6"
:sm=
"8"
>
<a-form-item
label=
"商品信息"
:labelCol=
"
{span: 5}" :wrapperCol="{span: 18, offset: 1}">
<a-input
placeholder=
"请输入名称、规格、型号"
v-model=
"queryParam.materialParam"
></a-input>
</a-form-item>
</a-col>
<a-col
:md=
"7"
:sm=
"10"
>
<a-form-item
label=
"单据日期"
:labelCol=
"labelCol"
:wrapperCol=
"wrapperCol"
>
<a-range-picker
style=
"width: 210px"
v-model=
"queryParam.createTimeRange"
format=
"YYYY-MM-DD"
:placeholder=
"['开始时间', '结束时间']"
@
change=
"onDateChange"
@
ok=
"onDateOk"
/>
</a-form-item>
</a-col>
<span
style=
"float: left;overflow: hidden;"
class=
"table-page-search-submitButtons"
>
<a-col
:md=
"6"
:sm=
"24"
>
<a-button
type=
"primary"
@
click=
"searchQuery"
>
查询
</a-button>
<a-button
style=
"margin-left: 8px"
@
click=
"searchReset"
>
重置
</a-button>
</a-col>
</span>
</a-row>
</a-form>
</div>
<!-- table区域-begin -->
<a-table
bordered
...
...
@@ -27,6 +63,7 @@
<
script
>
import
{
JeecgListMixin
}
from
'
@/mixins/JeecgListMixin
'
import
Vue
from
'
vue
'
export
default
{
name
:
'
DebtBillList
'
,
mixins
:[
JeecgListMixin
],
...
...
@@ -40,12 +77,22 @@
selectBillRows
:
[],
selectBillIds
:
''
,
queryParam
:
{
organId
:
""
,
materialParam
:
""
,
number
:
""
,
searchMaterial
:
""
,
type
:
""
,
subType
:
""
,
roleType
:
Vue
.
ls
.
get
(
'
roleType
'
),
status
:
""
},
labelCol
:
{
xs
:
{
span
:
24
},
sm
:
{
span
:
8
},
},
wrapperCol
:
{
xs
:
{
span
:
24
},
sm
:
{
span
:
16
},
},
// 表头
columns
:
[
{
...
...
@@ -59,20 +106,30 @@
}
},
{
title
:
''
,
dataIndex
:
'
organName
'
,
width
:
120
},
{
title
:
'
单据编号
'
,
dataIndex
:
'
number
'
,
width
:
1
5
0
},
{
title
:
'
商品信息
'
,
dataIndex
:
'
materialsList
'
,
width
:
2
2
0
,
ellipsis
:
true
,
{
title
:
'
单据编号
'
,
dataIndex
:
'
number
'
,
width
:
1
2
0
},
{
title
:
'
商品信息
'
,
dataIndex
:
'
materialsList
'
,
width
:
2
0
0
,
ellipsis
:
true
,
customRender
:
function
(
text
,
record
,
index
)
{
if
(
text
)
{
return
text
.
replace
(
"
,
"
,
"
,
"
);
}
}
},
{
title
:
'
单据日期
'
,
dataIndex
:
'
operTimeStr
'
,
width
:
1
45
},
{
title
:
'
单据日期
'
,
dataIndex
:
'
operTimeStr
'
,
width
:
1
30
},
{
title
:
'
操作员
'
,
dataIndex
:
'
userName
'
,
width
:
60
},
{
title
:
'
金额合计
'
,
dataIndex
:
'
totalPrice
'
,
width
:
70
}
{
title
:
'
应收欠款
'
,
dataIndex
:
'
needDebt
'
,
width
:
70
,
customRender
:
function
(
text
,
record
,
index
)
{
return
(
record
.
discountLastMoney
-
record
.
changeAmount
).
toFixed
(
2
);
}
},
{
title
:
'
已收欠款
'
,
dataIndex
:
'
finishDebt
'
,
width
:
70
},
{
title
:
'
待收欠款
'
,
dataIndex
:
'
debt
'
,
width
:
70
,
customRender
:
function
(
text
,
record
,
index
)
{
return
(
record
.
discountLastMoney
-
record
.
changeAmount
-
record
.
finishDebt
).
toFixed
(
2
);
}
}
],
url
:
{
list
:
"
/depotHead/
l
ist
"
list
:
"
/depotHead/
debtL
ist
"
}
}
},
...
...
@@ -84,7 +141,8 @@
created
()
{
},
methods
:
{
show
(
type
,
subType
,
organType
,
status
)
{
show
(
organId
,
type
,
subType
,
organType
,
status
)
{
this
.
queryParam
.
organId
=
organId
this
.
queryParam
.
type
=
type
this
.
queryParam
.
subType
=
subType
this
.
queryParam
.
status
=
status
...
...
@@ -109,6 +167,20 @@
this
.
$emit
(
'
ok
'
,
this
.
selectBillRows
);
this
.
close
();
},
onDateChange
:
function
(
value
,
dateString
)
{
this
.
queryParam
.
beginTime
=
dateString
[
0
];
this
.
queryParam
.
endTime
=
dateString
[
1
];
},
onDateOk
(
value
)
{
console
.
log
(
value
);
},
searchReset
()
{
this
.
queryParam
=
{
type
:
this
.
queryParam
.
type
,
subType
:
this
.
queryParam
.
subType
}
this
.
loadData
(
1
);
},
getSelectBillRows
()
{
let
dataSource
=
this
.
dataSource
;
let
billIds
=
""
;
...
...
jshERP-web/src/views/financial/dialog/FinancialDetail.vue
View file @
344f35b6
...
...
@@ -288,6 +288,11 @@
</a-col>
</a-row>
<a-row
class=
"form-row"
:gutter=
"24"
>
<a-col
:span=
"6"
>
<a-form-item
:labelCol=
"labelCol"
:wrapperCol=
"wrapperCol"
label=
"收款账户"
>
{{
model
.
accountName
}}
</a-form-item>
</a-col>
<a-col
:span=
"6"
>
<a-form-item
:labelCol=
"labelCol"
:wrapperCol=
"wrapperCol"
label=
"优惠金额"
>
{{
model
.
changeAmount
}}
...
...
@@ -295,7 +300,6 @@
</a-col>
<a-col
:span=
"6"
></a-col>
<a-col
:span=
"6"
></a-col>
<a-col
:span=
"6"
></a-col>
</a-row>
</section>
</
template
>
...
...
@@ -405,8 +409,10 @@
],
moneyInColumns
:
[
{
title
:
'
销售单据编号
'
,
dataIndex
:
'
billNumber
'
,
width
:
'
20%
'
},
{
title
:
'
金额
'
,
dataIndex
:
'
eachAmount
'
,
width
:
'
10%
'
},
{
title
:
'
备注
'
,
dataIndex
:
'
remark
'
,
width
:
'
30%
'
}
{
title
:
'
应收欠款
'
,
dataIndex
:
'
needDebt
'
,
width
:
'
10%
'
},
{
title
:
'
已收欠款
'
,
dataIndex
:
'
finishDebt
'
,
width
:
'
10%
'
},
{
title
:
'
本次收款
'
,
dataIndex
:
'
eachAmount
'
,
width
:
'
10%
'
},
{
title
:
'
备注
'
,
dataIndex
:
'
remark
'
,
width
:
'
20%
'
}
],
moneyOutColumns
:
[
{
title
:
'
账户名称
'
,
dataIndex
:
'
accountName
'
,
width
:
'
20%
'
},
...
...
jshERP-web/src/views/financial/modules/MoneyInModal.vue
View file @
344f35b6
...
...
@@ -49,7 +49,7 @@
<a-col
:lg=
"6"
:md=
"12"
:sm=
"24"
>
<!-- 操作按钮 -->
<div
class=
"action-button"
>
<a-button
type=
"primary"
icon=
"plus"
@
click=
"handleClickAdd"
>
批量
新增
</a-button>
<a-button
type=
"primary"
icon=
"plus"
@
click=
"handleClickAdd"
>
新增
</a-button>
<span
class=
"gap"
></span>
<a-button
type=
"primary"
icon=
"minus"
@
click=
"handleClear"
>
清空
</a-button>
</div>
...
...
@@ -76,6 +76,15 @@
</a-col>
</a-row>
<a-row
class=
"form-row"
:gutter=
"24"
>
<a-col
:lg=
"6"
:md=
"12"
:sm=
"24"
>
<a-form-item
:labelCol=
"labelCol"
:wrapperCol=
"wrapperCol"
label=
"收款账户"
>
<a-select
placeholder=
"选择收款账户"
v-decorator=
"[ 'accountId', validatorRules.accountId ]"
:dropdownMatchSelectWidth=
"false"
>
<a-select-option
v-for=
"(item,index) in accountList"
:key=
"index"
:value=
"item.id"
>
{{
item
.
name
}}
</a-select-option>
</a-select>
</a-form-item>
</a-col>
<a-col
:lg=
"6"
:md=
"12"
:sm=
"24"
>
<a-form-item
:labelCol=
"labelCol"
:wrapperCol=
"wrapperCol"
label=
"优惠金额"
>
<a-input
placeholder=
"请输入优惠金额"
v-decorator.trim=
"[ 'changeAmount' ]"
/>
...
...
@@ -85,7 +94,12 @@
</a-col>
<a-col
:lg=
"6"
:md=
"12"
:sm=
"24"
>
</a-col>
</a-row>
<a-row
class=
"form-row"
:gutter=
"24"
>
<a-col
:lg=
"6"
:md=
"12"
:sm=
"24"
>
<a-form-item
:labelCol=
"labelCol"
:wrapperCol=
"wrapperCol"
label=
"文件上传"
>
<j-upload
v-model=
"fileList"
bizPath=
"financial"
></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
...
...
@@ -100,6 +114,8 @@
import
{
FormTypes
}
from
'
@/utils/JEditableTableUtil
'
import
{
JEditableTableMixin
}
from
'
@/mixins/JEditableTableMixin
'
import
{
FinancialModalMixin
}
from
'
../mixins/FinancialModalMixin
'
import
JUpload
from
'
@/components/jeecg/JUpload
'
import
JEllipsis
from
'
@/components/jeecg/JEllipsis
'
import
JDate
from
'
@/components/jeecg/JDate
'
import
Vue
from
'
vue
'
export
default
{
...
...
@@ -107,6 +123,8 @@
mixins
:
[
JEditableTableMixin
,
FinancialModalMixin
],
components
:
{
DebtBillList
,
JUpload
,
JEllipsis
,
JDate
},
data
()
{
...
...
@@ -118,6 +136,7 @@
addDefaultRowNum
:
0
,
visible
:
false
,
model
:
{},
fileList
:[],
labelCol
:
{
xs
:
{
span
:
24
},
sm
:
{
span
:
8
},
...
...
@@ -133,10 +152,12 @@
dataSource
:
[],
columns
:
[
{
title
:
'
销售单据编号
'
,
key
:
'
billNumber
'
,
width
:
'
20%
'
,
type
:
FormTypes
.
input
,
readonly
:
true
},
{
title
:
'
金额
'
,
key
:
'
eachAmount
'
,
width
:
'
10%
'
,
type
:
FormTypes
.
inputNumber
,
statistics
:
true
,
placeholder
:
'
请选择${title}
'
,
{
title
:
'
应收欠款
'
,
key
:
'
needDebt
'
,
width
:
'
10%
'
,
type
:
FormTypes
.
inputNumber
,
statistics
:
true
,
readonly
:
true
},
{
title
:
'
已收欠款
'
,
key
:
'
finishDebt
'
,
width
:
'
10%
'
,
type
:
FormTypes
.
inputNumber
,
statistics
:
true
,
readonly
:
true
},
{
title
:
'
本次收款
'
,
key
:
'
eachAmount
'
,
width
:
'
10%
'
,
type
:
FormTypes
.
inputNumber
,
statistics
:
true
,
placeholder
:
'
请选择${title}
'
,
validateRules
:
[{
required
:
true
,
message
:
'
${title}不能为空
'
}]
},
{
title
:
'
备注
'
,
key
:
'
remark
'
,
width
:
'
3
0%
'
,
type
:
FormTypes
.
input
,
placeholder
:
'
请选择${title}
'
}
{
title
:
'
备注
'
,
key
:
'
remark
'
,
width
:
'
2
0%
'
,
type
:
FormTypes
.
input
,
placeholder
:
'
请选择${title}
'
}
]
},
confirmLoading
:
false
,
...
...
@@ -150,6 +171,11 @@
rules
:
[
{
required
:
true
,
message
:
'
请选择经手人!
'
}
]
},
accountId
:{
rules
:
[
{
required
:
true
,
message
:
'
请选择收款账户!
'
}
]
}
},
url
:
{
...
...
@@ -160,7 +186,7 @@
}
},
created
()
{
this
.
init
Detail
Account
()
this
.
initAccount
()
},
methods
:
{
//调用完edit()方法之后会自动调用此方法
...
...
@@ -170,8 +196,10 @@
}
else
{
this
.
model
.
billTime
=
this
.
model
.
billTimeStr
this
.
$nextTick
(()
=>
{
this
.
form
.
setFieldsValue
(
pick
(
this
.
model
,
'
organId
'
,
'
handsPersonId
'
,
'
billTime
'
,
'
billNo
'
,
'
remark
'
,
'
changeAmount
'
))
this
.
form
.
setFieldsValue
(
pick
(
this
.
model
,
'
organId
'
,
'
handsPersonId
'
,
'
billTime
'
,
'
billNo
'
,
'
remark
'
,
'
accountId
'
,
'
changeAmount
'
))
});
this
.
fileList
=
this
.
model
.
fileName
// 加载子表数据
let
params
=
{
headerId
:
this
.
model
.
id
...
...
@@ -190,6 +218,9 @@
totalPrice
+=
item
.
eachAmount
-
0
}
billMain
.
totalPrice
=
totalPrice
if
(
this
.
fileList
&&
this
.
fileList
.
length
>
0
)
{
billMain
.
fileName
=
this
.
fileList
}
if
(
this
.
model
.
id
){
billMain
.
id
=
this
.
model
.
id
}
...
...
@@ -199,8 +230,13 @@
}
},
handleClickAdd
()
{
this
.
$refs
.
debtBillList
.
show
(
'
出库
'
,
'
销售
'
,
'
客户
'
,
"
0
"
)
this
.
$refs
.
debtBillList
.
title
=
"
选择销售出库
"
let
organId
=
this
.
form
.
getFieldValue
(
'
organId
'
)
if
(
organId
){
this
.
$refs
.
debtBillList
.
show
(
organId
,
'
出库
'
,
'
销售
'
,
'
客户
'
,
"
0
"
)
this
.
$refs
.
debtBillList
.
title
=
"
选择销售出库欠款单据
"
}
else
{
this
.
$message
.
warning
(
'
请选择客户!
'
);
}
},
handleClear
()
{
this
.
accountTable
.
dataSource
=
[]
...
...
@@ -217,8 +253,11 @@
for
(
let
i
=
0
;
i
<
selectBillRows
.
length
;
i
++
){
let
info
=
selectBillRows
[
i
]
info
.
billNumber
=
info
.
number
info
.
eachAmount
=
info
.
totalPrice
listEx
.
push
(
info
)
info
.
needDebt
=
(
info
.
discountLastMoney
-
info
.
changeAmount
).
toFixed
(
2
)
info
.
eachAmount
=
(
info
.
discountLastMoney
-
info
.
changeAmount
-
info
.
finishDebt
).
toFixed
(
2
);
if
(
info
.
eachAmount
!=
0
)
{
listEx
.
push
(
info
)
}
}
tab
.
dataSource
=
listEx
typeof
success
===
'
function
'
?
success
(
res
)
:
''
...
...
Write
Preview
Supports
Markdown
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