Branch_d40a2540
yujialong 2 years ago
parent d5f8a827dd
commit 16206af273
  1. BIN
      src/assets/img/product/1.png
  2. BIN
      src/assets/img/product/2.png
  3. BIN
      src/assets/img/product/3.png
  4. BIN
      src/assets/img/product/4.png
  5. BIN
      src/assets/img/product/5.png
  6. 175
      src/pages/product/list/index.vue
  7. 206
      src/pages/product/show/index.vue
  8. 209
      src/pages/project/add/index.vue
  9. 142
      src/pages/project/list/index.vue
  10. 43
      src/pages/station/list/index.vue
  11. 293
      src/pages/station/preview/index.vue

Binary file not shown.

After

Width:  |  Height:  |  Size: 667 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 451 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 581 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 490 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 585 B

@ -1,10 +1,14 @@
<template> <template>
<div class="wrap"> <div class="wrap">
<el-carousel :interval="6000" :height="carouselHeight"> <el-carousel :interval="6000"
:height="carouselHeight">
<template v-for="(item, i) in banners"> <template v-for="(item, i) in banners">
<el-carousel-item :key="i"> <el-carousel-item :key="i">
<div :class="['banner-item', {'cursor-pointer': item.url}]" @click="openLink(item)"> <div :class="['banner-item', {'cursor-pointer': item.url}]"
<img :src="item.banner" alt="" :style="{height: carouselHeight}"> @click="openLink(item)">
<img :src="item.banner"
alt=""
:style="{height: carouselHeight}">
<p class="banner-name">{{ item.title }}</p> <p class="banner-name">{{ item.title }}</p>
</div> </div>
</el-carousel-item> </el-carousel-item>
@ -14,15 +18,25 @@
<div class="inner"> <div class="inner">
<div class="typw-wrap"> <div class="typw-wrap">
<div> <div>
<img src="@/assets/img/hot.png" alt=""> <img src="@/assets/img/hot.png"
<img class="m-l-5 m-r-10" src="@/assets/img/type.png" alt=""> alt="">
<img class="m-l-5 m-r-10"
src="@/assets/img/type.png"
alt="">
<ul class="tab"> <ul class="tab">
<li v-for="(tab, i) in tabs" :key="i" :class="{active: curTab === tab.id}" @click="tabChange(tab)">{{ tab.name }}</li> <li v-for="(tab, i) in tabs"
:key="i"
:class="{active: curTab === tab.id}"
@click="tabChange(tab)">{{ tab.name }}</li>
</ul> </ul>
</div> </div>
<div class="search"> <div class="search">
<img class="icon" src="@/assets/img/search.png" alt=""> <img class="icon"
<input type="text" placeholder="请输入产品名称" v-model="form.productName"> src="@/assets/img/search.png"
alt="">
<input type="text"
placeholder="请输入产品名称"
v-model="form.productName">
</div> </div>
</div> </div>
<div class="filter"> <div class="filter">
@ -30,48 +44,86 @@
<dt>学科专业</dt> <dt>学科专业</dt>
<dd>学科类别</dd> <dd>学科类别</dd>
<el-select v-model="form.categoryId" clearable @change="getProfessionalClass()" @clear="clearClass()"> <el-select v-model="form.categoryId"
<el-option label="不限" value=""></el-option> clearable
<el-option v-for="(item,index) in subjectList" :key="index" :label="item.disciplineName" :value="item.disciplineId"></el-option> @change="getProfessionalClass()"
@clear="clearClass()">
<el-option label="不限"
value=""></el-option>
<el-option v-for="(item,index) in subjectList"
:key="index"
:label="item.disciplineName"
:value="item.disciplineId"></el-option>
</el-select> </el-select>
<dd style="margin: 0 0 0 50px">专业类</dd> <dd style="margin: 0 0 0 50px">专业类</dd>
<el-select v-model="form.professionalCategoryId" clearable :disabled="form.categoryId ? false : true" @change="getProfessional" @clear="clearProfess()"> <el-select v-model="form.professionalCategoryId"
<el-option label="不限" value=""></el-option> clearable
<el-option v-for="(item,index) in professionalClassList" :key="index" :label="item.professionalClassName" :value="item.professionalClassId"></el-option> :disabled="form.categoryId ? false : true"
@change="getProfessional"
@clear="clearProfess()">
<el-option label="不限"
value=""></el-option>
<el-option v-for="(item,index) in professionalClassList"
:key="index"
:label="item.professionalClassName"
:value="item.professionalClassId"></el-option>
</el-select> </el-select>
<dd style="margin: 0 0 0 50px">专业</dd> <dd style="margin: 0 0 0 50px">专业</dd>
<el-select v-model="form.professionalId" clearable :disabled="form.professionalCategoryId ? false : true" @change="initData"> <el-select v-model="form.professionalId"
<el-option label="不限" value=""></el-option> clearable
<el-option v-for="(item,index) in professionalList" :key="index" :label="item.professionalName" :value="item.professionalId"></el-option> :disabled="form.professionalCategoryId ? false : true"
@change="initData">
<el-option label="不限"
value=""></el-option>
<el-option v-for="(item,index) in professionalList"
:key="index"
:label="item.professionalName"
:value="item.professionalId"></el-option>
</el-select> </el-select>
</dl> </dl>
<dl v-if="curTab == 3"> <dl v-if="curTab == 3">
<dt>产品标签</dt> <dt>产品标签</dt>
<div class="vals"> <div class="vals">
<dd :class="{active: form.tagId === ''}" @click="filterChange('', 'tagId')">全部</dd> <dd :class="{active: form.tagId === ''}"
<dd v-for="(item, i) in labels" :key="i" :class="{active: form.tagId === item.tagsId}" @click="filterChange(item.tagsId, 'tagId')">{{ item.tagsName }}</dd> @click="filterChange('', 'tagId')">全部</dd>
<dd v-for="(item, i) in labels"
:key="i"
:class="{active: form.tagId === item.tagsId}"
@click="filterChange(item.tagsId, 'tagId')">{{ item.tagsName }}</dd>
</div> </div>
</dl> </dl>
<dl> <dl>
<dt>产品类型</dt> <dt>产品类型</dt>
<div class="vals"> <div class="vals">
<dd :class="{active: form.productClassification === ''}" @click="filterChange('', 'productClassification')">全部</dd> <dd :class="{active: form.productClassification === ''}"
<dd v-for="(item, i) in classifications" :key="i" :class="{active: form.productClassification === item.typeId}" @click="filterChange(item.typeId, 'productClassification')">{{ item.typeName }}</dd> @click="filterChange('', 'productClassification')">全部</dd>
<dd v-for="(item, i) in classifications"
:key="i"
:class="{active: form.productClassification === item.typeId}"
@click="filterChange(item.typeId, 'productClassification')">{{ item.typeName }}</dd>
</div> </div>
</dl> </dl>
<dl> <dl>
<dt>购买状态</dt> <dt>购买状态</dt>
<dd v-for="(item, i) in status" :key="i" :class="{active: form.purchaseStatus === item.id}" @click="filterChange(item.id, 'purchaseStatus')">{{ item.name }}</dd> <dd v-for="(item, i) in status"
:key="i"
:class="{active: form.purchaseStatus === item.id}"
@click="filterChange(item.id, 'purchaseStatus')">{{ item.name }}</dd>
</dl> </dl>
</div> </div>
<div class="filter m-t-20"> <div class="filter m-t-20">
<dl> <dl>
<dd v-for="(item, i) in sorts" :key="i" :class="{active: form.sort === item.id}" @click="filterChange(item.id, 'sort')">{{ item.name }}</dd> <dd v-for="(item, i) in sorts"
<dd :class="{active: form.sort === 2 || form.sort === 5}" @click="sort">发布时间</dd> :key="i"
<span class="caret" @click="sort"> :class="{active: form.sort === item.id}"
@click="filterChange(item.id, 'sort')">{{ item.name }}</dd>
<dd :class="{active: form.sort === 2 || form.sort === 5}"
@click="sort">发布时间</dd>
<span class="caret"
@click="sort">
<i :class="['asc', {active: form.sort === 2}]"></i> <i :class="['asc', {active: form.sort === 2}]"></i>
<i :class="['desc', {active: form.sort === 5}]"></i> <i :class="['desc', {active: form.sort === 5}]"></i>
</span> </span>
@ -81,35 +133,57 @@
<div class="courses"> <div class="courses">
<template v-if="list.length"> <template v-if="list.length">
<ul> <ul>
<li v-for="(item, i) in list" :key="i" @click="toDetail(item.mallId)"> <li v-for="(item, i) in list"
<img :src="item.coverDrawing" alt="" /> :key="i"
<img v-if="item.logoOfOurSchool" class="my-school" src="@/assets/img/my-school.png" alt=""> @click="toDetail(item.mallId)">
<img :src="item.coverDrawing"
alt="" />
<img v-if="item.logoOfOurSchool"
class="my-school"
src="@/assets/img/my-school.png"
alt="">
<div class="texts"> <div class="texts">
<el-tooltip effect="dark" :visible-arrow="false" :content="item.productName" placement="bottom"> <el-tooltip effect="dark"
:visible-arrow="false"
:content="item.productName"
placement="bottom">
<div class="title">{{ item.productName }}</div> <div class="title">{{ item.productName }}</div>
</el-tooltip> </el-tooltip>
<div class="desc" v-html="item.productIntroduction"></div> <div class="desc"
v-html="item.productIntroduction"></div>
<div class="tags"> <div class="tags">
<el-tooltip v-if="item.tagsName" class="item" effect="dark" :visible-arrow="false" :content="item.tagsName" placement="bottom"> <el-tooltip v-if="item.tagsName"
class="item"
effect="dark"
:visible-arrow="false"
:content="item.tagsName"
placement="bottom">
<div> <div>
<el-tag v-for="(tag, i) in item.tagsName.split(',')" :key="i" class="tag">{{ tag }}</el-tag> <el-tag v-for="(tag, i) in item.tagsName.split(',')"
:key="i"
class="tag">{{ tag }}</el-tag>
</div> </div>
</el-tooltip> </el-tooltip>
</div> </div>
<div :class="['metas', {'not-selected': !item.selected}]"> <div :class="['metas', {'not-selected': !item.selected}]">
<el-tag <el-tag v-if="item.selected"
v-if="item.selected"
type="danger" type="danger"
effect="dark"> effect="dark">
官方精选 官方精选
</el-tag> </el-tag>
<div v-if="item.isCourse" class="meta">{{ item.learningCount }}人学过</div> <div v-if="item.isCourse"
class="meta">{{ item.learningCount }}人学过</div>
</div> </div>
</div> </div>
</li> </li>
</ul> </ul>
<div class="pagination"> <div class="pagination">
<el-pagination background layout="total, prev, pager, next" :page-size="pageSize" :total="total" @current-change="handleCurrentChange" :current-page="page"></el-pagination> <el-pagination background
layout="total, prev, pager, next"
:page-size="pageSize"
:total="total"
@current-change="handleCurrentChange"
:current-page="page"></el-pagination>
</div> </div>
</template> </template>
</div> </div>
@ -333,6 +407,10 @@ export default {
this.classificationList = page.records this.classificationList = page.records
}).catch(res => { }) }).catch(res => { })
}, },
// banner
openLink (item) {
item.url && window.open(item.url)
},
// tab // tab
tabChange ({ id }) { tabChange ({ id }) {
this.curTab = id this.curTab = id
@ -381,7 +459,7 @@ export default {
top: 116px; top: 116px;
left: 188px; left: 188px;
font-size: 50px; font-size: 50px;
color: #2E2D31; color: #2e2d31;
} }
} }
.inner { .inner {
@ -402,7 +480,7 @@ export default {
margin: 0 20px; margin: 0 20px;
font-size: 18px; font-size: 18px;
line-height: 25px; line-height: 25px;
color: #0B1D30; color: #0b1d30;
cursor: pointer; cursor: pointer;
&:after { &:after {
content: ''; content: '';
@ -414,7 +492,7 @@ export default {
transform: translateX(-50%); transform: translateX(-50%);
} }
&.active:after { &.active:after {
background-color: #007EFF; background-color: #007eff;
} }
} }
} }
@ -463,7 +541,7 @@ export default {
cursor: pointer; cursor: pointer;
&.active { &.active {
font-weight: 600; font-weight: 600;
color: #007EFF; color: #007eff;
} }
} }
} }
@ -525,7 +603,7 @@ export default {
img { img {
width: 100%; width: 100%;
height: 140px; height: 140px;
transition: .3s; transition: 0.3s;
} }
.my-school { .my-school {
position: absolute; position: absolute;
@ -539,7 +617,7 @@ export default {
} }
.title { .title {
margin-bottom: 10px; margin-bottom: 10px;
color: #0B1D30; color: #0b1d30;
font-size: 14px; font-size: 14px;
font-weight: 600; font-weight: 600;
word-wrap: break-word; word-wrap: break-word;
@ -550,7 +628,7 @@ export default {
} }
.desc { .desc {
min-height: 34px; min-height: 34px;
color: #757F92; color: #757f92;
font-size: 12px; font-size: 12px;
display: -webkit-box; display: -webkit-box;
-webkit-box-orient: vertical; -webkit-box-orient: vertical;
@ -564,8 +642,8 @@ export default {
} }
.tag { .tag {
margin-right: 8px; margin-right: 8px;
color: #007EFF; color: #007eff;
background-color: #F9F9F9; background-color: #f9f9f9;
border: 0; border: 0;
} }
.type { .type {
@ -573,7 +651,7 @@ export default {
padding: 4px 11px; padding: 4px 11px;
font-size: 12px; font-size: 12px;
color: #666; color: #666;
border: 1px solid #DADADA; border: 1px solid #dadada;
border-radius: 20px; border-radius: 20px;
} }
.metas { .metas {
@ -588,7 +666,7 @@ export default {
.meta { .meta {
display: inline-flex; display: inline-flex;
align-items: center; align-items: center;
color: #B5BFD5; color: #b5bfd5;
font-size: 12px; font-size: 12px;
.icon { .icon {
width: 14px; width: 14px;
@ -597,7 +675,8 @@ export default {
} }
} }
&:hover { &:hover {
box-shadow: 0px 5px 12px 4px rgba(142, 123, 253, 0.09), 0px 3px 6px 0px rgba(142, 123, 253, 0.12), 0px 1px 2px -2px rgba(142, 123, 253, 0.16); box-shadow: 0px 5px 12px 4px rgba(142, 123, 253, 0.09), 0px 3px 6px 0px rgba(142, 123, 253, 0.12),
0px 1px 2px -2px rgba(142, 123, 253, 0.16);
img { img {
transform: scale(1.05); transform: scale(1.05);
} }

@ -2,52 +2,97 @@
<div class="wrap"> <div class="wrap">
<div class="inner"> <div class="inner">
<div class="top"> <div class="top">
<div v-if="form.interfaceDiagrams" class="pics"> <div v-if="form.interfaceDiagrams && height"
<img v-for="(pic, i) in form.interfaceDiagrams" :key="i" :src="pic" alt=""> class="pics"
:style="{height: form.interfaceDiagrams.length === 1 ? height: 'auto'}">
<img v-for="(pic, i) in form.interfaceDiagrams"
:key="i"
:src="pic"
alt="">
</div> </div>
<div class="right"> <div class="right"
id="fields">
<h6>{{ form.mall.productName }}</h6> <h6>{{ form.mall.productName }}</h6>
<div v-if="isCourse" class="meta"> <div v-if="isCourse"
class="meta">
<span class="val">{{ form.numberOfExperimentalItems }}</span> 个实验项目&emsp;&emsp; <span class="val">{{ form.numberOfExperimentalItems }}</span> 个实验项目&emsp;&emsp;
已有 <span class="val">{{ form.goodsRes.learningCount }}</span>人学过 已有 <span class="val">{{ form.goodsRes.learningCount }}</span>人学过
</div> </div>
<div class="des" v-html="form.mall.productIntroduction"></div> <div class="des"
<div class="field">适用专业{{ form.goodsRes.professionalName }}</div> v-html="form.mall.productIntroduction"></div>
<div class="fields"> <div class="fields">
<div v-if="form.mall.applicationScenario" class="field"><span class="label">适用场景</span>{{ form.mall.applicationScenario }}</div> <div class="field"><img src="@/assets/img/product/1.png"
<div v-if="form.mall.matchingCourse" class="field"><span class="label">匹配课程</span>{{ form.mall.matchingCourse }}</div> alt=""> 适用专业{{ form.goodsRes.professionalName }}</div>
<div v-if="form.mall.courseHours" class="field"><span class="label">预计课时</span>{{ form.mall.courseHours }}</div> <div v-if="form.mall.applicationScenario"
<div v-if="form.goodsRes.typeName" class="field"><span class="label">产品类型</span>{{ form.goodsRes.typeName }}</div> class="field"><span class="label"><img src="@/assets/img/product/2.png"
alt=""> 适用场景</span>{{ form.mall.applicationScenario }}</div>
<div v-if="form.mall.matchingCourse"
class="field"><span class="label"><img src="@/assets/img/product/3.png"
alt=""> 匹配课程</span>{{ form.mall.matchingCourse }}</div>
<div v-if="form.mall.courseHours"
class="field"><span class="label"><img src="@/assets/img/product/4.png"
alt=""> 预计课时</span>{{ form.mall.courseHours }}</div>
<div v-if="form.goodsRes.typeName"
class="field"><span class="label"><img src="@/assets/img/product/5.png"
alt=""> 产品类型</span>{{ form.goodsRes.typeName }}</div>
</div> </div>
<button v-if="!form.goodsRes.logoOfOurSchool" class="btn" @click="toTrail">试用体验</button> <button v-if="!form.goodsRes.logoOfOurSchool"
<button v-else-if="isCourse || withLink" class="btn entry" @click="toStation">进入实验</button> class="btn"
@click="toTrail">试用体验</button>
<button v-else-if="isCourse || withLink"
class="btn entry"
@click="toStation">进入实验</button>
</div> </div>
</div> </div>
<div class="course"> <div class="course">
<div class="detail"> <div class="detail">
<ul class="tab"> <ul class="tab">
<li v-for="(tab, i) in tabs" :key="i" :class="{active: curTab === tab.id}" @click="tabChange(tab)">{{ tab.name }}</li> <li v-for="(tab, i) in tabs"
:key="i"
:class="{active: curTab === tab.id}"
@click="tabChange(tab)">{{ tab.name }}</li>
</ul> </ul>
<div class="courses"> <div class="courses">
<template v-if="!curTab"> <template v-if="!curTab">
<div class="des" v-html="form.mall.detailedIntroduction"></div> <div class="des"
v-html="form.mall.detailedIntroduction"></div>
</template> </template>
<template v-else> <template v-else>
<div class="chapter" v-for="(item, i) in chapterList" :key="i"> <div class="chapter"
v-for="(item, i) in chapterList"
:key="i">
<div class="chapterName">{{ item.name }}</div> <div class="chapterName">{{ item.name }}</div>
<div class="section" v-if="item.subsectionList.length"> <div class="section"
<div v-for="(section, j) in item.subsectionList" :key="j" @click="toPreview(i, j)"> v-if="item.subsectionList.length">
<div class="sectionName" :title="section.name" :class="{active: curLink === `${item.name}${section.name}`}"> <div v-for="(section, j) in item.subsectionList"
:key="j"
@click="toPreview(i, j)">
<div class="sectionName"
:title="section.name"
:class="{active: curLink === `${item.name}${section.name}`}">
<div class="val"> <div class="val">
<img v-if="section.fileType === 'pptx'" src="@/assets/img/exts/ppt.png" alt=""> <img v-if="section.fileType === 'pptx'"
<img v-else-if="section.fileType === 'mp4'" src="@/assets/img/exts/video.png" alt=""> src="@/assets/img/exts/ppt.png"
<img v-else-if="section.fileType === 'doc' || section.fileType === 'docx'" src="@/assets/img/exts/word.png" alt=""> alt="">
<img v-else-if="section.fileType === 'txt'" src="@/assets/img/exts/txt.png" alt=""> <img v-else-if="section.fileType === 'mp4'"
<img v-else-if="section.fileType === 'pdf'" src="@/assets/img/exts/pdf.png" alt=""> src="@/assets/img/exts/video.png"
<img v-else src="@/assets/img/exts/pic.png" alt=""> alt="">
<img v-else-if="section.fileType === 'doc' || section.fileType === 'docx'"
src="@/assets/img/exts/word.png"
alt="">
<img v-else-if="section.fileType === 'txt'"
src="@/assets/img/exts/txt.png"
alt="">
<img v-else-if="section.fileType === 'pdf'"
src="@/assets/img/exts/pdf.png"
alt="">
<img v-else
src="@/assets/img/exts/pic.png"
alt="">
{{ section.name }} {{ section.name }}
</div> </div>
<i v-if="!form.goodsRes.logoOfOurSchool" class="icon el-icon-lock"></i> <i v-if="!form.goodsRes.logoOfOurSchool"
class="icon el-icon-lock"></i>
</div> </div>
</div> </div>
</div> </div>
@ -58,23 +103,33 @@
<div class="products"> <div class="products">
<h6>热门产品推荐</h6> <h6>热门产品推荐</h6>
<ul class="product"> <ul class="product">
<li v-for="(item, i) in hots" :key="i" @click="toDetail(item.mallId)"> <li v-for="(item, i) in hots"
<img :src="item.coverDrawing" alt="" /> :key="i"
<img v-if="item.logoOfOurSchool" class="my-school" src="@/assets/img/my-school.png" alt=""> @click="toDetail(item.mallId)">
<img :src="item.coverDrawing"
alt="" />
<img v-if="item.logoOfOurSchool"
class="my-school"
src="@/assets/img/my-school.png"
alt="">
<div class="texts"> <div class="texts">
<div class="title">{{ item.productName }}</div> <div class="title">{{ item.productName }}</div>
<div :class="['desc', {'not-tag': !item.tagsName}]" v-html="item.productIntroduction"></div> <div :class="['desc', {'not-tag': !item.tagsName}]"
<div v-if="item.tagsName" class="tags"> v-html="item.productIntroduction"></div>
<el-tag v-for="(tag, i) in item.tagsName.split(',')" :key="i" class="tag">{{ tag }}</el-tag> <div v-if="item.tagsName"
class="tags">
<el-tag v-for="(tag, i) in item.tagsName.split(',')"
:key="i"
class="tag">{{ tag }}</el-tag>
</div> </div>
<div class="metas"> <div class="metas">
<el-tag <el-tag v-if="item.selected"
v-if="item.selected"
type="danger" type="danger"
effect="dark"> effect="dark">
官方精选 官方精选
</el-tag> </el-tag>
<div v-if="item.isCourse" class="meta">{{ item.learningCount }}人学过</div> <div v-if="item.isCourse"
class="meta">{{ item.learningCount }}人学过</div>
</div> </div>
</div> </div>
</li> </li>
@ -84,11 +139,20 @@
</div> </div>
<!-- 选择链接 --> <!-- 选择链接 -->
<el-dialog title="请选择链接" :visible.sync="linkVisible" width="420px" center :close-on-click-modal="false"> <el-dialog title="请选择链接"
<div v-if="withLink" class="buy"> :visible.sync="linkVisible"
<div v-for="(link, i) in form.mallNonAssociatedLinks" :key="i" class="link-line"> width="420px"
center
:close-on-click-modal="false">
<div v-if="withLink"
class="buy">
<div v-for="(link, i) in form.mallNonAssociatedLinks"
:key="i"
class="link-line">
{{ link.urlName }} {{ link.urlName }}
<a class="url" :href="link.url" target="_blank">{{ link.url }}</a> <a class="url"
:href="link.url"
target="_blank">{{ link.url }}</a>
</div> </div>
</div> </div>
</el-dialog> </el-dialog>
@ -116,7 +180,8 @@ export default {
}, },
chapterList: [], chapterList: [],
hots: [], hots: [],
linkVisible: false linkVisible: false,
height: ''
}; };
}, },
computed: { computed: {
@ -161,6 +226,9 @@ export default {
this.form = e this.form = e
this.chapterList = '' this.chapterList = ''
e.mall.associatedProduct && this.getChapter() e.mall.associatedProduct && this.getChapter()
this.$nextTick(() => {
this.height = document.querySelector('#fields').clientHeight + 'px'
})
}).catch(err => { }) }).catch(err => { })
}, },
// //
@ -175,7 +243,7 @@ export default {
// //
toPreview (i, j) { toPreview (i, j) {
this.form.goodsRes.logoOfOurSchool ? this.form.goodsRes.logoOfOurSchool ?
this.$router.push(`/station/preview?courseId=${this.form.mall.associatedProduct}&curriculumName=${this.form.mall.associatedProductName}&mallId=${this.id}&chapter=${i}&section=${j}`) : this.$router.push(`/station/preview?courseId=${this.form.mall.associatedProduct}&curriculumName=${this.form.mall.associatedProductName}&mallId=${this.id}&chapter=${i}&section=${j}&admin=1`) :
this.toTrail() this.toTrail()
}, },
// / // /
@ -237,7 +305,7 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
.wrap { .wrap {
background: #F3F6FA; background: #f3f6fa;
.inner { .inner {
width: 1154px; width: 1154px;
margin: 0 auto; margin: 0 auto;
@ -263,6 +331,12 @@ export default {
&:last-child { &:last-child {
margin-right: 0; margin-right: 0;
} }
&:only-child {
// max-height: 266px;
// height: auto;
height: 100%;
margin: 0;
}
} }
} }
.right { .right {
@ -272,14 +346,14 @@ export default {
h6 { h6 {
font-size: 24px; font-size: 24px;
font-weight: 600; font-weight: 600;
color: #2E2D31; color: #2e2d31;
} }
.meta { .meta {
margin: 10px 0; margin: 10px 0;
font-size: 12px; font-size: 12px;
color: #2E2D31; color: #2e2d31;
.val { .val {
color: #007EFF; color: #007eff;
} }
} }
.des { .des {
@ -287,20 +361,24 @@ export default {
font-size: 14px; font-size: 14px;
color: #666; color: #666;
line-height: 20px; line-height: 20px;
@include mul-ellipsis(3);
} }
.field { .field {
font-size: 14px; font-size: 14px;
color: #2E2D31; color: #2e2d31;
.label { .label {
color: #333; color: #333;
} }
} }
.fields { .fields {
display: flex; display: flex;
justify-content: space-between; // justify-content: space-between;
flex-wrap: wrap; flex-wrap: wrap;
height: 60px;
margin: 10px 0 10px; margin: 10px 0 10px;
overflow: hidden;
.field { .field {
margin-right: 40px;
margin-bottom: 10px; margin-bottom: 10px;
} }
} }
@ -308,19 +386,19 @@ export default {
width: 119px; width: 119px;
height: 46px; height: 46px;
color: #fff; color: #fff;
background: #64C25A; background: #64c25a;
border-radius: 6px; border-radius: 6px;
border: 0; border: 0;
cursor: pointer; cursor: pointer;
&:hover { &:hover {
opacity: .9; opacity: 0.9;
} }
&:first-child { &:first-child {
margin-left: 11px; margin-left: 11px;
} }
} }
.entry { .entry {
background: #007EFF; background: #007eff;
} }
} }
.tab { .tab {
@ -331,7 +409,7 @@ export default {
margin-right: 20px; margin-right: 20px;
font-size: 18px; font-size: 18px;
line-height: 25px; line-height: 25px;
color: #0B1D30; color: #0b1d30;
cursor: pointer; cursor: pointer;
&:after { &:after {
content: ''; content: '';
@ -343,7 +421,7 @@ export default {
transform: translateX(-50%); transform: translateX(-50%);
} }
&.active:after { &.active:after {
background-color: #007EFF; background-color: #007eff;
} }
} }
} }
@ -355,7 +433,6 @@ export default {
padding: 20px 24px; padding: 20px 24px;
background-color: #fff; background-color: #fff;
border-radius: 10px; border-radius: 10px;
} }
} }
.courses { .courses {
@ -388,8 +465,8 @@ export default {
margin-right: 8px; margin-right: 8px;
} }
&:hover { &:hover {
color: #007EFF; color: #007eff;
background: #F6FBFF; background: #f6fbff;
} }
.val { .val {
display: inline-flex; display: inline-flex;
@ -406,7 +483,7 @@ export default {
margin-left: 24px; margin-left: 24px;
& > h6 { & > h6 {
font-size: 14px; font-size: 14px;
color: #0B1D30; color: #0b1d30;
} }
} }
.product { .product {
@ -422,7 +499,7 @@ export default {
img { img {
width: 100%; width: 100%;
height: 140px; height: 140px;
transition: .3s; transition: 0.3s;
} }
.my-school { .my-school {
position: absolute; position: absolute;
@ -436,7 +513,7 @@ export default {
} }
.title { .title {
margin-bottom: 10px; margin-bottom: 10px;
color: #0B1D30; color: #0b1d30;
font-size: 14px; font-size: 14px;
font-weight: 600; font-weight: 600;
word-wrap: break-word; word-wrap: break-word;
@ -447,7 +524,7 @@ export default {
} }
.desc { .desc {
min-height: 34px; min-height: 34px;
color: #757F92; color: #757f92;
font-size: 12px; font-size: 12px;
display: -webkit-box; display: -webkit-box;
-webkit-box-orient: vertical; -webkit-box-orient: vertical;
@ -462,8 +539,8 @@ export default {
} }
.tag { .tag {
margin-right: 8px; margin-right: 8px;
color: #007EFF; color: #007eff;
background-color: #F9F9F9; background-color: #f9f9f9;
border: 0; border: 0;
} }
.type { .type {
@ -471,7 +548,7 @@ export default {
padding: 4px 11px; padding: 4px 11px;
font-size: 12px; font-size: 12px;
color: #666; color: #666;
border: 1px solid #DADADA; border: 1px solid #dadada;
border-radius: 20px; border-radius: 20px;
} }
.metas { .metas {
@ -483,7 +560,7 @@ export default {
.meta { .meta {
display: inline-flex; display: inline-flex;
align-items: center; align-items: center;
color: #B5BFD5; color: #b5bfd5;
font-size: 12px; font-size: 12px;
.icon { .icon {
width: 14px; width: 14px;
@ -492,7 +569,8 @@ export default {
} }
} }
&:hover { &:hover {
box-shadow: 0px 5px 12px 4px rgba(142, 123, 253, 0.09), 0px 3px 6px 0px rgba(142, 123, 253, 0.12), 0px 1px 2px -2px rgba(142, 123, 253, 0.16); box-shadow: 0px 5px 12px 4px rgba(142, 123, 253, 0.09), 0px 3px 6px 0px rgba(142, 123, 253, 0.12),
0px 1px 2px -2px rgba(142, 123, 253, 0.16);
img { img {
transform: scale(1.05); transform: scale(1.05);
} }
@ -503,7 +581,7 @@ export default {
.link-line { .link-line {
margin: 5px 0; margin: 5px 0;
.url { .url {
color: #007EFF; color: #007eff;
text-decoration: underline; text-decoration: underline;
} }
} }

@ -1,39 +1,53 @@
<template> <template>
<div ref="main" class="main"> <div ref="main"
class="main">
<el-form :disabled="isDetail"> <el-form :disabled="isDetail">
<el-card shadow="hover" class="m-b-20"> <el-card shadow="hover"
class="m-b-20">
<div class="flex-between"> <div class="flex-between">
<el-page-header @back="back" content="项目配置"></el-page-header> <el-page-header @back="back"
content="项目配置"></el-page-header>
<div v-if="!isDetail"> <div v-if="!isDetail">
<el-button type="success" @click="save(0)">保存为草稿</el-button> <el-button type="success"
<el-button type="primary" @click="save(1)">确定并发布</el-button> @click="save(0)">保存为草稿</el-button>
<el-button type="primary"
@click="save(1)">确定并发布</el-button>
</div> </div>
</div> </div>
</el-card> </el-card>
<el-card shadow="hover" class="m-b-20"> <el-card shadow="hover"
class="m-b-20">
<h6 class="p-title">基本信息</h6> <h6 class="p-title">基本信息</h6>
<div> <div>
<el-form label-width="80px" :disabled="isDetail"> <el-form label-width="80px"
:disabled="isDetail">
<div class="flex"> <div class="flex">
<el-form-item label="系统"> <el-form-item label="系统">
<el-select v-model="projectManage.systemId" placeholder="请选择" @change="systemChange"> <el-select v-model="projectManage.systemId"
<el-option placeholder="请选择"
v-for="item in systemList" @change="systemChange">
<el-option v-for="item in systemList"
:key="item.id" :key="item.id"
:label="item.label" :label="item.label"
:value="item.id" :value="item.id"></el-option>
></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="项目名称"> <el-form-item label="项目名称">
<el-input v-model.trim="projectManage.projectName" placeholder="20个字符以内" @blur="projectNameExistis"></el-input> <el-input v-model.trim="projectManage.projectName"
placeholder="20个字符以内"
@blur="projectNameExistis"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="项目权限"> <el-form-item label="项目权限">
<el-select v-model="projectManage.permissions" placeholder="请选择" @change="permissionChange"> <el-select v-model="projectManage.permissions"
<el-option label="练习" :value="0"></el-option> placeholder="请选择"
<el-option label="考核" :value="1"></el-option> @change="permissionChange">
<el-option label="竞赛" :value="2"></el-option> <el-option label="练习"
:value="0"></el-option>
<el-option label="考核"
:value="1"></el-option>
<el-option label="竞赛"
:value="2"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</div> </div>
@ -41,100 +55,158 @@
</div> </div>
</el-card> </el-card>
<el-card shadow="hover" class="m-b-20"> <el-card shadow="hover"
class="m-b-20">
<h6 class="p-title">实验目标</h6> <h6 class="p-title">实验目标</h6>
<div> <div>
<el-form label-width="0"> <el-form label-width="0">
<el-form-item> <el-form-item>
<quill :border="true" :readonly="isDetail" v-model="projectManage.experimentTarget" :minHeight="150" :height="150" /> <quill :border="true"
:readonly="isDetail"
v-model="projectManage.experimentTarget"
:minHeight="150"
:height="150" />
</el-form-item> </el-form-item>
</el-form> </el-form>
</div> </div>
</el-card> </el-card>
<el-card shadow="hover" class="m-b-20"> <el-card shadow="hover"
class="m-b-20">
<h6 class="p-title">项目背景</h6> <h6 class="p-title">项目背景</h6>
<div> <div>
<el-form label-width="0"> <el-form label-width="0">
<el-form-item> <el-form-item>
<quill :border="true" :readonly="isDetail" v-model="projectManage.experimentDescription" :minHeight="150" :height="150" :index="1" /> <quill :border="true"
:readonly="isDetail"
v-model="projectManage.experimentDescription"
:minHeight="150"
:height="150"
:index="1" />
</el-form-item> </el-form-item>
</el-form> </el-form>
</div> </div>
</el-card> </el-card>
<el-card shadow="hover" class="m-b-20"> <el-card shadow="hover"
class="m-b-20">
<div class="m-b-20 flex-between"> <div class="m-b-20 flex-between">
<h6 class="p-title" style="margin-bottom: 0">实验任务</h6> <h6 class="p-title"
style="margin-bottom: 0">实验任务</h6>
<div> <div>
<!--<el-button :disabled="isDetail" type="primary" @click="toJudgePoint('home')">进入判分点</el-button>--> <!--<el-button :disabled="isDetail" type="primary" @click="toJudgePoint('home')">进入判分点</el-button>-->
</div> </div>
</div> </div>
<div class="m-b-20 flex-between"> <div class="m-b-20 flex-between">
<div class="flex-center"> <div class="flex-center">
<div class="m-r-20" style="color: #f00">项目总分值100</div> <div class="m-r-20"
style="color: #f00">项目总分值100</div>
<!-- <div>权重&emsp;<div class="dib"><el-input></el-input></div></div> --> <!-- <div>权重&emsp;<div class="dib"><el-input></el-input></div></div> -->
</div> </div>
<div> <div>
<el-button class="m-r-20" type="text" @click="avgDistributionScore">平均分配分值</el-button> <el-button class="m-r-20"
<el-button class="m-r-20" type="text" @click="manualDistributionScore">手动分配分值</el-button> type="text"
@click="avgDistributionScore">平均分配分值</el-button>
<el-button class="m-r-20"
type="text"
@click="manualDistributionScore">手动分配分值</el-button>
<span>(待分配分值: {{ handDistributionScore }}/100)</span> <span>(待分配分值: {{ handDistributionScore }}/100)</span>
</div> </div>
</div> </div>
<el-button type="primary" icon="el-icon-plus" round @click="handleQueryJudgment" style="margin-bottom: 10px">判分点</el-button> <el-button type="primary"
<el-button type="primary" icon="el-icon-delete" round @click="batchDeleteProjectJudgment" style="margin-bottom: 10px">批量删除</el-button> icon="el-icon-plus"
round
@click="handleQueryJudgment"
style="margin-bottom: 10px">判分点</el-button>
<el-button type="primary"
icon="el-icon-delete"
round
@click="batchDeleteProjectJudgment"
style="margin-bottom: 10px">批量删除</el-button>
<div class="draggable"> <div class="draggable">
<el-table <el-table ref="projectJudgementTable"
ref="projectJudgementTable"
:data="projectJudgmentData" :data="projectJudgmentData"
class="table" class="table"
stripe stripe
header-align="center" header-align="center"
@selection-change="handleSelectionProjectJudgment" @selection-change="handleSelectionProjectJudgment"
row-key="judgmentId" row-key="judgmentId"
v-loading="listLoading" v-loading="listLoading">
> <el-table-column type="selection"
<el-table-column type="selection" width="55" align="center"></el-table-column> width="55"
<el-table-column prop="sort" label="序号" width="80" align="center"> align="center"></el-table-column>
<el-table-column prop="sort"
label="序号"
width="80"
align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.sort }} {{ scope.row.sort }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="name" label="判分指标" align="center"></el-table-column> <el-table-column prop="name"
<el-table-column prop="name" label="判分点名称" align="center"></el-table-column> label="判分指标"
<el-table-column label="实验要求" align="center" width="600"> align="center"></el-table-column>
<el-table-column prop="name"
label="判分点名称"
align="center"></el-table-column>
<el-table-column label="实验要求"
align="center"
width="600">
<template slot-scope="scope"> <template slot-scope="scope">
<quill :border="true" :readonly="true" elseRead="true" v-model="scope.row.experimentalRequirements" :minHeight="150" :height="150" :index="2" /> <quill :border="true"
:readonly="true"
elseRead="true"
v-model="scope.row.experimentalRequirements"
:minHeight="150"
:height="150"
:index="2" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="score" label="分数" align="center" width="120"> <el-table-column prop="score"
label="分数"
align="center"
width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<!--type="number" @blur="updateProjectJudgment"--> <!--type="number" @blur="updateProjectJudgment"-->
<el-input v-model.trim="scope.row.score" @input="scoreChange(scope.row, scope.$index,$event)"></el-input> <el-input v-model.trim="scope.row.score"
@input="scoreChange(scope.row, scope.$index,$event)"></el-input>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" width="100" align="center"> <el-table-column label="操作"
width="100"
align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<!--<el-button :disabled="isDetail" type="text" style="margin-right: 10px" @click="toJudgePoint('edit', scope.row)">自定义</el-button>--> <!--<el-button :disabled="isDetail" type="text" style="margin-right: 10px" @click="toJudgePoint('edit', scope.row)">自定义</el-button>-->
<el-button type="text" @click="delJudgePoint(scope.$index)">删除</el-button> <el-button type="text"
@click="delJudgePoint(scope.$index)">删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
</div> </div>
</el-card> </el-card>
<el-card shadow="hover" class="m-b-20"> <el-card shadow="hover"
class="m-b-20">
<div class="m-b-20 flex-between"> <div class="m-b-20 flex-between">
<h6 class="p-title" style="margin-bottom: 0">实验提示</h6> <h6 class="p-title"
style="margin-bottom: 0">实验提示</h6>
<div> <div>
启用 启用
<el-switch :active-value="0" :inactive-value="1" v-model="projectManage.hintOpen"></el-switch> <el-switch :active-value="0"
:inactive-value="1"
v-model="projectManage.hintOpen"></el-switch>
</div> </div>
</div> </div>
<div> <div>
<el-form label-width="0"> <el-form label-width="0">
<el-form-item prop="tips" label=""> <el-form-item prop="tips"
<quill :border="true" :readonly="isDetail" v-model="projectManage.experimentHint" :minHeight="150" :height="150" :index="3" /> label="">
<quill :border="true"
:readonly="isDetail"
v-model="projectManage.experimentHint"
:minHeight="150"
:height="150"
:index="3" />
</el-form-item> </el-form-item>
</el-form> </el-form>
</div> </div>
@ -142,14 +214,19 @@
</el-form> </el-form>
<!--选择判分点对话框--> <!--选择判分点对话框-->
<el-dialog title="添加判分点" :visible.sync="dialogVisible" width="40%" :close-on-click-modal="false"> <el-dialog title="添加判分点"
:visible.sync="dialogVisible"
width="40%"
:close-on-click-modal="false">
<div class="text-right m-b-10"> <div class="text-right m-b-10">
<div> <div>
<el-input placeholder="请输入需要查找的判分点" prefix-icon="el-icon-search" v-model.trim="judgementpointsquery" clearable></el-input> <el-input placeholder="请输入需要查找的判分点"
prefix-icon="el-icon-search"
v-model.trim="judgementpointsquery"
clearable></el-input>
</div> </div>
</div> </div>
<el-table <el-table v-loading="visibleLoading"
v-loading="visibleLoading"
:data="judgementData" :data="judgementData"
ref="judgementTable" ref="judgementTable"
class="table" class="table"
@ -157,24 +234,36 @@
header-align="center" header-align="center"
max-height="400" max-height="400"
@selection-change="handleSelectionJudgment" @selection-change="handleSelectionJudgment"
:row-key="rowKey" :row-key="rowKey">
> <el-table-column type="selection"
<el-table-column type="selection" width="55" align="center" :reserve-selection="true"></el-table-column> width="55"
<el-table-column prop="id" label="序号" align="center" width="100"> align="center"
:reserve-selection="true"></el-table-column>
<el-table-column prop="id"
label="序号"
align="center"
width="100">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.$index + 1 }} {{ scope.$index + 1 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="name" label="判分点名称" align="center"></el-table-column> <el-table-column prop="name"
<el-table-column label="操作" align="center" width="100"> label="判分点名称"
align="center"></el-table-column>
<el-table-column label="操作"
align="center"
width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button size="mini" @click="toJudgePoint('view', scope.row)">查看</el-button> <el-button size="mini"
@click="toJudgePoint('view', scope.row)">查看</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div slot="footer" class="dialog-footer"> <div slot="footer"
class="dialog-footer">
<el-button @click="dialogVisible = false"> </el-button> <el-button @click="dialogVisible = false"> </el-button>
<el-button type="primary" @click="addJudgment"> </el-button> <el-button type="primary"
@click="addJudgment"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
</div> </div>

@ -1,7 +1,10 @@
<template> <template>
<div> <div>
<el-card v-if="showBack" shadow="hover" class="m-b-20"> <el-card v-if="showBack"
<el-page-header content="实验项目管理" @back="goBack"></el-page-header> shadow="hover"
class="m-b-20">
<el-page-header content="实验项目管理"
@back="goBack"></el-page-header>
</el-card> </el-card>
<div class="page"> <div class="page">
<h6 class="p-title">筛选</h6> <h6 class="p-title">筛选</h6>
@ -9,41 +12,41 @@
<ul class="filter"> <ul class="filter">
<li> <li>
<label>创建人</label> <label>创建人</label>
<el-select v-model="queryData.founder" placeholder="请选择创建人" @change="founderChange"> <el-select v-model="queryData.founder"
<el-option placeholder="请选择创建人"
v-for="(item,index) in founderList" @change="founderChange">
<el-option v-for="(item,index) in founderList"
:key="index" :key="index"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"></el-option>
></el-option>
</el-select> </el-select>
</li> </li>
<li> <li>
<label>状态</label> <label>状态</label>
<el-select v-model="queryData.state" clearable placeholder="请选择状态" @change="initData"> <el-select v-model="queryData.state"
<el-option clearable
v-for="(item,index) in stateList" placeholder="请选择状态"
@change="initData">
<el-option v-for="(item,index) in stateList"
:key="index" :key="index"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"></el-option>
></el-option>
</el-select> </el-select>
</li> </li>
<li> <li>
<label>权限</label> <label>权限</label>
<el-select v-model="queryData.permissions" placeholder="请选择" @change="initData"> <el-select v-model="queryData.permissions"
<el-option placeholder="请选择"
v-for="item in permissionsList" @change="initData">
<el-option v-for="item in permissionsList"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"></el-option>
></el-option>
</el-select> </el-select>
</li> </li>
<li> <li>
<label>课程</label> <label>课程</label>
<el-cascader <el-cascader v-model="cid"
v-model="cid"
:options="curs" :options="curs"
:props="{ checkStrictly: true, value: 'id' }" :props="{ checkStrictly: true, value: 'id' }"
popper-class="course-cas" popper-class="course-cas"
@ -70,71 +73,121 @@
</el-select> </el-select>
</li> --> </li> -->
<li> <li>
<el-input placeholder="请输入项目名称" prefix-icon="el-icon-search" v-model="keyword" clearable></el-input> <el-input placeholder="请输入项目名称"
prefix-icon="el-icon-search"
v-model="keyword"
clearable></el-input>
</li> </li>
</ul> </ul>
<div> <div>
<el-button v-auth type="info" @click="add">新增项目</el-button> <el-button v-auth
<el-button v-auth type="primary" @click="delAllData">批量删除</el-button> type="info"
@click="add">新增项目</el-button>
<el-button v-auth
type="primary"
@click="delAllData">批量删除</el-button>
</div> </div>
</div> </div>
<el-table :data="listData" class="table" ref="table" stripe header-align="center" <el-table :data="listData"
class="table"
ref="table"
stripe
header-align="center"
@selection-change="handleSelectionChange"> @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" :selectable="disabledSelection"></el-table-column> <el-table-column type="selection"
<el-table-column type="index" width="100" label="序号" align="center"> width="55"
align="center"
:selectable="disabledSelection"></el-table-column>
<el-table-column type="index"
width="100"
label="序号"
align="center">
<template slot-scope="scope">{{ scope.$index + (page - 1) * pageSize + 1 }}</template> <template slot-scope="scope">{{ scope.$index + (page - 1) * pageSize + 1 }}</template>
</el-table-column> </el-table-column>
<el-table-column prop="projectName" label="实验项目名称" min-width="400" align="center" show-overflow-tooltip></el-table-column> <el-table-column prop="projectName"
<el-table-column prop="founder" label="创建人" min-width="150" align="center"> label="实验项目名称"
min-width="400"
align="center"
show-overflow-tooltip></el-table-column>
<el-table-column prop="founder"
label="创建人"
min-width="150"
align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ founderKeys[scope.row.founder] }} {{ founderKeys[scope.row.founder] }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="权限" min-width="120" align="center"> <el-table-column label="权限"
min-width="120"
align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ permissionsKeys[scope.row.permissions] }} {{ permissionsKeys[scope.row.permissions] }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="createTime" label="创建时间" min-width="150" align="center"></el-table-column> <el-table-column prop="createTime"
<el-table-column prop="status" label="状态" min-width="100" align="center"> label="创建时间"
min-width="150"
align="center"></el-table-column>
<el-table-column prop="status"
label="状态"
min-width="100"
align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ stateKeys[scope.row.state] }} {{ stateKeys[scope.row.state] }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" width="300" align="center"> <el-table-column label="操作"
width="300"
align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="edit(scope.row, 1)">查看</el-button> <el-button type="text"
<el-button v-if="scope.row.founder && (roleName.includes('超级') || roleName === scope.row.roleName || (roleName === '管理员' && !scope.row.roleName.includes('超级')))" type="text" @click="edit(scope.row)">编辑</el-button> @click="edit(scope.row, 1)">查看</el-button>
<el-button v-if="scope.row.founder && (roleName.includes('超级') || roleName === scope.row.roleName || (roleName === '管理员' && !scope.row.roleName.includes('超级')))" type="text" @click="handleDelete(scope.row.projectId)">删除</el-button> <el-button v-if="scope.row.founder && (roleName.includes('超级') || roleName === scope.row.roleName || (roleName === '管理员' && !scope.row.roleName.includes('超级')))"
<el-button v-auth type="text" @click="copyData(scope.row.projectId)">复制</el-button> type="text"
<el-switch @click="edit(scope.row)">编辑</el-button>
v-auth="'禁用'" <el-button v-if="scope.row.founder && (roleName.includes('超级') || roleName === scope.row.roleName || (roleName === '管理员' && !scope.row.roleName.includes('超级')))"
type="text"
@click="handleDelete(scope.row.projectId)">删除</el-button>
<el-button v-auth
type="text"
@click="copyData(scope.row.projectId)">复制</el-button>
<el-switch v-auth="'禁用'"
v-if="scope.row.state" v-if="scope.row.state"
v-model="scope.row.ccupationlabOpen" v-model="scope.row.ccupationlabOpen"
:active-text="scope.row.ccupationlabOpen ? '关闭' : '启用'" :active-text="scope.row.ccupationlabOpen ? '关闭' : '启用'"
:active-value="0" :active-value="0"
:inactive-value="1" :inactive-value="1"
style="margin: 0 10px 0 10px" style="margin: 0 10px 0 10px"
@change="switchOff(scope.row)" @change="switchOff(scope.row)"></el-switch>
></el-switch>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="pagination"> <div class="pagination">
<el-pagination background @current-change="handleCurrentChange" :current-page="page" layout="total, prev, pager, next" :total="total"></el-pagination> <el-pagination background
@current-change="handleCurrentChange"
:current-page="page"
layout="total, prev, pager, next"
:total="total"></el-pagination>
</div> </div>
<el-dialog title="复制" :visible.sync="copyVisible" width="24%" center :close-on-click-modal="false"> <el-dialog title="复制"
:visible.sync="copyVisible"
width="24%"
center
:close-on-click-modal="false">
<el-form> <el-form>
<el-form-item> <el-form-item>
<!--前端不用做名称判重了@change='projectNameExistis'--> <!--前端不用做名称判重了@change='projectNameExistis'-->
<el-input placeholder="请输入项目名称" v-model="projectName"></el-input> <el-input placeholder="请输入项目名称"
v-model="projectName"></el-input>
</el-form-item> </el-form-item>
</el-form> </el-form>
<span slot="footer" class="dialog-footer"> <span slot="footer"
class="dialog-footer">
<el-button @click="copyVisible = false"> </el-button> <el-button @click="copyVisible = false"> </el-button>
<el-button type="primary" @click="copySubmit"> </el-button> <el-button type="primary"
@click="copySubmit"> </el-button>
</span> </span>
</el-dialog> </el-dialog>
</div> </div>
@ -452,5 +505,4 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
</style> </style>

@ -3,21 +3,34 @@
<div class="wrap"> <div class="wrap">
<div class="search"> <div class="search">
<h6>创新实验智能教学</h6> <h6>创新实验智能教学</h6>
<div class="input" v-auth="'搜索'"> <div class="input"
<img src="@/assets/img/search.png" alt=""> v-auth="'搜索'">
<input type="text" placeholder="请输入关键词" v-model="keyword"> <img src="@/assets/img/search.png"
alt="">
<input type="text"
placeholder="请输入关键词"
v-model="keyword">
</div> </div>
</div> </div>
<div class="station"> <div class="station">
<div class="inner"> <div class="inner">
<div class="tab"> <div class="tab">
<a class="item" v-for="(item, i) in tabs" :key="i" :class="{active: item.id == active}" @click="tabChange(item)">{{ item.name }}</a> <a class="item"
v-for="(item, i) in tabs"
:key="i"
:class="{active: item.id == active}"
@click="tabChange(item)">{{ item.name }}</a>
</div> </div>
<div class="curs"> <div class="curs">
<template v-if="curriculumList.length"> <template v-if="curriculumList.length">
<template v-for="(item,index) in curriculumList"> <template v-for="(item,index) in curriculumList">
<div class="item" :title="item.curriculumName" @click="goPreview(item)" :key="index" v-if="!keyword || item.curriculumName.includes(keyword)"> <div class="item"
<img :src="item.coverUrl" alt=""> :title="item.curriculumName"
@click="goPreview(item)"
:key="index"
v-if="!keyword || item.curriculumName.includes(keyword)">
<img :src="item.coverUrl"
alt="">
<div class="bottom"> <div class="bottom">
<p class="text"><span>{{ item.goodsName || item.curriculumName }}</span></p> <p class="text"><span>{{ item.goodsName || item.curriculumName }}</span></p>
<a>进入实验</a> <a>进入实验</a>
@ -25,9 +38,11 @@
</div> </div>
</template> </template>
</template> </template>
<div class="empty flex-1" v-else> <div class="empty flex-1"
v-else>
<div> <div>
<img src="@/assets/img/none.png" alt=""> <img src="@/assets/img/none.png"
alt="">
<p>暂无数据</p> <p>暂无数据</p>
</div> </div>
</div> </div>
@ -76,7 +91,7 @@ export default {
}); });
}, },
goPreview (item) { goPreview (item) {
this.$router.push(`/station/preview?courseId=${item.cid}&curriculumName=${item.curriculumName}&mallId=${item.mallId || ''}`); this.$router.push(`/station/preview?courseId=${item.cid}&curriculumName=${item.curriculumName}&mallId=${item.mallId || ''}&admin=1`);
}, },
// tab // tab
tabChange (item) { tabChange (item) {
@ -138,8 +153,8 @@ export default {
border-bottom: 3px solid transparent; border-bottom: 3px solid transparent;
cursor: pointer; cursor: pointer;
&.active { &.active {
color: #007EFF; color: #007eff;
border-color: #007EFF; border-color: #007eff;
} }
} }
} }
@ -166,7 +181,7 @@ export default {
border-radius: 8px; border-radius: 8px;
cursor: pointer; cursor: pointer;
&:hover { &:hover {
opacity: .9; opacity: 0.9;
} }
img { img {
width: 215px; width: 215px;
@ -197,9 +212,9 @@ export default {
padding: 0 8px; padding: 0 8px;
line-height: 28px; line-height: 28px;
font-size: 14px; font-size: 14px;
color: #7A7A7A; color: #7a7a7a;
border-radius: 20px; border-radius: 20px;
border: 1px solid #DADADA; border: 1px solid #dadada;
} }
} }
} }

@ -1,42 +1,63 @@
<template> <template>
<div style="padding: 24px"> <div style="padding: 24px">
<el-card shadow="hover" class="m-b-20"> <el-card shadow="hover"
class="m-b-20">
<div class="flex-between"> <div class="flex-between">
<el-page-header @back="goBack" :content="curriculumName"></el-page-header> <el-page-header @back="goBack"
:content="curriculumName"></el-page-header>
</div> </div>
</el-card> </el-card>
<el-card shadow="hover" class="m-b-20" style="background: none;"> <el-card shadow="hover"
class="m-b-20"
style="background: none;">
<div class="flex"> <div class="flex">
<div class="cover" :class="{'is-word': showMask1}"> <div class="cover"
:class="{'is-word': showMask1}">
<!--实验台不显示课程封面--> <!--实验台不显示课程封面-->
<img v-if="coverUrl" :src="coverUrl" alt="" width="100%" height="100%"> <img v-if="coverUrl"
:src="coverUrl"
alt=""
width="100%"
height="100%">
<template v-else-if="iframeSrc"> <template v-else-if="iframeSrc">
<iframe class="inner fileIframe" id="fileIframe" :src="iframeSrc" frameborder="0"></iframe> <iframe class="inner fileIframe"
id="fileIframe"
:src="iframeSrc"
frameborder="0"></iframe>
<template v-if="showMask"> <template v-if="showMask">
<div class="mask" style="width:100%;background: #393A3D;height: 30px;top: 53px;"></div> <div class="mask"
<div class="mask" style="width:100%;background: #393A3D;height: 30px;top: 53px;"></div> style="width:100%;background: #393A3D;height: 30px;top: 53px;"></div>
<div class="mask"
style="width:100%;background: #393A3D;height: 30px;top: 53px;"></div>
</template> </template>
<template v-if="showMask1"> <template v-if="showMask1">
<div class="word-mask" style="height: 40px;"></div> <div class="word-mask"
style="height: 40px;"></div>
<div class="word-mask2" <div class="word-mask2"
style="top: 55px;left: 28%;width: 44%;height: calc(100% - 80px);"></div> style="top: 55px;left: 28%;width: 44%;height: calc(100% - 80px);"></div>
</template> </template>
<template v-if="showMask2"> <template v-if="showMask2">
<div class="excel-mask1" style="height: 48px;"></div> <div class="excel-mask1"
style="height: 48px;"></div>
</template> </template>
</template> </template>
<div class="pdf inner" v-else-if="pdfSrc"> <div class="pdf inner"
<img class="full" src="@/assets/img/screen/full.png" alt="" @click="fullScreen"> v-else-if="pdfSrc">
<img class="full"
src="@/assets/img/screen/full.png"
alt=""
@click="fullScreen">
<p class="arrow"> <p class="arrow">
<span @click="changePdfPage(0)" class="turn el-icon-arrow-left" <span @click="changePdfPage(0)"
class="turn el-icon-arrow-left"
:class="{grey: currentPage==1}"></span> :class="{grey: currentPage==1}"></span>
{{ currentPage }} / {{ pageCount }} {{ currentPage }} / {{ pageCount }}
<span @click="changePdfPage(1)" class="turn el-icon-arrow-right" <span @click="changePdfPage(1)"
class="turn el-icon-arrow-right"
:class="{grey: currentPage==pageCount}"></span> :class="{grey: currentPage==pageCount}"></span>
</p> </p>
<div style='color:#393A3D;height: 30px;background: #393A3D;'></div> <div style='color:#393A3D;height: 30px;background: #393A3D;'></div>
<pdf <pdf class="pdf-wrap"
class="pdf-wrap"
:src="pdfSrc" :src="pdfSrc"
:page="currentPage" :page="currentPage"
@num-pages="pageCount=$event" @num-pages="pageCount=$event"
@ -44,47 +65,73 @@
@loaded="loadPdfHandler"> @loaded="loadPdfHandler">
</pdf> </pdf>
</div> </div>
<div class="inner" v-else-if="playAuth"> <div class="inner"
<div class="video_wid" id="player"></div> v-else-if="playAuth">
<div class="video_wid"
id="player"></div>
</div> </div>
</div> </div>
<div class="catalog"> <div class="catalog">
<div class="m-b-20"> <div class="m-b-20">
<el-button v-if="!overdue" class="entry" type="primary" size="small" @click="showBuy">续费</el-button> <el-button v-if="!overdue"
<el-button v-else class="entry" type="primary" @click="entry"> </el-button> class="entry"
type="primary"
size="small"
@click="showBuy">续费</el-button>
<el-button v-else
class="entry"
type="primary"
@click="entry"> </el-button>
</div> </div>
<div class="list"> <div class="list">
<h4 class="title">{{ courseName }}</h4> <h4 class="title">{{ courseName }}</h4>
<div> <div>
<h6 class="pro-title">当前教学进度</h6> <h6 class="pro-title">当前教学进度</h6>
<el-progress :stroke-width="12" :percentage="schedule" :format="percentFormat" :text-color="'#fff'"></el-progress> <el-progress :stroke-width="12"
:percentage="schedule"
:format="percentFormat"
:text-color="'#fff'"></el-progress>
</div> </div>
<div class="types"> <div class="types">
<div :class="['item', { active: type === 1 }]" @click="typeChange(1)"> <div :class="['item', { active: type === 1 }]"
@click="typeChange(1)">
<i class="icon el-icon-notebook-2"></i> 目录 <i class="icon el-icon-notebook-2"></i> 目录
</div> </div>
<div :class="['item', { active: type === 2 }]" @click="typeChange(2)"> <div :class="['item', { active: type === 2 }]"
@click="typeChange(2)">
<i class="icon el-icon-timer"></i> 教学进度 <i class="icon el-icon-timer"></i> 教学进度
</div> </div>
</div> </div>
<div class="chapters"> <div class="chapters">
<template v-if="type === 1"> <template v-if="type === 1">
<template v-if="chapterList.length"> <template v-if="chapterList.length">
<div class="chapter" v-for="(item,index) in chapterList" :key="index"> <div class="chapter"
v-for="(item,index) in chapterList"
:key="index">
<div class="chapterName">{{ item.name }}</div> <div class="chapterName">{{ item.name }}</div>
<div class="section" v-if="item.subsectionList.length"> <div class="section"
<div v-for="(section,i) in item.subsectionList" :key="i" @click="preview(section, item.name)"> v-if="item.subsectionList.length">
<p class="sectionName" :title="section.name" :class="{active: curLink === `${item.name}${section.name}`}">{{ section.name }}</p> <div v-for="(section,i) in item.subsectionList"
:key="i"
@click="preview(section, item.name)">
<p class="sectionName"
:title="section.name"
:class="{active: curLink === `${item.name}${section.name}`}">{{ section.name }}</p>
</div> </div>
</div> </div>
</div> </div>
</template> </template>
</template> </template>
<div v-else class="section"> <div v-else
<p class="sectionName" v-for="(item, i) in progressList" :key="i" :title="item.projectName"> class="section">
<p class="sectionName"
v-for="(item, i) in progressList"
:key="i"
:title="item.projectName">
{{ i + 1 }}. {{ i + 1 }}.
{{ item.projectName }} {{ item.projectName }}
<i :class="['icon', item.whetherToStudyOrNot ? 'el-icon-success' : 'circle']" @click.stop="studySection(item)"></i> <i :class="['icon', item.whetherToStudyOrNot ? 'el-icon-success' : 'circle']"
@click.stop="studySection(item)"></i>
</p> </p>
</div> </div>
</div> </div>
@ -93,35 +140,44 @@
</div> </div>
</el-card> </el-card>
<div class="tabs"> <div class="tabs">
<a class="item" v-for="(item, i) in tabs" :key="i" :class="{active: item.id == active}" @click="tabChange(item)">{{ item.name }}</a> <a class="item"
v-for="(item, i) in tabs"
:key="i"
:class="{active: item.id == active}"
@click="tabChange(item)">{{ item.name }}</a>
</div> </div>
<div class="tab-content"> <div class="tab-content">
<template v-if="active === 1"> <template v-if="active === 1">
<el-card shadow="hover" class="m-t-20 m-b-20"> <el-card shadow="hover"
<h4 style="margin-bottom: 10px;font-size: 16px;">课程简介</h4> class="m-t-20 m-b-20">
<div v-html="briefIntroduction"></div> <div v-html="briefIntroduction"></div>
</el-card> </el-card>
<el-card shadow="hover" class="m-b-20">
<h4 style="margin-bottom: 10px;font-size: 16px;">课程目标</h4>
<div v-html="teachingObjectives"></div>
</el-card>
</template> </template>
<template v-if="active === 2"> <template v-if="active === 2">
<div class="page"> <div class="page">
<template v-if="showNoteAdd"> <template v-if="showNoteAdd">
<el-form class="form" ref="form" label-width="120px" center> <el-form class="form"
<el-form-item class="required" label="笔记标题"> ref="form"
<el-input placeholder="请输入笔记标题" v-model="noteForm.noteName" maxlength="30" style="width: 400px"></el-input> label-width="120px"
center>
<el-form-item class="required"
label="笔记标题">
<el-input placeholder="请输入笔记标题"
v-model="noteForm.noteName"
maxlength="30"
style="width: 400px"></el-input>
</el-form-item> </el-form-item>
<el-form-item class="required" label="笔记内容"> <el-form-item class="required"
<Editor api-key='rnk6zw9v267xqz7pf98twt1vmrvltmd436je7a642pckltda' v-model="noteForm.noteContent" :init="editorConfig" /> label="笔记内容">
<Editor api-key='rnk6zw9v267xqz7pf98twt1vmrvltmd436je7a642pckltda'
v-model="noteForm.noteContent"
:init="editorConfig" />
</el-form-item> </el-form-item>
</el-form> </el-form>
<div class="text-right"> <div class="text-right">
<el-button type="primary" @click="submitNote">保存</el-button> <el-button type="primary"
@click="submitNote">保存</el-button>
</div> </div>
</template> </template>
<template v-else> <template v-else>
@ -129,26 +185,34 @@
<ul class="filter"> <ul class="filter">
<li> <li>
<label>搜索</label> <label>搜索</label>
<el-input placeholder="请输入标题" v-model="noteKeyword" clearable></el-input> <el-input placeholder="请输入标题"
v-model="noteKeyword"
clearable></el-input>
</li> </li>
</ul> </ul>
<div> <div>
<el-button type="primary" @click="addNote">新增笔记</el-button> <el-button type="primary"
@click="addNote">新增笔记</el-button>
</div> </div>
</div> </div>
<el-timeline class="timeline"> <el-timeline class="timeline">
<el-timeline-item placement="top" v-for="(item, i) in notes" :key="i"> <el-timeline-item placement="top"
v-for="(item, i) in notes"
:key="i">
<p class="sign">{{ item.createTime }}</p> <p class="sign">{{ item.createTime }}</p>
<div class="ver"> <div class="ver">
<div> <div>
{{ item.noteName }} {{ item.noteName }}
<span class="action"> <span class="action">
<i class="el-icon-edit-outline" @click="editNote(item)"></i> <i class="el-icon-edit-outline"
<i class="el-icon-delete" @click="delNote(item)"></i> @click="editNote(item)"></i>
<i class="el-icon-delete"
@click="delNote(item)"></i>
</span> </span>
</div> </div>
</div> </div>
<div class="des" v-html="item.noteContent"></div> <div class="des"
v-html="item.noteContent"></div>
</el-timeline-item> </el-timeline-item>
</el-timeline> </el-timeline>
</template> </template>
@ -156,84 +220,131 @@
</template> </template>
<template v-if="active === 4"> <template v-if="active === 4">
<div class="page"> <div class="page">
<quill ref="quill" :border="true" v-model="msg" :height="150" :toTop="false" /> <quill ref="quill"
:border="true"
v-model="msg"
:height="150"
:toTop="false" />
<ul class="msg"> <ul class="msg">
<li v-for="(item, i) in msgs" :key="i"> <li v-for="(item, i) in msgs"
:key="i">
<div class="li-wrap"> <div class="li-wrap">
<img :src="item.avatar" alt="" class="avatar"> <img :src="item.avatar"
alt=""
class="avatar">
<div class="texts"> <div class="texts">
<h6> <h6>
<span class="name">{{ item.userName }}</span> <span class="name">{{ item.userName }}</span>
发表于 {{ item.createDate }} 发表于 {{ item.createDate }}
</h6> </h6>
<div class="des" v-html="item.content"></div> <div class="des"
v-html="item.content"></div>
</div> </div>
<div class="action"> <div class="action">
<i class="icon el-icon-chat-dot-square"></i> <i class="icon el-icon-chat-dot-square"></i>
<i class="icon el-icon-delete"></i> <i class="icon el-icon-delete"></i>
<img class="icon" src="@/assets/img/like.png" alt=""> <img class="icon"
src="@/assets/img/like.png"
alt="">
</div> </div>
</div> </div>
<div class="reply" v-if="item.showReply"> <div class="reply"
<quill :border="true" v-model="item.replyContent" :toTop="false" :height="150" /> v-if="item.showReply">
<quill :border="true"
v-model="item.replyContent"
:toTop="false"
:height="150" />
<div class="m-t-10 text-right"> <div class="m-t-10 text-right">
<el-button type="primary" size="mini">提交</el-button> <el-button type="primary"
size="mini">提交</el-button>
</div> </div>
</div> </div>
<ul class="msg children" v-if="item.showChildren"> <ul class="msg children"
<li v-for="(reply,i) in item.children" :key="i"> v-if="item.showChildren">
<li v-for="(reply,i) in item.children"
:key="i">
<div class="li-wrap"> <div class="li-wrap">
<img class="avatar" :src="reply.avatar" alt=""> <img class="avatar"
:src="reply.avatar"
alt="">
<div class="texts"> <div class="texts">
<div class="name">{{reply.userName}}</div> <div class="name">{{reply.userName}}</div>
<div class="des" v-html="reply.content"></div> <div class="des"
v-html="reply.content"></div>
<div class="date">{{reply.createDate}}</div> <div class="date">{{reply.createDate}}</div>
</div> </div>
<div class="action"> <div class="action">
<i class="icon el-icon-chat-dot-square"></i> <i class="icon el-icon-chat-dot-square"></i>
<i class="icon el-icon-delete"></i> <i class="icon el-icon-delete"></i>
<img class="icon" src="@/assets/img/like.png" alt=""> <img class="icon"
src="@/assets/img/like.png"
alt="">
</div> </div>
</div> </div>
<div class="reply" v-if="reply.showReply"> <div class="reply"
<quill :border="true" v-model="reply.replyContent" :toTop="false" :height="150" /> v-if="reply.showReply">
<quill :border="true"
v-model="reply.replyContent"
:toTop="false"
:height="150" />
<div class="m-t-10 text-right"> <div class="m-t-10 text-right">
<el-button type="primary" size="mini">提交</el-button> <el-button type="primary"
size="mini">提交</el-button>
</div> </div>
</div> </div>
</li> </li>
</ul> </ul>
<div v-if="item.getCommentReplyNum" class="toggle"><span @click="item.showChildren = !item.showChildren">{{item.showChildren ? '收起所有回复' : `查看所有${item.getCommentReplyNum}条回复`}} <i class="el-icon-arrow-down"></i></span></div> <div v-if="item.getCommentReplyNum"
class="toggle"><span @click="item.showChildren = !item.showChildren">{{item.showChildren ? '收起所有回复' : `查看所有${item.getCommentReplyNum}条回复`}} <i class="el-icon-arrow-down"></i></span></div>
</li> </li>
</ul> </ul>
</div> </div>
</template> </template>
</div> </div>
<el-dialog title="请选择项目"
<el-dialog title="请选择项目" v-loading="loading" :visible.sync="projectVisible" width="828px" custom-class="project-dia" :close-on-click-modal="false"> v-loading="loading"
:visible.sync="projectVisible"
width="828px"
custom-class="project-dia"
:close-on-click-modal="false">
<ul class="projects"> <ul class="projects">
<li v-for="(item, i) in projects" :key="i" :class="{active: curProject == item.projectId}" @click="selectProject(item)"> <li v-for="(item, i) in projects"
<img src="@/assets/img/project.png" alt=""> :key="i"
:class="{active: curProject == item.projectId}"
@click="selectProject(item)">
<img src="@/assets/img/project.png"
alt="">
<span>{{ i + 1 }}. {{ item.projectName }}</span> <span>{{ i + 1 }}. {{ item.projectName }}</span>
</li> </li>
</ul> </ul>
<span slot="footer" class="dialog-footer"> <span slot="footer"
<el-button size="small" @click="projectVisible = false"> </el-button> class="dialog-footer">
<el-button size="small" type="primary" @click="toSub"> </el-button> <el-button size="small"
@click="projectVisible = false"> </el-button>
<el-button size="small"
type="primary"
@click="toSub"> </el-button>
</span> </span>
</el-dialog> </el-dialog>
<!-- 购买弹框 --> <!-- 购买弹框 -->
<el-dialog title="温馨提示" :visible.sync="buyVisible" width="420px" center :close-on-click-modal="false"> <el-dialog title="温馨提示"
:visible.sync="buyVisible"
width="420px"
center
:close-on-click-modal="false">
<div class="buy"> <div class="buy">
<p class="tips">该课程订阅期限已到期若需要续费请扫码添加客服咨询</p> <p class="tips">该课程订阅期限已到期若需要续费请扫码添加客服咨询</p>
<img src="@/assets/img/wechat-code.jpeg" alt=""> <img src="@/assets/img/wechat-code.jpeg"
alt="">
</div> </div>
</el-dialog> </el-dialog>
<pdfDia :key="pdfVisible" :visible.sync="pdfVisible" :src.sync="pdfSrc"/> <pdfDia :key="pdfVisible"
:visible.sync="pdfVisible"
:src.sync="pdfSrc" />
</div> </div>
</template> </template>
@ -252,10 +363,11 @@ export default {
return { return {
editorConfig, editorConfig,
courseId: this.$route.query.courseId, courseId: this.$route.query.courseId,
mallId: this.$route.query.mallId, mallId: this.$route.query.mallId || '',
curriculumName: this.$route.query.curriculumName, curriculumName: this.$route.query.curriculumName,
chapter: this.$route.query.chapter, chapter: this.$route.query.chapter,
section: this.$route.query.section, section: this.$route.query.section,
fromAdmin: this.$route.query.admin, // or
type: 1, type: 1,
video: "http://liuwanr.oss-cn-shenzhen.aliyuncs.com/mp4/20200519/1589871025648.mp4", video: "http://liuwanr.oss-cn-shenzhen.aliyuncs.com/mp4/20200519/1589871025648.mp4",
chapterList: [], // chapterList: [], //
@ -367,7 +479,9 @@ export default {
}, },
methods: { methods: {
goBack () { goBack () {
this.$router.back() this.fromAdmin ?
this.$router.back() :
this.$router.push('/station')
}, },
async getData () { async getData () {
let { data } = await this.$post(`${this.api.curriculumDetail}?cid=${this.courseId}&mallId=${this.mallId}`); let { data } = await this.$post(`${this.api.curriculumDetail}?cid=${this.courseId}&mallId=${this.mallId}`);
@ -671,6 +785,7 @@ export default {
util.cookies.set('stopTime', '', -1) util.cookies.set('stopTime', '', -1)
projectId ? util.cookies.set('projectId', projectId) : util.cookies.set('projectId', '', -1) projectId ? util.cookies.set('projectId', projectId) : util.cookies.set('projectId', '', -1)
util.cookies.set('token', token) util.cookies.set('token', token)
util.cookies.set('mallId', this.mallId)
util.cookies.set('courseId', this.courseId) util.cookies.set('courseId', this.courseId)
util.cookies.set('curriculumName', escape(this.curriculumName)) util.cookies.set('curriculumName', escape(this.curriculumName))
util.cookies.set('systemId', id) util.cookies.set('systemId', id)
@ -709,7 +824,7 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
@import "../../../styles/page/station.scss"; @import '../../../styles/page/station.scss';
$height: 700px; $height: 700px;
.page { .page {
margin: 12px 0; margin: 12px 0;
@ -719,7 +834,8 @@ $height: 700px;
line-height: 24px; line-height: 24px;
} }
} }
.video_wid,.cover{ .video_wid,
.cover {
position: relative; position: relative;
width: 76%; width: 76%;
height: $height !important; height: $height !important;
@ -773,7 +889,8 @@ $height: 700px;
.fileIframe { .fileIframe {
height: $height !important; height: $height !important;
} }
.video_wid,.inner{ .video_wid,
.inner {
width: 100%; width: 100%;
height: 100% !important; height: 100% !important;
border: 0; border: 0;
@ -873,7 +990,7 @@ $height: 700px;
cursor: pointer; cursor: pointer;
@include ellipsis; @include ellipsis;
&.active { &.active {
color: #9278FF; color: #9278ff;
} }
.icon { .icon {
position: absolute; position: absolute;
@ -901,10 +1018,10 @@ $height: 700px;
} }
.el-image-viewer__wrapper { .el-image-viewer__wrapper {
transform: translateY(-10px); transform: translateY(-10px);
transition: transform .5s; transition: transform 0.5s;
&.active { &.active {
transform: translateY(0) transform: translateY(0);
} }
} }
.el-image-viewer__close { .el-image-viewer__close {
@ -1023,12 +1140,12 @@ $height: 700px;
width: 238px; width: 238px;
padding: 16px; padding: 16px;
margin: 0 20px 20px 0; margin: 0 20px 20px 0;
background-color: #F6F8FA; background-color: #f6f8fa;
border-radius: 16px; border-radius: 16px;
cursor: pointer; cursor: pointer;
&:hover { &:hover {
span { span {
color: #007EFF; color: #007eff;
} }
} }
&:nth-child(3n) { &:nth-child(3n) {

Loading…
Cancel
Save