Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
confucius
Project
Project
Details
Activity
Releases
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
罗超
confucius
Commits
ecf7c4f1
Commit
ecf7c4f1
authored
Jun 21, 2021
by
黄奎
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://gitlab.oytour.com/luochao/confucius
parents
866736a2
f5e18382
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
177 additions
and
41 deletions
+177
-41
index.js
src/api/finance/index.js
+9
-0
CommissionDetail.vue
src/pages/financial/CommissionDetail.vue
+13
-1
addFinancialDocuments.vue
...ages/financial/financalDocument/addFinancialDocuments.vue
+8
-2
salesCommission.vue
src/pages/financial/salesCommission.vue
+147
-38
No files found.
src/api/finance/index.js
View file @
ecf7c4f1
...
...
@@ -120,4 +120,13 @@ export function getSellCommissionForOrderList(data) {
});
}
// 财务工作台 获取周期提成 创建提成
export
function
setSellCommissionInfo
(
data
)
{
return
request
({
url
:
'/SellCommission/SetSellCommissionInfo'
,
method
:
'post'
,
data
});
}
src/pages/financial/CommissionDetail.vue
View file @
ecf7c4f1
...
...
@@ -118,9 +118,21 @@
department
:[],
ClassList
:[],
allClassList
:[],
see_tcdetailed
:
false
}
},
created
()
{
let
userinfo
=
this
.
getLocalStorage
();
userinfo
.
ActionMenuList
.
map
(
x
=>
{
//判断权限
if
(
x
.
FunctionCode
==
"see_tcdetailed"
){
//判断是否可以查看其他明细
this
.
see_tcdetailed
=
true
;
}
})
if
(
this
.
see_tcdetailed
==
false
){
console
.
log
(
userinfo
)
this
.
msg
.
UserId
=
userinfo
.
Id
}
},
created
()
{},
mounted
()
{
console
.
log
(
this
.
$route
.
query
)
if
(
this
.
$route
.
query
&&
this
.
$route
.
query
.
id
){
...
...
src/pages/financial/financalDocument/addFinancialDocuments.vue
View file @
ecf7c4f1
...
...
@@ -1629,7 +1629,7 @@
if
(
!
this
.
msg
.
InvoiceRemark
){
this
.
msg
.
InvoiceRemark
=
''
}
if
(
id
||
id
===
0
)
{
if
(
!
this
.
orderObj
&&
id
>
0
)
{
this
.
msg
.
RB_Branch_Id
=
this
.
msg
.
RB_Branch_Id
...
...
@@ -1645,10 +1645,13 @@
if
(
!
this
.
$route
.
query
.
companyID
&&
userInfo
.
Group_Id
==
100000
){
this
.
msg
.
RB_Branch_Id
=
4
}
if
(
this
.
orderObj
){
//6.21号新加 校区的id
this
.
msg
.
RB_Branch_Id
=
this
.
orderObj
.
School_Id
}
if
(
this
.
orderObj
&&
this
.
orderObj
.
companyIDList
&&
this
.
orderObj
.
companyIDList
.
length
>
0
)
{
this
.
msg
.
RB_Branch_Id
=
this
.
orderObj
.
companyIDList
[
0
];
}
else
if
(
this
.
$route
.
query
.
companyID
)
{
if
(
this
.
$route
.
query
.
companyID
!==
'undefined'
){
this
.
msg
.
RB_Branch_Id
=
parseInt
(
this
.
$route
.
query
.
companyID
);
}
else
{
...
...
@@ -1657,6 +1660,7 @@
}
}
this
.
admin_get_DepartmentGetList
(
this
.
msg
.
RB_Branch_Id
);
this
.
get_GetInvoiceTypeEnumList
()
this
.
msg
.
PayDate
=
this
.
msg
.
PayDate
;
...
...
@@ -1832,12 +1836,14 @@
}
})
let
Status
=
false
;
if
(
this
.
$route
.
query
.
companyID
!==
'-1'
&&
this
.
$route
.
query
.
companyID
!==
undefined
){
Status
=
true
;
data
.
forEach
(
x
=>
{
x
.
disabled
=
true
;
})
}
if
(
this
.
orderObj
&&
this
.
orderObj
.
companyIDList
&&
this
.
orderObj
.
companyIDList
.
length
>
0
)
{
Status
=
true
;
this
.
orderObj
.
companyIDList
.
forEach
(
x
=>
{
...
...
src/pages/financial/salesCommission.vue
View file @
ecf7c4f1
...
...
@@ -41,9 +41,27 @@
<div
class=
"page-body salesCommission"
>
<div
class=
"page-search row items-center"
>
<div
class=
"col row wrap q-mr-lg q-col-gutter-md"
>
<div
class=
"col-3"
>
<q-input
filled
v-model=
"msg.Name"
@
keyup
.
enter
.
native=
"msg.PageIndex = 1,getList()"
label=
"周期名称"
/>
<div
style=
"margin-right: 20px;"
v-if=
'iscMaker==true'
>
<div
class=
"block"
>
<span
style=
"margin-right: 5px;"
>
校区
</span>
<el-select
v-model=
"msg.SchoolId"
filterable
@
change=
"handleCurrentChanges(1)"
>
<el-option
value=
"-1"
label=
"不限"
></el-option>
<el-option
v-for=
'item in CompanyList'
:label=
'item.SName'
:value=
'item.SId'
:key=
'item.SId'
></el-option>
</el-select>
</div>
</div>
<div
class=
"col-3"
v-if=
'isgenerate==true'
>
<div
class=
"block"
style=
"display:flex"
>
<span
style=
"margin-right: 5px;"
>
选择月份
</span>
<el-date-picker
v-model=
"value2"
type=
"month"
placeholder=
"选择月"
>
</el-date-picker>
<q-btn
:loading=
"loading1"
color=
"primary"
size=
"11px"
label=
"生成提成"
@
click=
"scCommission"
style=
"margin-left:10px"
/>
</div>
</div>
</div>
</div>
<template
>
...
...
@@ -56,6 +74,13 @@
<el-table-column
prop=
"Id"
label=
"ID"
></el-table-column>
<el-table-column
prop=
"Periods"
label=
"周期"
></el-table-column>
<el-table-column
prop=
"SumPrice"
label=
"提成总金额"
>
</el-table-column>
<el-table-column
prop=
"SchooldCommission"
label=
"校区提成总金额"
>
<template
slot-scope=
"scope"
>
<div
style=
"display: flex;flex-wrap: wrap;"
v-if=
'scope.row.SchooldCommission>=0'
>
{{
scope
.
row
.
SchooldCommission
>=
0
?
scope
.
row
.
SchooldCommission
:
'-'
}}
</div>
</
template
>
</el-table-column>
<el-table-column
prop=
"FrIdList"
label=
"财务单据"
>
<
template
slot-scope=
"scope"
>
<div
style=
"display: flex;flex-wrap: wrap;"
v-if=
'scope.row.FrIdList.length>0'
>
...
...
@@ -74,8 +99,8 @@
<i
class=
"iconfont icon-sousuo"
@
click=
"goUrl('CommissionDetail',scope.row.Id)"
></i>
</el-tooltip>
<el-tooltip
class=
"item"
effect=
"dark"
content=
"制单"
placement=
"top"
>
<i
class=
"iconfont icon-add"
<el-tooltip
class=
"item"
effect=
"dark"
content=
"制单"
placement=
"top"
v-if=
'iscMaker==true'
>
<i
class=
"iconfont icon-add"
v-if=
'iscMaker==true'
@
click=
"generalFinancacls(scope.row)"
></i>
</el-tooltip>
</div>
...
...
@@ -84,8 +109,8 @@
</el-table>
<div
style=
"margin-top: 10px;text-align: center;"
>
<el-pagination
background
@
current-change=
"handleCurrentChanges"
layout=
"total,prev, pager, next, jumper"
:current-page
.
sync=
"msg.
pageIndex
"
:page-size=
"msg.
p
ageSize"
:total=
'total'
>
<el-pagination
background
@
current-change=
"handleCurrentChanges"
layout=
"total,prev, pager, next, jumper"
:current-page
.
sync=
"msg.
PageSize
"
:page-size=
"msg.
P
ageSize"
:total=
'total'
>
</el-pagination>
</div>
...
...
@@ -94,12 +119,16 @@
</div>
</template>
<
script
>
import
{
getSchoolDropdown
}
from
'../../api/school/index'
import
{
GetClassTypePageList
,
}
from
'../../api/system/index'
;
import
{
getSellCommissionPeriodsPageList
,
setSellCommissionRule
setSellCommissionRule
,
setSellCommissionInfo
}
from
'../../api/finance/index'
export
default
{
meta
:
{
...
...
@@ -110,35 +139,82 @@
data
()
{
return
{
loading
:
false
,
loading1
:
false
,
value2
:
''
,
//列表数据参数
msg
:
{
PageIndex
:
1
,
PageSize
:
20
,
Name
:
''
,
SchoolId
:
'-1'
},
pageCount
:
0
,
persistent
:
false
,
listData
:{},
tableData
:[],
total
:
0
total
:
0
,
CompanyList
:[],
isgenerate
:
false
,
//是否有生成的权限
iscMaker
:
false
,
//是否有制单的权限
}
},
created
()
{},
created
()
{
let
userinfo
=
this
.
getLocalStorage
();
userinfo
.
ActionMenuList
.
map
(
x
=>
{
//判断权限
if
(
x
.
FunctionCode
==
"Generate_Commission"
){
//判断是否有生成的权限
this
.
isgenerate
=
true
;
}
if
(
x
.
FunctionCode
==
"Commission_maker"
){
//判断是否有制单的权限
this
.
iscMaker
=
true
;
}
})
var
myDate
=
new
Date
();
myDate
.
setMonth
(
myDate
.
getMonth
()
-
1
);
this
.
value2
=
myDate
.
getFullYear
()
+
"-"
+
(
myDate
.
getMonth
()
+
1
)
},
mounted
()
{
this
.
getList
();
//获取提成周期列表
this
.
getBranchList
()
},
methods
:
{
getList
(){
this
.
loading
=
true
;
getSellCommissionPeriodsPageList
(
this
.
msg
).
then
(
res
=>
{
if
(
res
.
Code
==
1
)
{
this
.
tableData
=
res
.
Data
.
PageData
this
.
total
=
res
.
Data
.
Count
}
if
(
res
.
Code
==
1
)
{
this
.
tableData
=
res
.
Data
.
PageData
this
.
total
=
res
.
Data
.
Count
}
})
},
scCommission
(){
//生成提成
if
(
this
.
loading1
==
false
){
this
.
loading1
=
true
;
setSellCommissionInfo
({
Month
:
this
.
value2
}).
then
(
res
=>
{
if
(
res
.
Code
==
1
)
{
this
.
$q
.
notify
({
icon
:
'iconfont icon-chenggong'
,
color
:
'accent'
,
timeout
:
2000
,
message
:
'生成提成成功'
,
position
:
'top'
})
this
.
getList
()
}
this
.
loading1
=
false
;
}).
catch
(
err
=>
{
this
.
loading1
=
false
;
})
}
},
getBranchList
(){
//获取校区
getSchoolDropdown
({}).
then
(
res
=>
{
this
.
CompanyList
=
res
.
Data
;
}).
catch
(()
=>
{
})
},
goUrl
(
path
,
id
)
{
this
.
$router
.
push
({
path
:
'/financial/'
+
path
,
...
...
@@ -158,33 +234,66 @@
})
},
generalFinancacls
(
item
)
{
if
(
item
.
FrIdList
&&
item
.
FrIdList
.
length
>
0
)
{
this
.
Error
(
"请不要多次制单!"
)
return
;
if
(
this
.
msg
.
SchoolId
==
-
1
){
if
(
item
.
SumPrice
>
0
){
this
.
tishi
(
item
.
SumPrice
)
}
else
{
this
.
$message
.
error
(
'提成总金额为0'
)
}
}
else
{
if
(
item
.
SchooldCommission
>
0
){
this
.
goaddFinancial
(
item
.
SchooldCommission
)
}
else
{
this
.
$message
.
error
(
'校区提成总金额为0'
)
}
}
},
goaddFinancial
(
Money
){
let
School_Id
=
0
;
let
obj
=
{
CostType
:
16
,
Money
:
item
.
SumPrice
,
CurrencyId
:
21
,
XSTC
:
1
,
}
let
query
=
{
blank
:
"y"
,
tab
:
"新增付款单据"
,
Type
:
2
,
IsUploadPic
:
1
,
Name
:
'总部销售提成单'
,
id
:
28
,
orderObj
:
JSON
.
stringify
(
obj
)
}
this
.
$router
.
push
({
path
:
"/financial/financalDocument/addFinancialDocuments"
,
query
});
CostType
:
316
,
Money
:
Money
,
CurrencyId
:
21
,
XSTC
:
1
,
School_Id
:
this
.
msg
.
SchoolId
==
-
1
?
0
:
this
.
msg
.
SchoolId
,
}
let
query
=
{
blank
:
"y"
,
tab
:
"新增付款单据"
,
Type
:
2
,
IsUploadPic
:
1
,
Name
:
'销售提成单'
,
id
:
143
,
orderObj
:
JSON
.
stringify
(
obj
)
}
this
.
$router
.
push
({
path
:
"/financial/financalDocument/addFinancialDocuments"
,
query
});
},
tishi
(
Money
){
let
that
=
this
this
.
$q
.
dialog
({
title
:
"销售制单"
,
message
:
"你正在进行所有校区一起制单操作?"
,
persistent
:
true
,
cancel
:
{
label
:
"取消"
,
flat
:
true
},
ok
:
{
label
:
"确认"
,
flat
:
true
,
focus
:
true
}
}).
onOk
(()
=>
{
this
.
goaddFinancial
(
Money
)
});
},
handleCurrentChanges
(
val
){
console
.
log
(
val
)
this
.
msg
.
PageIndex
=
val
;
this
.
getList
()
},
...
...
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