提交 79368625 authored 作者: 王鹏飞's avatar 王鹏飞

修改评分模块

上级 3446b30a
...@@ -12,6 +12,9 @@ import { ...@@ -12,6 +12,9 @@ import {
import ScoreCard from './ScoreCard.vue' import ScoreCard from './ScoreCard.vue'
import ScoreCardLive from './ScoreCardLive.vue' import ScoreCardLive from './ScoreCardLive.vue'
import Preview from '@/components/Preview.vue' import Preview from '@/components/Preview.vue'
import { useUserStore } from '@/stores/user'
const userStore = useUserStore()
const statusList = useMapStore().getMapValuesByKey('system_status') const statusList = useMapStore().getMapValuesByKey('system_status')
...@@ -210,10 +213,33 @@ const activeTab = ref(1) ...@@ -210,10 +213,33 @@ const activeTab = ref(1)
const handleNext = () => { const handleNext = () => {
activeTab.value++ activeTab.value++
} }
const isScoreTeacher = computed(() => {
return ['15310038381', '15310038382', '15310038383', '15310038384', '15310038385', '15310038386'].includes(
userStore.user.mobile
)
})
watchEffect(() => {
if (isScoreTeacher.value) {
activeTab.value = scoreRules.value.length - 1
}
})
const disableTabPanel = (type) => {
if (type == 5 || type == 6) return false
return isScoreTeacher.value
}
</script> </script>
<template> <template>
<el-tabs stretch v-model="activeTab" class="score-tabs"> <el-tabs stretch v-model="activeTab" class="score-tabs">
<el-tab-pane v-for="(item, index) in scoreRules" :key="index" :label="item.name" :name="index + 1" lazy> <el-tab-pane
v-for="(item, index) in scoreRules"
:key="index"
:label="item.name"
:name="index + 1"
lazy
:disabled="disableTabPanel(item.type)">
<!-- 商品品类管理 --> <!-- 商品品类管理 -->
<template v-if="item.type == 1"> <template v-if="item.type == 1">
<ScoreCard <ScoreCard
...@@ -368,17 +394,21 @@ const handleNext = () => { ...@@ -368,17 +394,21 @@ const handleNext = () => {
width: 1000px; width: 1000px;
margin: 0 auto 20px; margin: 0 auto 20px;
} }
:deep(.el-tabs__nav-wrap::after) { :deep(.el-tabs__nav-wrap::after) {
display: none; display: none;
} }
} }
.score-header { .score-header {
display: flex; display: flex;
align-items: center; align-items: center;
.el-form { .el-form {
flex: 1; flex: 1;
} }
} }
.score-box { .score-box {
width: 100px; width: 100px;
border: 1px solid #dcdfe6; border: 1px solid #dcdfe6;
...@@ -390,11 +420,13 @@ const handleNext = () => { ...@@ -390,11 +420,13 @@ const handleNext = () => {
align-items: center; align-items: center;
justify-content: center; justify-content: center;
} }
.table-expand-box { .table-expand-box {
border: 1px solid #dcdfe6; border: 1px solid #dcdfe6;
padding: 20px; padding: 20px;
border-radius: 10px; border-radius: 10px;
} }
.form-box { .form-box {
width: 100%; width: 100%;
border: 1px solid #dcdfe6; border: 1px solid #dcdfe6;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论