Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yd-csf-front
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
yuzhenWang
yd-csf-front
Commits
679e9f3f
Commit
679e9f3f
authored
Apr 07, 2026
by
yuzhenWang
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'test' into 'feature-20260407wyz-增加拆分出帐'
Test See merge request
!103
parents
189821fc
c3092767
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
228 additions
and
6 deletions
+228
-6
src/api/financial/commission.js
+19
-0
src/components/SearchForm/SearchForm.vue
+20
-6
src/views/financialCenter/payroll.vue
+189
-0
No files found.
src/api/financial/commission.js
View file @
679e9f3f
...
...
@@ -429,4 +429,22 @@ export function receivableReport(data) {
method
:
'post'
,
data
:
data
})
}
// 薪资拆分应发信息汇总列表
export
function
salarySummary
(
data
)
{
return
request
({
url
:
'csf/api/salarySplit/summary/page'
,
method
:
'post'
,
data
:
data
})
}
// 薪资拆分应发信息汇总列表下载---待提供
export
function
exportPayRoll
(
data
)
{
return
request
({
url
:
'csf/api/salarySplit/export/summary/list'
,
method
:
'post'
,
data
:
data
,
})
}
\ No newline at end of file
src/components/SearchForm/SearchForm.vue
View file @
679e9f3f
...
...
@@ -82,14 +82,28 @@
v-model=
"localModel[item.prop]"
type=
"daterange"
range-separator=
"至"
start-placeholder=
"开始日期
"
end-placeholder=
"结束日期
"
:start-placeholder=
"item.startPlaceholder || '开始日期'
"
:end-placeholder=
"item.endPlaceholder || '结束日期'
"
:value-format=
"item.valueFormat || 'YYYY-MM-DD'"
:disabled=
"item.disabled"
:disabled-date=
"getDisabledDateFn(item)"
style=
"width: 100%"
@
change=
"val => handleModelChange(val, item)"
/>
<!-- Monthrange (新增) -->
<el-date-picker
v-else-if=
"item.type === 'monthrange'"
v-model=
"localModel[item.prop]"
type=
"monthrange"
range-separator=
"至"
:start-placeholder=
"item.startPlaceholder || '开始月份'"
:end-placeholder=
"item.endPlaceholder || '结束月份'"
:value-format=
"item.valueFormat || 'YYYY-MM'"
:disabled=
"item.disabled"
:disabled-date=
"getDisabledDateFn(item)"
style=
"width: 100%"
@
change=
"val => handleModelChange(val, item)"
/>
<!-- Checkbox Group -->
<el-checkbox-group
...
...
@@ -359,7 +373,7 @@ watch(
// 优先用父传值,否则用默认值
if
(
props
.
modelValue
?.[
key
]
!==
undefined
)
{
initialModel
[
key
]
=
props
.
modelValue
[
key
]
}
else
if
(
item
.
multiple
||
[
'checkbox-group'
,
'daterange'
].
includes
(
item
.
type
))
{
}
else
if
(
item
.
multiple
||
[
'checkbox-group'
,
'daterange'
,
'monthrange'
].
includes
(
item
.
type
))
{
initialModel
[
key
]
=
item
.
defaultValue
??
[]
}
else
{
initialModel
[
key
]
=
item
.
defaultValue
??
''
...
...
@@ -396,7 +410,7 @@ function syncModelFromProps(newModelValue, newConfig) {
const
key
=
item
.
prop
if
(
newModelValue
.
hasOwnProperty
(
key
))
{
synced
[
key
]
=
newModelValue
[
key
]
}
else
if
(
item
.
multiple
||
[
'checkbox-group'
,
'daterange'
].
includes
(
item
.
type
))
{
}
else
if
(
item
.
multiple
||
[
'checkbox-group'
,
'daterange'
,
'monthrange'
].
includes
(
item
.
type
))
{
synced
[
key
]
=
item
.
defaultValue
??
[]
}
else
{
synced
[
key
]
=
item
.
defaultValue
??
''
...
...
@@ -571,7 +585,7 @@ onMounted(async () => {
if
(
localModel
.
value
[
key
]
==
null
)
{
if
(
item
.
multiple
)
{
initialData
[
key
]
=
item
.
defaultValue
??
[]
}
else
if
([
'checkbox-group'
,
'daterange'
].
includes
(
item
.
type
))
{
}
else
if
([
'checkbox-group'
,
'daterange'
,
'monthrange'
].
includes
(
item
.
type
))
{
initialData
[
key
]
=
item
.
defaultValue
??
[]
}
else
{
initialData
[
key
]
=
item
.
defaultValue
??
''
...
...
@@ -885,7 +899,7 @@ defineExpose({
const
resetData
=
{}
internalConfig
.
value
.
forEach
(
item
=>
{
const
key
=
item
.
prop
if
([
'checkbox-group'
,
'daterange'
].
includes
(
item
.
type
)
||
item
.
multiple
)
{
if
([
'checkbox-group'
,
'daterange'
,
'monthrange'
].
includes
(
item
.
type
)
||
item
.
multiple
)
{
resetData
[
key
]
=
item
.
defaultValue
??
[]
}
else
if
(
item
.
type
===
'upload'
)
{
resetData
[
key
]
=
item
.
defaultValue
??
[]
// upload 也是数组
...
...
src/views/financialCenter/payroll.vue
0 → 100644
View file @
679e9f3f
<
template
>
<div
class=
'app-container'
>
<CommonPage
:operationBtnList=
'operationBtnList'
:visibleDefaultButtons=
'visibleDefaultButtons'
:showSearchForm=
'true'
:show-pagination=
'true'
:total=
'pageTotal'
:current-page=
'currentPage'
:page-size=
'pageSize'
@
size-change=
'handleSizeChange'
@
current-change=
'handleCurrentChange'
>
<!-- 搜索区域 -->
<template
#
searchForm
>
<SearchForm
ref=
"searchFormRef"
:config=
"searchConfig"
/>
</
template
>
<!-- 列表区域 -->
<
template
#
table
>
<el-table
:data=
"tableData"
v-loading=
"loading"
ref=
"tableRef"
row-key=
"salarySplitNo"
:reserve-selection=
"true"
:border=
"true"
>
<el-table-column
v-for=
"(column, index) in tableColumns"
:key=
"index"
:fixed=
"column.fixed"
:prop=
"column.prop"
:label=
"column.label"
:width=
"column.width"
:sortable=
"column.sortable"
:formatter=
"column.formatter"
/>
</el-table>
</
template
>
</CommonPage>
</div>
</template>
<
script
setup
>
import
{
ref
,
reactive
}
from
'vue'
import
CommonPage
from
'@/components/commonPage'
import
{
salarySummary
,
exportPayRoll
}
from
'@/api/financial/commission'
import
{
ElMessageBox
,
ElMessage
}
from
'element-plus'
import
SearchForm
from
'@/components/SearchForm/SearchForm.vue'
const
searchFormRef
=
ref
(
null
)
const
searchParams
=
ref
({})
const
searchConfig
=
ref
([
{
type
:
'select'
,
prop
:
'brokerBizIdList'
,
label
:
'转介人'
,
api
:
'/insurance/base/api/userSaleExpand/page'
,
keywordField
:
'realName'
,
requestParams
:
{
pageNo
:
1
,
pageSize
:
20
},
placeholder
:
'输入转介人名称搜索'
,
debounceWait
:
500
,
// 自定义防抖时间
valueKey
:
'clientUserBizId'
,
labelKey
:
'realName'
,
multiple
:
true
,
transform
:
(
res
)
=>
{
return
res
?.
data
.
records
||
[]
}
},
{
type
:
'monthrange'
,
prop
:
'payoutMonth'
,
label
:
'出账年月(实)'
,
startPlaceholder
:
'开始年月'
,
endPlaceholder
:
'结束年月'
},
{
type
:
'input'
,
prop
:
'billOrg'
,
label
:
'出账机构'
,
}
])
const
tableColumns
=
ref
([
{
prop
:
'salarySplitNo'
,
label
:
'发放编号'
,
sortable
:
true
,
width
:
'150'
,
fixed
:
'left'
},
{
prop
:
'brokerName'
,
label
:
'转介人'
,
sortable
:
true
,
width
:
'150'
,
fixed
:
'left'
},
{
prop
:
'internalNumber'
,
label
:
'内部编号'
,
sortable
:
true
,
width
:
'150'
},
{
prop
:
'team'
,
label
:
'所属团队'
,
sortable
:
true
,
width
:
'150'
},
{
prop
:
'fromAmount'
,
label
:
'原币种金额'
,
sortable
:
true
,
width
:
'150'
},
{
prop
:
'currency'
,
label
:
'原币种'
,
sortable
:
true
,
width
:
'150'
},
{
prop
:
'exchangeRate'
,
label
:
'汇率(原币种->目标币种)'
,
sortable
:
true
,
width
:
'150'
},
{
prop
:
'toAmount'
,
label
:
'目标金额'
,
sortable
:
true
,
width
:
'150'
},
{
prop
:
'toCurrency'
,
label
:
'目标币种'
,
sortable
:
true
,
width
:
'150'
},
{
prop
:
'fortuneAccountMonth'
,
label
:
'出账月(实)'
,
sortable
:
true
,
width
:
'150'
},
{
prop
:
'billOrg'
,
label
:
'出账机构'
,
sortable
:
true
,
width
:
'150'
},
{
prop
:
'"hkdAmount'
,
label
:
'本期总出账金额(原币种)'
,
sortable
:
true
,
width
:
'150'
},
{
prop
:
'fortuneAccountBizId'
,
label
:
'出账记录业务id'
,
sortable
:
true
,
width
:
'150'
},
])
// 添加表格引用
const
tableRef
=
ref
()
// 表格数据
const
tableData
=
ref
([])
const
loading
=
ref
(
false
)
// 分页相关
const
currentPage
=
ref
(
1
)
const
pageSize
=
ref
(
10
)
const
pageTotal
=
ref
(
0
)
// 分页事件
const
handleSizeChange
=
(
val
)
=>
{
pageSize
.
value
=
val
getList
()
}
const
handleCurrentChange
=
(
val
)
=>
{
currentPage
.
value
=
val
getList
()
}
// 获取数据列表
const
getList
=
async
(
searchParams
=
{})
=>
{
loading
.
value
=
true
try
{
const
params
=
{
...
searchParams
,
startMonth
:
searchParams
.
payoutMonth
?
searchParams
.
payoutMonth
[
0
]
:
''
,
endMonth
:
searchParams
.
payoutMonth
?
searchParams
.
payoutMonth
[
1
]
:
''
,
payoutMonth
:
undefined
,
pageNo
:
currentPage
.
value
,
pageSize
:
pageSize
.
value
}
const
response
=
await
salarySummary
(
params
)
if
(
response
.
data
.
page
)
{
tableData
.
value
=
response
.
data
.
page
.
records
pageTotal
.
value
=
response
.
data
.
page
.
total
loading
.
value
=
false
}
}
catch
(
error
)
{
loading
.
value
=
false
// ElMessage.error('获取数据失败')
}
}
getList
()
// 查询
const
handleQuery
=
()
=>
{
const
params
=
searchFormRef
.
value
.
getFormData
()
console
.
log
(
'父组件发起查询:'
,
params
)
getList
(
params
)
}
// 重置查询
const
handleReset
=
()
=>
{
// 重置搜索表单
searchFormRef
.
value
.
resetForm
()
searchParams
.
value
=
{}
console
.
log
(
'表单已重置'
)
getList
(
searchParams
.
value
)
}
const
handleExport
=
async
()
=>
{
// 获取搜索参数
let
params
=
searchFormRef
.
value
?.
getFormData
()
params
=
{
...
params
,
startMonth
:
params
.
payoutMonth
?
params
.
payoutMonth
[
0
]
:
''
,
endMonth
:
params
.
payoutMonth
?
params
.
payoutMonth
[
1
]
:
''
,
payoutMonth
:
undefined
,
}
const
response
=
await
exportPayRoll
(
params
)
if
(
response
.
data
&&
response
.
data
.
url
){
window
.
open
(
response
.
data
.
url
)
}
else
{
ElMessage
.
error
(
'导出失败'
)
}
}
const
visibleDefaultButtons
=
ref
([
'export'
,
'reset'
,
'query'
])
// 按钮配置
const
operationBtnList
=
ref
([
{
key
:
'reset'
,
direction
:
'right'
,
click
:
handleReset
},
{
key
:
'query'
,
direction
:
'right'
,
click
:
handleQuery
},
{
key
:
'export'
,
direction
:
'right'
,
click
:
handleExport
}
])
</
script
>
<
style
scoped
></
style
>
\ No newline at end of file
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