|
@@ -117,15 +117,14 @@
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="12" class="diSpan">
|
|
|
-
|
|
|
- <el-tooltip placement="top" popper-class='mTooltip'>
|
|
|
- <div slot="content">
|
|
|
- 「是」当前声部的学生都可以选择该老师;
|
|
|
- <br />「否」只有该老师的VIP课,单技课,基础技能课的学生可以选择该老师;
|
|
|
- </div>
|
|
|
- <img :src="imageIcon" class='micon el-tooltip' style="width:8px height:8px" alt="">
|
|
|
- </el-tooltip>
|
|
|
-
|
|
|
+ <el-tooltip placement="top" popper-class="mTooltip">
|
|
|
+ <div slot="content">
|
|
|
+ 「是」当前声部的学生都可以选择该老师;
|
|
|
+ <br />「否」只有该老师的VIP课,单技课,基础技能课的学生可以选择该老师;
|
|
|
+ </div>
|
|
|
+ <img :src="imageIcon" class="micon el-tooltip" style="width:8px height:8px" alt />
|
|
|
+ </el-tooltip>
|
|
|
+
|
|
|
<el-form-item label="开放陪练" label-width="90px" class="course">
|
|
|
<el-select
|
|
|
v-model.trim="topForm.isSupportExtraPracticeLesson"
|
|
@@ -136,7 +135,6 @@
|
|
|
<el-option label="是" :value="true"></el-option>
|
|
|
<el-option label="否" :value="false"></el-option>
|
|
|
</el-select>
|
|
|
-
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
@@ -253,12 +251,27 @@
|
|
|
<img v-if="topForm.avatar" key="avatar" :src="topForm.avatar" alt />
|
|
|
<img v-else key="avatar" src="@/assets/images/base/woman.png" alt />
|
|
|
</div>
|
|
|
+ <el-upload
|
|
|
+ class="ivu-upload"
|
|
|
+ :show-upload-list="false"
|
|
|
+ :show-file-list='false'
|
|
|
+ :headers="headers"
|
|
|
+ :on-success="handleSuccess"
|
|
|
+ :format="['jpg','jpeg','png','gif']"
|
|
|
+ :max-size="2048"
|
|
|
+ multiple
|
|
|
+ action="/api-web/uploadFile"
|
|
|
+ >
|
|
|
+ <el-button icon="ios-cloud-upload-outline" v-if="pageType != 'create'"v-permission="{child: 'api-web/uploadFile', parent: '/teacherUpdate/baseInfo'}">修改头像</el-button>
|
|
|
+ <el-button icon="ios-cloud-upload-outline" v-else v-permission="{child: 'api-web/uploadFile', parent: '/teacherAdd/baseInfo'}">修改头像</el-button>
|
|
|
+ </el-upload>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
|
// import { queryByOrganId } from '@/api/systemManage'
|
|
|
+import { getToken } from '@/utils/auth'
|
|
|
import { branchQueryPage, subjectListTree } from "@/api/specialSetting";
|
|
|
import { teacherAdd, teacherUpdate, teacherGet } from "@/api/teacherManager";
|
|
|
import store from "@/store";
|
|
@@ -278,6 +291,9 @@ export default {
|
|
|
name: "teacherOperation",
|
|
|
data() {
|
|
|
return {
|
|
|
+ headers: {
|
|
|
+ Authorization: getToken()
|
|
|
+ },
|
|
|
jobNature: jobNature,
|
|
|
organId: null,
|
|
|
pageType: this.$route.query.type,
|
|
@@ -306,10 +322,9 @@ export default {
|
|
|
certificateType: null,
|
|
|
certificateNum: null,
|
|
|
isSupportCourseScheduleRewardsRules: true,
|
|
|
- isSupportExtraPracticeLesson: null,
|
|
|
-
|
|
|
+ isSupportExtraPracticeLesson: null
|
|
|
},
|
|
|
- imageIcon:require('@/assets/images/base/warning.png'),
|
|
|
+ imageIcon: require("@/assets/images/base/warning.png"),
|
|
|
rules: {
|
|
|
realName: [
|
|
|
{ required: true, message: "请输入姓名", trigger: "blur" },
|
|
@@ -336,7 +351,8 @@ export default {
|
|
|
message: "请选择专业技能",
|
|
|
trigger: "change"
|
|
|
}
|
|
|
- ]
|
|
|
+ ],
|
|
|
+ isAvatar:null
|
|
|
}
|
|
|
};
|
|
|
},
|
|
@@ -357,6 +373,7 @@ export default {
|
|
|
if (this.$route.query.rules) {
|
|
|
this.Frules = this.$route.query.rules;
|
|
|
}
|
|
|
+ // isAvatar
|
|
|
branchQueryPage({
|
|
|
// 获取分部
|
|
|
delFlag: 0,
|
|
@@ -523,28 +540,37 @@ export default {
|
|
|
path: "/business/teacherList",
|
|
|
query: { rules: this.Frules, search: this.Fsearch }
|
|
|
});
|
|
|
- }
|
|
|
+ },
|
|
|
+ handleSuccess (res) {
|
|
|
+ // 获取富文本组件实例
|
|
|
+ // let quill = this.editor
|
|
|
+ // 如果上传成功
|
|
|
+ if (res.code == 200) {
|
|
|
+ // 获取光标所在位置
|
|
|
+ this.topForm.avatar = res.data.url
|
|
|
+ }
|
|
|
+ },
|
|
|
}
|
|
|
};
|
|
|
</script>
|
|
|
<style lang="scss" scoped>
|
|
|
.atooltip.el-tooltip__popper[x-placement^="top"] .popper__arrow {
|
|
|
- border-top-color: #ECF0F0;
|
|
|
+ border-top-color: #ecf0f0;
|
|
|
color: #666666;
|
|
|
}
|
|
|
.atooltip.el-tooltip__popper[x-placement^="top"] .popper__arrow:after {
|
|
|
- border-top-color: #ECF0F0;
|
|
|
- color: #666666;
|
|
|
+ border-top-color: #ecf0f0;
|
|
|
+ color: #666666;
|
|
|
}
|
|
|
.atooltip {
|
|
|
- background: #ECF0F0 !important;
|
|
|
- color: #666666;
|
|
|
+ background: #ecf0f0 !important;
|
|
|
+ color: #666666;
|
|
|
}
|
|
|
.diSpan {
|
|
|
position: relative;
|
|
|
.micon {
|
|
|
position: absolute;
|
|
|
- top:12px;
|
|
|
+ top: 12px;
|
|
|
left: 64px;
|
|
|
}
|
|
|
}
|
|
@@ -610,12 +636,16 @@ export default {
|
|
|
}
|
|
|
.right {
|
|
|
margin-left: 100px;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ align-items: center;
|
|
|
.teacherIcon {
|
|
|
width: 150px;
|
|
|
height: 150px;
|
|
|
// border: 1px solid #444;
|
|
|
border-radius: 50%;
|
|
|
overflow: hidden;
|
|
|
+ margin-bottom: 20px;
|
|
|
img {
|
|
|
width: 150px;
|
|
|
height: 150px;
|