Commit 62eaa310 authored by 王飞龙's avatar 王飞龙

个人开课

parent cc4925b6
......@@ -109,7 +109,7 @@
<!-- 开课类型-->
<el-table-column label="开课类型" prop="isPay" :show-overflow-tooltip="true">
<template slot-scope="scope">
<!-- {{ scope.row.isPay === 0 ? '试用' : '付费' }}-->
<!-- {{ scope.row.isPay === 0 ? '试用' : '付费' }}-->
<span v-if="scope.row.flag === '0'">{{ scope.row.isPay === 0 ? '试用' : '付费' }}</span>
<el-select
v-if="scope.row.flag === '1'"
......@@ -426,9 +426,9 @@
width="50"
align="center"
/>
<el-table-column label="单位" prop="unit">
<el-table-column label="单位" prop="applicantUnit">
<template slot-scope="scope">
{{ scope.row.unitName || '-' }}
{{ getUnitName(scope.row.applicantUnit) || '-' }}
</template>
</el-table-column>
<el-table-column label="课程" prop="class">
......@@ -466,22 +466,73 @@
</el-table-column>
<el-table-column label="开课类型" prop="isPay">
<template slot-scope="scope">
{{ scope.row.isPay === 0 ? '试用' : '付费' }}
<!-- {{ scope.row.isPay === 0 ? '试用' : '付费' }}-->
<span v-if="scope.row.flag === '0'">{{ scope.row.isPay === 0 ? '试用' : '付费' }}</span>
<el-select
v-if="scope.row.flag === '1'"
v-model="scope.row.isPay"
filterable
style="width: 160px"
>
<el-option
v-for="(items,index) in isPayList"
:key="index"
:label="items.label"
:value="items.value"
/>
</el-select>
</template>
</el-table-column>
<el-table-column label="岗位分类" prop="jobClassification">
<template slot-scope="scope">
{{ getJobClassificationName(scope.row.jobClassification) || '-' }}
<!-- {{ getJobClassificationName(scope.row.jobClassification) || '-' }}-->
<span v-if="scope.row.flag === '0'"> {{ getJobClassificationName(scope.row.jobClassification) || '-' }}</span>
<el-select
v-if="scope.row.flag === '1'"
v-model="scope.row.jobClassification"
filterable
style="width: 160px"
>
<el-option
v-for="(items,index) in valueOptions"
:key="index"
:label="items.dictLabel"
:value="items.dictValue"
/>
</el-select>
</template>
</el-table-column>
<el-table-column label="技术分类" prop="teDirection">
<template slot-scope="scope">
{{ getCourseDirectionName(scope.row.technicalClassification) || '-' }}
<!-- {{ getCourseDirectionName(scope.row.technicalClassification) || '-' }}-->
<span v-if="scope.row.flag === '0'"> {{ getCourseDirectionName(scope.row.technicalClassification) || '-' }}</span>
<el-select
v-if="scope.row.flag === '1'"
v-model="scope.row.technicalClassification"
filterable
style="width: 160px"
>
<el-option
v-for="(items,index) in courseDirection"
:key="index"
:label="items.dictLabel"
:value="items.dictValue"
/>
</el-select>
</template>
</el-table-column>
<el-table-column label="备注" prop="remarks">
<template slot-scope="scope">
{{ scope.row.remarks || '-' }}
<!-- {{ scope.row.remarks || '-' }}-->
<span v-if="scope.row.flag === '0'"> {{ scope.row.remarks || '-' }}</span>
<el-input
v-if="scope.row.flag === '1'"
v-model="scope.row.remarks"
placeholder="备注"
clearable
:maxlength="30"
size="small"
/>
</template>
</el-table-column>
<el-table-column label="操作" class-name="small-padding fixed-width">
......@@ -626,7 +677,7 @@ export default {
technicalClassification: '',
beginTrialTime: '',
endTrialTime: '',
applicantType: 1
applicantType: 2
},
// 开课类型list
isPayList: [
......@@ -686,6 +737,16 @@ export default {
this.unitOptions = res.data
})
},
// 根据id获取单位名称
getUnitName(businessId) {
let name = ''
this.unitOptions.forEach(item => {
if (item.businessId === businessId) {
name = item.unitName
}
})
return name
},
// 获取岗位类型
getJobClassification() {
// const obj = {
......@@ -818,7 +879,7 @@ export default {
technicalClassification: this.addForm.technicalClassification,
isPay: this.addForm.isPay,
remarks: this.addForm.remarks,
applicantType: 1
applicantType: 2
}
this.form.settingList.push(obj)
......@@ -945,20 +1006,6 @@ export default {
/** 修改按钮操作 */
handleUpdate(index) {
this.dateList[index].flag = '1'
// this.reset()
// const roleId = row.businessId || this.ids
// const roleMenu = this.getRoleMenuTreeSelect(roleId)
// getRole(roleId).then(response => {
// this.form = response.data
// this.open = true
//
// this.$nextTick(() => {
// roleMenu.then(res => {
// this.$refs.menu.setCheckedKeys(res.data.checkedKeys)
// })
// })
// this.title = '修改角色'
// })
},
/** 保存按钮操作 */
handleSave(index) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment