Commit 16b44952 authored by zhengke's avatar zhengke

修改

parent 12ff5570
......@@ -10,10 +10,17 @@
<span v-if="subItem.TimeStr==='早上'" class="commonTimeStr greenTime">{{subItem.TimeStr}}</span>
<span v-if="subItem.TimeStr==='下午'" class="commonTimeStr blueTime">{{subItem.TimeStr}}</span>
<span v-if="subItem.TimeStr==='晚上'" class="commonTimeStr orangeTime">{{subItem.TimeStr}}</span>
<q-badge rounded color="orange" label="试听课" v-if="subItem.ClassType==2" style="margin-left:5px;font-size:10px"/>
<q-badge rounded color="cyan-7" label="预约课" v-if="subItem.ClassType==3" style="margin-left:5px;font-size:10px"/>
<q-badge rounded color="orange" label="试听课" v-if="subItem.ClassType==2"
style="margin-left:5px;font-size:10px" />
<q-badge rounded color="cyan-7" label="预约课" v-if="subItem.ClassType==3"
style="margin-left:5px;font-size:10px" />
<span style="color:red;margin:0 5px;">{{subItem.TeacherName}}</span>
<span>[{{subItem.RoomName}}]</span>
<template v-if="subItem.ClassType==3&&subItem.GuestList.length<subItem.ScrollMinNum">
<q-badge color="red" rounded style="margin-left:5px;">
</q-badge>
</template>
</div>
</template>
<div class="plan_Inner">
......@@ -35,12 +42,35 @@
:key="tIndex">{{tItem.GuestName}}</span>
</div>
</div>
<div class="plan_Inner" style="align-items:center;" v-if="subItem.CompleteProgress>=0">
<div class="plan_LeftTitle">课程进度:</div>
<div class="plan_RightInner">
<el-progress :percentage="subItem.CompleteProgress"></el-progress>
<template v-if="subItem.ClassType==3">
<div class="plan_Inner" style="align-items:center;">
<div class="plan_LeftTitle">课程进度:</div>
<div class="plan_RightInner">
<el-progress :percentage="GetPercent(subItem.Ranks,subItem.TotalPlanNum)"></el-progress>
</div>
</div>
</div>
</template>
<template v-else>
<div class="plan_Inner" style="align-items:center;" v-if="subItem.CompleteProgress>=0">
<div class="plan_LeftTitle">课程进度:</div>
<div class="plan_RightInner">
<el-progress :percentage="subItem.CompleteProgress"></el-progress>
</div>
</div>
</template>
<template v-if="subItem.ClassType==3">
<div class="plan_Inner">
<div class="plan_LeftTitle">课程状态:</div>
<div class="plan_RightInner" style="color: rgb(239, 83, 80);" v-if="subItem.AppointState==1">待确认</div>
<div class="plan_RightInner" style="color: rgb(33, 186, 69);" v-if="subItem.AppointState==2">已确认</div>
</div>
<div class="plan_Inner">
<div class="plan_LeftTitle">最小成班:</div>
<div class="plan_RightInner">
<span style="color: rgb(33, 186, 69);">{{subItem.ScrollMinNum}}</span>
</div>
</div>
</template>
</el-collapse-item>
</el-collapse>
</div>
......@@ -66,7 +96,16 @@
},
methods: {
GetPercent(num, total) {
num = parseFloat(num);
total = parseFloat(total);
if (isNaN(num) || isNaN(total)) {
undefined
return "-";
}
return total <= 0 ? 0 : (Math.round(num / total * 100) / 100.00);
}
}
}
</script>
\ No newline at end of file
</script>
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