|
@@ -13,22 +13,24 @@
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column label="主教课酬">
|
|
<el-table-column label="主教课酬">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
- <el-input v-model="scope.row.mainTeacherSalary" placeholder="请输入内容"></el-input>
|
|
|
|
|
|
+ <el-input v-model="scope.row.mainTeacherSalary" placeholder="请输入课酬"></el-input>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column label="助教课酬">
|
|
<el-table-column label="助教课酬">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
- <el-input v-model="scope.row.assistantTeacherSalary" placeholder="请输入内容"></el-input>
|
|
|
|
|
|
+ <el-input v-model="scope.row.assistantTeacherSalary" placeholder="请输入课酬"></el-input>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
- <el-table-column label="操作" width="100px">
|
|
|
|
|
|
+ <!-- <el-table-column label="操作" width="100px">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button @click="onMusicGroupSave2(scope.row)" type="text">保存</el-button>
|
|
<el-button @click="onMusicGroupSave2(scope.row)" type="text">保存</el-button>
|
|
</template>
|
|
</template>
|
|
- </el-table-column>
|
|
|
|
|
|
+ </el-table-column> -->
|
|
</el-table>
|
|
</el-table>
|
|
|
|
|
|
- <h3>单次课次参考时长:30min</h3>
|
|
|
|
|
|
+ <h3>单次课次参考时长:30min
|
|
|
|
+ <el-button @click="onVIPSave()" type="text">保存</el-button>
|
|
|
|
+ </h3>
|
|
<el-table :data='vipTable'
|
|
<el-table :data='vipTable'
|
|
:header-cell-style="{background:'#EDEEF0',color:'#444'}">
|
|
:header-cell-style="{background:'#EDEEF0',color:'#444'}">
|
|
<el-table-column label="VIP课课酬参考值" prop="vipGroupCategoryName">
|
|
<el-table-column label="VIP课课酬参考值" prop="vipGroupCategoryName">
|
|
@@ -43,15 +45,17 @@
|
|
<el-input v-model="scope.row.offlineClassesSalary" placeholder="请输入内容"></el-input>
|
|
<el-input v-model="scope.row.offlineClassesSalary" placeholder="请输入内容"></el-input>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
- <el-table-column label="操作" width="100px">
|
|
|
|
|
|
+ <!-- <el-table-column label="操作" width="100px">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button @click="onVIPSave(scope.row)" type="text">保存</el-button>
|
|
<el-button @click="onVIPSave(scope.row)" type="text">保存</el-button>
|
|
</template>
|
|
</template>
|
|
- </el-table-column>
|
|
|
|
|
|
+ </el-table-column> -->
|
|
</el-table>
|
|
</el-table>
|
|
</div>
|
|
</div>
|
|
<div class="right">
|
|
<div class="right">
|
|
- <h3>乐团课梯度课酬结算</h3>
|
|
|
|
|
|
+ <h3>乐团课梯度课酬结算
|
|
|
|
+ <el-button @click="onMusicGroupSave()" type="text">保存</el-button>
|
|
|
|
+ </h3>
|
|
<el-table :data="musicGroupTable" :header-cell-style="{background:'#EDEEF0',color:'#444'}">
|
|
<el-table :data="musicGroupTable" :header-cell-style="{background:'#EDEEF0',color:'#444'}">
|
|
<el-table-column label="">
|
|
<el-table-column label="">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
@@ -64,20 +68,24 @@
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column label="主教课酬">
|
|
<el-table-column label="主教课酬">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
- <el-input v-model="scope.row.mainTeacherSalary" placeholder="请输入内容"></el-input>
|
|
|
|
|
|
+ <el-input v-model="scope.row.mainTeacherSalary" placeholder="请输入课酬"></el-input>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column label="助教课酬">
|
|
<el-table-column label="助教课酬">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
- <el-input v-model="scope.row.assistantTeacherSalary" placeholder="请输入内容"></el-input>
|
|
|
|
|
|
+ <el-input v-model="scope.row.assistantTeacherSalary" placeholder="请输入课酬"></el-input>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
- <el-table-column label="操作" width="100px">
|
|
|
|
|
|
+ <!-- <el-table-column label="操作" width="100px">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button @click="onMusicGroupSave(scope.row)" type="text">保存</el-button>
|
|
<el-button @click="onMusicGroupSave(scope.row)" type="text">保存</el-button>
|
|
</template>
|
|
</template>
|
|
- </el-table-column>
|
|
|
|
|
|
+ </el-table-column> -->
|
|
|
|
+ <!-- <template slot="append" style="text-align: right;">
|
|
|
|
+ <el-button @click="onMusicGroupSave(scope.row)" type="text">保存</el-button>
|
|
|
|
+ </template> -->
|
|
</el-table>
|
|
</el-table>
|
|
|
|
+
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@@ -105,7 +113,7 @@ export default {
|
|
// 获取课程形态 设置vip课酬
|
|
// 获取课程形态 设置vip课酬
|
|
vipGroupCategory({ organId: this.$store.getters.organ }).then(res => {
|
|
vipGroupCategory({ organId: this.$store.getters.organ }).then(res => {
|
|
if (res.code == 200) {
|
|
if (res.code == 200) {
|
|
- this.vipList = res.data
|
|
|
|
|
|
+ // this.vipList = res.data
|
|
let vipData = res.data
|
|
let vipData = res.data
|
|
// VIP课列表
|
|
// VIP课列表
|
|
vipGroupSalaryList({
|
|
vipGroupSalaryList({
|
|
@@ -154,8 +162,10 @@ export default {
|
|
courseScheduleType: courseScheduleType,
|
|
courseScheduleType: courseScheduleType,
|
|
durationMax: type.max,
|
|
durationMax: type.max,
|
|
durationMin: type.min,
|
|
durationMin: type.min,
|
|
- mainTeacherSalary: 0,
|
|
|
|
- assistantTeacherSalary: 0
|
|
|
|
|
|
+ mainTeacherSalary: null,
|
|
|
|
+ assistantTeacherSalary: null,
|
|
|
|
+ userId: this.teacherId,
|
|
|
|
+ settlementType: 'GRADIENT_SALARY'
|
|
})
|
|
})
|
|
})
|
|
})
|
|
}
|
|
}
|
|
@@ -179,6 +189,10 @@ export default {
|
|
})
|
|
})
|
|
},
|
|
},
|
|
vipListCompare(vipData, rows) { // vip 做对比
|
|
vipListCompare(vipData, rows) { // vip 做对比
|
|
|
|
+ // console.log('start------------------')
|
|
|
|
+ // console.log(vipData)
|
|
|
|
+ // console.log(rows)
|
|
|
|
+ // console.log('end------------------')
|
|
if(!vipData) { // 判断是否有数据
|
|
if(!vipData) { // 判断是否有数据
|
|
this.vipTable = rows
|
|
this.vipTable = rows
|
|
return
|
|
return
|
|
@@ -213,43 +227,57 @@ export default {
|
|
this.vipTable = result
|
|
this.vipTable = result
|
|
},
|
|
},
|
|
teacherSalaryList(domain, rows) {
|
|
teacherSalaryList(domain, rows) {
|
|
- console.log(domain)
|
|
|
|
- console.log(rows)
|
|
|
|
if(domain.length <= 0) { // 判断后台是否有设置
|
|
if(domain.length <= 0) { // 判断后台是否有设置
|
|
this.musicGroupTable = rows
|
|
this.musicGroupTable = rows
|
|
return
|
|
return
|
|
}
|
|
}
|
|
|
|
+ if(!rows || rows.length <= 0) {
|
|
|
|
+ this.musicGroupTable = domain
|
|
|
|
+ }
|
|
let result = []
|
|
let result = []
|
|
domain.forEach(item => {
|
|
domain.forEach(item => {
|
|
- if(rows) {
|
|
|
|
- rows.forEach(c => {
|
|
|
|
- if(item.paramName == c.settlementType && item.max == c.durationMax && item.min == c.durationMin) {
|
|
|
|
- result.push({
|
|
|
|
- id: c.id,
|
|
|
|
- durationMax: c.durationMax,
|
|
|
|
- durationMin: c.durationMin,
|
|
|
|
- mainTeacherSalary: c.mainTeacherSalary,
|
|
|
|
- assistantTeacherSalary: c.assistantTeacherSalary,
|
|
|
|
- courseScheduleType: c.courseScheduleType
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- } else {
|
|
|
|
- result.push({
|
|
|
|
- durationMax: item.max,
|
|
|
|
- durationMin: item.min,
|
|
|
|
- assistantTeacherSalary: null,
|
|
|
|
- mainTeacherSalary: null,
|
|
|
|
- courseScheduleType: item.paramName
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
|
|
+ rows.forEach(c => {
|
|
|
|
+ if(item.courseScheduleType == c.courseScheduleType && item.durationMax == c.durationMax && item.durationMin == c.durationMin) {
|
|
|
|
+ item.checked = true
|
|
|
|
+ result.push({
|
|
|
|
+ durationMax: c.durationMax,
|
|
|
|
+ durationMin: c.durationMin,
|
|
|
|
+ mainTeacherSalary: c.mainTeacherSalary,
|
|
|
|
+ assistantTeacherSalary: c.assistantTeacherSalary,
|
|
|
|
+ courseScheduleType: c.courseScheduleType,
|
|
|
|
+ userId: this.teacherId,
|
|
|
|
+ settlementType: 'GRADIENT_SALARY'
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ })
|
|
})
|
|
})
|
|
- //
|
|
|
|
- if(rows) {
|
|
|
|
-
|
|
|
|
|
|
+ // console.log(result)
|
|
|
|
+ // console.log(domain)
|
|
|
|
+ if(result.length > 0) {
|
|
|
|
+ domain.forEach(item => {
|
|
|
|
+
|
|
|
|
+ })
|
|
|
|
+ // result.forEach(item => {
|
|
|
|
+ // domain.forEach(c => {
|
|
|
|
+ // if(item.courseScheduleType == c.courseScheduleType && item.durationMax == c.durationMax && item.durationMin == c.durationMin) {
|
|
|
|
+ // } else {
|
|
|
|
+ // result.push({
|
|
|
|
+ // durationMax: c.durationMax,
|
|
|
|
+ // durationMin: c.durationMin,
|
|
|
|
+ // mainTeacherSalary: c.mainTeacherSalary,
|
|
|
|
+ // assistantTeacherSalary: c.assistantTeacherSalary,
|
|
|
|
+ // courseScheduleType: c.courseScheduleType,
|
|
|
|
+ // userId: this.teacherId,
|
|
|
|
+ // settlementType: 'GRADIENT_SALARY'
|
|
|
|
+ // })
|
|
|
|
+ // }
|
|
|
|
+ // })
|
|
|
|
+ // })
|
|
|
|
+ } else {
|
|
|
|
+ result = domain
|
|
}
|
|
}
|
|
- console.log(result)
|
|
|
|
- // this.musicGroupTable = result
|
|
|
|
|
|
+ // console.log(result)
|
|
|
|
+ this.musicGroupTable = result
|
|
},
|
|
},
|
|
onVIPSave(row) { // vip保存
|
|
onVIPSave(row) { // vip保存
|
|
vipGroupSalarySet({
|
|
vipGroupSalarySet({
|
|
@@ -266,11 +294,18 @@ export default {
|
|
})
|
|
})
|
|
},
|
|
},
|
|
onMusicGroupSave(row) {
|
|
onMusicGroupSave(row) {
|
|
- teacherSalaryBatchUpset([{
|
|
|
|
- id: row.id,
|
|
|
|
- mainTeacherSalary: row.mainTeacherSalary,
|
|
|
|
- assistantTeacherSalary: row.assistantTeacherSalary
|
|
|
|
- }]).then(res => {
|
|
|
|
|
|
+ let musicGroupTable = this.musicGroupTable
|
|
|
|
+ let checkStatus = true
|
|
|
|
+ musicGroupTable.forEach(item => {
|
|
|
|
+ if(item.assistantTeacherSalary < 0 || item.mainTeacherSalary < 0) {
|
|
|
|
+ this.$message('输入课酬不能为负数')
|
|
|
|
+ checkStatus = false
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ // 判断输入的值是否正确
|
|
|
|
+ if(!checkStatus) return false
|
|
|
|
+ // return
|
|
|
|
+ teacherSalaryBatchUpset(musicGroupTable).then(res => {
|
|
if(res.code == 200) {
|
|
if(res.code == 200) {
|
|
this.$message({
|
|
this.$message({
|
|
message: '保存成功',
|
|
message: '保存成功',
|