dev_202412
yujialong 2 months ago
parent 2de12c8ec0
commit 878645d672
  1. 189
      src/assets/css/station.scss
  2. BIN
      src/assets/img/full.png
  3. BIN
      src/assets/img/project.png
  4. BIN
      src/assets/img/wechat-code.jpeg
  5. 4
      src/router/index.js
  6. 18
      src/utils/api.js
  7. 23
      src/views/course/content/source.vue
  8. 11
      src/views/course/detail.vue
  9. 12
      src/views/course/list.vue
  10. 26
      src/views/order/Order.vue
  11. 57
      src/views/resourse/index.vue
  12. 25
      src/views/serve/projectList.vue
  13. 133
      src/views/shop/add.vue
  14. 1429
      src/views/station/index.vue

@ -0,0 +1,189 @@
.msg {
li {
margin-bottom: 10px;
border-top: 1px solid #f1f1f1;
&:first-child {
border-top: 0;
}
.li-wrap {
position: relative;
display: flex;
justify-content: space-between;
padding: 16px 0;
.avatar {
width: 48px;
height: 48px;
border-radius: 50%;
}
.texts {
flex: 1;
margin-left: 24px;
.name {
color: rgba(0, 0, 0, 0.85);
font-size: 16px;
}
.date {
color: rgba(0, 0, 0, 0.45);
font-size: 14px;
}
/deep/img {
max-width: 95%;
}
}
.reply-name {
color: #062c87;
}
.action {
display: inline-flex;
align-items: center;
margin: 15px 10px 0 0;
.icon {
margin: 0 5px;
color: #062c87;
font-size: 18px;
cursor: pointer;
&:hover {
opacity: 0.8;
}
&:first-child {
margin-right: 5px;
}
&.del {
color: rgba(0, 0, 0, 0.65);
border: 1px solid rgba(0, 0, 0, 0.15);
}
}
}
.like-wrap {
display: inline-flex;
align-items: center;
cursor: pointer;
}
}
.reply {
margin-top: 20px;
}
}
&.children {
margin-left: 72px;
padding-left: 24px;
background-color: rgba(0, 0, 0, 0.02);
border-radius: 8px;
li {
border-top-color: rgba(0, 0, 0, 0.06);
}
}
}
.toggle {
margin: 16px 0;
text-align: center;
color: #062c87;
font-size: 14px;
span {
cursor: pointer;
}
}
/deep/.quill {
background-color: #fff;
}
/deep/.timeline {
padding-left: 9%;
overflow: hidden;
.el-timeline-item {
padding-bottom: 40px;
}
.el-timeline-item__node--normal {
top: 30px;
}
.el-timeline-item__wrapper {
top: 15px;
padding-left: 40px;
}
.el-timeline-item__tail {
height: 250%;
border-left-width: 1px;
}
.sign {
position: relative;
display: inline-block;
margin-left: -12.5%;
font-size: 14px;
color: #062c87;
}
.draft {
.ver,
.sign {
color: #b1b1b1;
}
}
.ver {
display: flex;
justify-content: space-between;
align-items: center;
padding-bottom: 10px;
margin: -22px 0 20px;
font-size: 15px;
color: #062c87;
border-bottom: 1px dashed #bfbfbf;
}
.des {
p,
span,
em {
font-size: 14px !important;
}
}
.withdraw {
margin-right: 10px;
font-size: 13px;
color: #979797;
}
.action {
margin-left: 15px;
i {
margin-left: 8px;
font-size: 14px;
color: #062c87;
cursor: pointer;
&:hover {
opacity: 0.9;
}
}
}
.detail {
li {
margin-bottom: 20px;
}
.name {
display: flex;
align-items: center;
margin-bottom: 5px;
font-size: 15px;
font-weight: 600;
img {
width: 20px;
margin-right: 5px;
}
}
.val {
font-size: 14px;
line-height: 1.8;
white-space: pre-wrap;
p {
position: relative;
color: #6a6a6a;
&:before {
content: '';
display: inline-block;
width: 5px;
height: 5px;
margin: 0 10px 0 5px;
vertical-align: middle;
border-radius: 20px;
background-color: #c5b8ff;
}
}
}
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 205 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 343 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

@ -231,6 +231,10 @@ let router = new Router({
path: '/resourse',
component: () => import('../views/resourse'),
},
{
path: '/station',
component: () => import('../views/station'),
},
{
path: '/404',
component: () => import('../views/404.vue'),

@ -168,6 +168,24 @@ export default {
deleteCoursePrompt: `nakadai/nakadai/curriculum/deleteCoursePrompt`,
combinationResource: `nakadai/nakadai/curriculum/combinationResource`,
replaceResource: `nakadai/nakadai/curriculum/subsection/replaceResource`,
curriculumChapter: `nakadai/nakadai/curriculum/chapter/queryChaptersAndSubsections`,
courseLearningProgress: 'nakadai/nakadai/curriculum/learning/progressprogress/courseLearningProgress',
deleteLearningProgress: 'nakadai/nakadai/curriculum/learning/progressprogress/delete',
curriculumGetSubsection: `nakadai/nakadai/curriculum/subsection/getSubsection`,
// 课程笔记
addNote: `nakadai/curriculumNotes/addNote`,
curriculumNoteList: `nakadai/curriculumNotes/curriculumNoteList`,
deleteNotes: `nakadai/curriculumNotes/deleteNotes`,
updateNote: `nakadai/curriculumNotes/updateNote`,
// 教学互动
addCommentStation: `nakadai/comment/addComment`,
commentTreeList: `nakadai/comment/commentTreeList`,
deleteAComment: `nakadai/comment/deleteAComment`,
commentAndLike: `nakadai/commentLike/commentAndLike`,
unlike: `nakadai/commentLike/unlike`,
messageNotificationList: `nakadai/notify/messageNotificationList`,
noticeRead: `nakadai/notify/noticeRead`,
// 课程章节管理
addChapter: `nakadai/nakadai/curriculum/chapter/addChapter`, //添加章节
editChapter: `nakadai/nakadai/curriculum/chapter/editChapter`, //修改章节

@ -185,6 +185,7 @@ export default {
try {
this.loading = true
this.checkAll = false
const { checked } = this
if (this.active === 'tab3') {
const { page } = await this.$post(this.api.resourceLibrary, {
pageNum: 1,
@ -196,8 +197,9 @@ export default {
})
const list = page.records
list.forEach(e => {
const cur = checked.find(m => m.resourceName && m.id === e.id)
e.name = e.resourceName
e.check = false
e.check = !!cur
})
this.sources = list
} else {
@ -212,10 +214,26 @@ export default {
n.check = false
all.push(...n.subsections)
n.subsections.forEach(m => {
m.check = false
const cur = checked.find(j => m.cid === j.cid && m.id === j.id)
m.check = !!cur
})
})
})
list.forEach(e => {
e.shrink = false
e.check = false
e.chapters.forEach(n => {
n.shrink = false
n.check = n.subsections.every(m => m.check)
})
})
list.forEach(e => {
e.shrink = false
e.check = e.chapters.every(m => m.check)
})
list[0].shrink = true
list[0].chapters[0].shrink = true
this.allSections = all
@ -231,6 +249,7 @@ export default {
this.getData();
},
tabChange (index) {
this.keyword = ''
this.active = index
this.getCourse()
},

@ -2,7 +2,7 @@
<div class="wrap">
<el-card shadow="hover" class="m-b-20">
<div class="flex-between">
<el-page-header @back="back" :content="'新建课程'"></el-page-header>
<el-page-header @back="back" :content="(isCopy ? '复制' : !isAdd ? '编辑' : '新建') + '课程'"></el-page-header>
</div>
</el-card>
<div class="page">
@ -318,6 +318,8 @@ export default {
data () {
return {
cid: this.$route.query.cid,
isCopy: this.$route.query.copy,
isAdd: true,
editorConfig,
step: 1,
form: {
@ -435,6 +437,7 @@ export default {
},
mounted () {
if (this.cid) this.isAdd = false
this.getSubject()
this.getConfig()
this.getSystem()
@ -827,7 +830,7 @@ export default {
background: 'rgba(0, 0, 0, 0.7)'
})
try {
const res = await this.$post(this.api[cid ? 'modifyCourse' : 'createCurriculum'], form)
const res = await this.$post(this.api[cid && !this.isCopy ? 'modifyCourse' : 'createCurriculum'], form)
if (next) {
this.step = 2
if (!cid) {
@ -917,6 +920,10 @@ export default {
}
}
},
//
toStep (i) {
this.step = i
},
//
back () {
this.loadIns && this.loadIns.close()

@ -88,10 +88,12 @@
</el-switch>
</template>
</el-table-column>
<el-table-column label="操作" width="150" align="center">
<el-table-column label="操作" width="240" align="center">
<template slot-scope="scope">
<el-button type="text" @click="preview(scope.row)">预览课程</el-button>
<el-button type="text" @click="edit(scope.row)" v-auth="'/curriculum:编辑'">编辑</el-button>
<el-button type="text" @click="config(scope.row)" v-auth="'/curriculum:内容设置'">内容设置</el-button>
<el-button type="text" @click="copy(scope.row)">复制</el-button>
<el-button type="text" @click="handleDelete(scope.row)" v-auth="'/curriculum:删除'">删除</el-button>
</template>
</el-table-column>
@ -226,11 +228,19 @@ export default {
this.setReferrer()
this.$router.push(`/curriculum/detail?cid=${row.cid}`);
},
//
preview (row) {
this.$router.push(`/station?courseId=${row.cid || ''}&curriculumName=${encodeURIComponent(row.curriculumName)}&mallId=${row.mallId || ''}`)
},
//
config (row) {
this.setReferrer()
this.$router.push(`/curriculum/content?cid=${row.cid}&name=${row.curriculumName}`);
},
//
async copy (row) {
this.$router.push(`/curriculum/detail?cid=${row.cid}&copy=1`)
},
//
handleDelete (row) {
this.$post(`${this.api.deleteCoursePrompt}?cids=${row.cid}`).then(({ status }) => {

@ -64,7 +64,7 @@
<el-button type="primary" round @click="delAllSelection" v-auth>批量删除</el-button>
</div>
</div>
<el-table :data="orderData" class="table" ref="table" header-align="center"
<el-table v-loading="loading" :data="orderData" class="table" ref="table" header-align="center"
@selection-change="handleSelectionChange" row-key="orderId">
<el-table-column type="selection" width="55" align="center" :reserve-selection="true"></el-table-column>
<el-table-column type="index" width="100" label="序号" align="center">
@ -145,6 +145,7 @@ export default {
name: "已取消",
value: 2
}],
loading: false,
page: +this.$route.query.page || 1,
pageSize: 10,
totals: 0,
@ -176,15 +177,16 @@ export default {
val = 5;
}
},
getData () {
const sid = this.$store.state.dataPer.find(e => e.permissionName === '订单管理')
let data = {
...this.form,
pageNo: this.page,
pageSize: this.pageSize,
supplierId: sid ? sid.supplierId : ''
};
this.$post(this.api.orderList, data).then(res => {
async getData () {
try {
this.loading = true
const sid = this.$store.state.dataPer.find(e => e.permissionName === '订单管理')
const res = await this.$post(this.api.orderList, {
...this.form,
pageNo: this.page,
pageSize: this.pageSize,
supplierId: sid ? sid.supplierId : ''
})
res.orderPage.orders.forEach(e => {
e.orderType = this.orderTypeFn(e.orderType);
e.orderStatus = this.orderStatusFn(e.orderStatus);
@ -192,7 +194,9 @@ export default {
});
this.orderData = res.orderPage.orders;
this.totals = res.orderPage.total;
}).catch(res => { });
} finally {
this.loading = false
}
},
//
clearprovince () {

@ -73,9 +73,9 @@
<template v-if="active === 2">
<el-table-column key="1" prop="resourceDescription" min-width="160" label="资源描述"
align="center"></el-table-column>
<el-table-column key="2" prop="name" width="100" label="是否被引用" align="center">
<!-- <el-table-column key="2" prop="name" width="100" label="是否被引用" align="center">
<template slot-scope="scope">{{ scope.row.isReferenced ? '是' : '否' }}</template>
</el-table-column>
</el-table-column> -->
</template>
<template v-else>
<el-table-column key="3" prop="curriculumName" min-width="160" label="课程名称" align="center"></el-table-column>
@ -318,6 +318,7 @@ export default {
tabChange (id) {
this.active = id
this.form.cid = ''
this.$refs.table.clearSelection()
this.initData()
this.getCourse()
this.$router.push({
@ -423,7 +424,7 @@ export default {
scriptTag.src = "https://g.alicdn.com/de/prismplayer/2.8.2/aliplayer-min.js";
document.body.appendChild(scriptTag);
},
preview (row) {
async preview (row) {
if (this.transferType(row.fileType) == "视频") {
//
if (row.fileId) {
@ -451,32 +452,30 @@ export default {
this.pdfSrc = row.fileUrl;
this.pdfVisible = true;
} else {
this.$get(`${this.api.getSubsection}/${row.id}`).then(res => {
this.previewing = true;
this.loadIns = Loading.service();
this.$route.fullPath.includes("#file") || history.pushState({ file: true }, "文件预览", "#" + this.$route.fullPath + "#file");
if (row.fileType == "pptx") {
this.isPPT = true;
this.isWord = false;
this.isExcel = false;
} else if (row.fileType == "doc" || row.fileType == "docx") {
this.isPPT = false;
this.isWord = true;
this.isExcel = false;
} else if (row.fileType == "xls" || row.fileType == "xlsx") {
this.isExcel = true;
this.isPPT = false;
this.isWord = false;
} else {
this.isPPT = false;
this.isWord = false;
this.isExcel = false;
}
this.iframeSrc = res.previewUrl;
this.$nextTick(() => {
this.iframeOnload();
});
}).catch(err => { })
this.previewing = true;
this.loadIns = Loading.service();
this.$route.fullPath.includes("#file") || history.pushState({ file: true }, "文件预览", "#" + this.$route.fullPath + "#file");
if (row.fileType == "pptx") {
this.isPPT = true
this.isWord = false
this.isExcel = false
} else if (row.fileType == "doc" || row.fileType == "docx") {
this.isPPT = false
this.isWord = true
this.isExcel = false
} else if (row.fileType == "xls" || row.fileType == "xlsx") {
this.isExcel = true
this.isPPT = false
this.isWord = false
} else {
this.isPPT = false
this.isWord = false
this.isExcel = false
}
this.iframeSrc = 'https://view.officeapps.live.com/op/view.aspx?src=' + row.fileUrl
this.$nextTick(() => {
this.iframeOnload()
})
}
},
iframeOnload () {

@ -347,22 +347,25 @@ export default {
this.$message.warning("该项目名称已存在");
return;
}
this.currentRow.projectManage.projectName = this.projectName;
this.currentRow.projectManage.projectId = "";
this.currentRow.projectManage.founder = 0
this.currentRow.projectJudgmentList.forEach(i => {
i.projectId = "";
});
const data = this.currentRow
data.projectManage.projectName = this.projectName;
data.projectManage.projectId = ''
data.projectManage.createTime = ''
data.projectManage.updateTime = ''
data.projectManage.founder = 0
data.projectJudgmentList.forEach(i => {
i.projectId = ''
})
this.$post(`${this.api.copyProjectManage}`, this.currentRow).then(res => {
if (res.status === 200) {
this.form.founder = 0
this.initData();
this.$message.success("复制实验项目成功");
this.copyVisible = false;
this.initData()
this.$message.success("复制实验项目成功")
this.copyVisible = false
} else {
this.$message.error(res.message);
this.$message.error(res.message)
}
}).catch(err => { });
}).catch(err => { })
},
back () { //
this.$router.push(this.$store.state.referrer || '/configure')

@ -310,6 +310,20 @@
</el-form-item>
<el-form-item class="req" label="产品简介" prop="briefIntroduction">
<Editor api-key='rnk6zw9v267xqz7pf98twt1vmrvltmd436je7a642pckltda' v-model="form.mall.productIntroduction"
:init="editorConfig" :disabled="isDetail" />
</el-form-item>
<el-form-item class="req" label="详情介绍" prop="briefIntroduction">
<Editor api-key='rnk6zw9v267xqz7pf98twt1vmrvltmd436je7a642pckltda'
v-model="form.mall.detailedIntroduction" :init="editorConfig" :disabled="isDetail" />
</el-form-item>
<el-form-item prop="file" label="产品参数">
<Upload :limit="20" :changeFileList="false" :file-list.sync="form.mallAnnex" :on-remove="handleFileRemove"
@onSuccess="uploadSuccessFile" />
</el-form-item>
<!-- 大赛项目配置 -->
<div v-if="form.classificationIds == 3" class="mgb20">
<div class="mgb20 flex-between">
@ -354,20 +368,6 @@
</el-table-column>
</el-table>
</div>
<el-form-item class="req" label="产品简介" prop="briefIntroduction">
<Editor api-key='rnk6zw9v267xqz7pf98twt1vmrvltmd436je7a642pckltda' v-model="form.mall.productIntroduction"
:init="editorConfig" :disabled="isDetail" />
</el-form-item>
<el-form-item class="req" label="详情介绍" prop="briefIntroduction">
<Editor api-key='rnk6zw9v267xqz7pf98twt1vmrvltmd436je7a642pckltda'
v-model="form.mall.detailedIntroduction" :init="editorConfig" :disabled="isDetail" />
</el-form-item>
<el-form-item prop="file" label="产品参数">
<Upload :limit="20" :changeFileList="false" :file-list.sync="form.mallAnnex" :on-remove="handleFileRemove"
@onSuccess="uploadSuccessFile" />
</el-form-item>
</el-col>
</el-row>
</el-form>
@ -446,30 +446,32 @@
<el-dialog title="关联产品" :visible.sync="productVisible" width="800px" :close-on-click-modal="false"
class="product-dia">
<div class="tabs">
<a class="item" v-for="(item, i) in tabs" :key="i" :class="{ active: i == productActive }"
@click="tabChange(i)">{{
item }}</a>
</div>
<el-input placeholder="请输入产品名称" prefix-icon="el-icon-search" v-model="productKeyword" clearable
style="width: 200px;margin-bottom: 10px;"></el-input>
<el-table :data="products" class="table" ref="table" header-align="center" row-key="id">
<el-table-column width="80" align="center">
<template slot-scope="scope">
<el-radio class="product-radio" v-model="selectProduct" :label="scope.row.cid"></el-radio>
</template>
</el-table-column>
<el-table-column type="index" width="100" label="序号" align="center">
<template slot-scope="scope">
{{ scope.$index + (page - 1) * pageSize + 1 }}
</template>
</el-table-column>
<el-table-column prop="curriculumName" label="产品名称" min-width="150" align="center"></el-table-column>
</el-table>
<div class="pagination">
<el-pagination background layout="total, prev, pager, next" :total="total" @current-change="handleCurrentChange"
:current-page="page">
</el-pagination>
<div v-loading="productLoading">
<div class="tabs">
<a class="item" v-for="(item, i) in tabs" :key="i" :class="{ active: i == productActive }"
@click="tabChange(i)">{{
item }}</a>
</div>
<el-input placeholder="请输入产品名称" prefix-icon="el-icon-search" v-model="productKeyword" clearable
style="width: 200px;margin-bottom: 10px;"></el-input>
<el-table :data="products" class="table" ref="table" header-align="center" row-key="id">
<el-table-column width="80" align="center">
<template slot-scope="scope">
<el-radio class="product-radio" v-model="selectProduct" :label="scope.row.cid"></el-radio>
</template>
</el-table-column>
<el-table-column type="index" width="100" label="序号" align="center">
<template slot-scope="scope">
{{ scope.$index + (page - 1) * pageSize + 1 }}
</template>
</el-table-column>
<el-table-column prop="curriculumName" label="产品名称" min-width="150" align="center"></el-table-column>
</el-table>
<div class="pagination">
<el-pagination background layout="total, prev, pager, next" :total="total"
@current-change="handleCurrentChange" :current-page="page">
</el-pagination>
</div>
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="productVisible = false">取消</el-button>
@ -643,6 +645,7 @@ export default {
],
},
productVisible: false,
productLoading: false,
tabs: ['理论课程', '实训课程', '理实课程', '数据前瞻', '职站增值应用'],
products: [],
multipleSelection: [],
@ -823,32 +826,33 @@ export default {
this.getProduct()
},
//
getProduct () {
async getProduct () {
const active = this.productActive
const keyword = this.productKeyword
//
if (active < 3) {
const sid = this.$store.state.dataPer.find(e => e.permissionName === '课程管理')
this.$post(this.api.curriculumList, {
curriculumName: keyword,
curriculumType: active,
pageNum: this.page,
pageSize: this.pageSize,
supplierId: sid ? sid.supplierId : '',
isShelves: 1,
platformId: Setting.platformId
}).then(({ page }) => {
this.productLoading = true
try {
//
if (active < 3) {
const sid = this.$store.state.dataPer.find(e => e.permissionName === '课程管理')
const { page } = await this.$post(this.api.curriculumList, {
curriculumName: keyword,
curriculumType: active,
pageNum: this.page,
pageSize: this.pageSize,
supplierId: sid ? sid.supplierId : '',
isShelves: 1,
platformId: Setting.platformId
})
this.products = page.records
this.total = page.total
}).catch(err => { })
} else if (active == 3) { //
this.$post(this.api.listByEntity, {
pageNum: this.page,
pageSize: this.pageSize,
productName: keyword,
supplierId: '1',
status: 1
}).then(res => {
} else if (active == 3) { //
const res = await this.$post(this.api.listByEntity, {
pageNum: this.page,
pageSize: this.pageSize,
productName: keyword,
supplierId: '1',
status: 1
})
const list = res.pageList.records
list.forEach(e => {
e.cid = e.id
@ -856,9 +860,8 @@ export default {
})
this.products = list
this.total = res.pageList.total
}).catch(res => { })
} else { //
this.$post(this.api.getValueModule + '?platformId=1').then(res => {
} else { //
const res = await this.$post(this.api.getValueModule + '?platformId=1')
const list = res.valueList
list.forEach(e => {
e.cid = e.id
@ -866,7 +869,9 @@ export default {
})
this.products = list
this.total = list.length
}).catch(err => { })
}
} finally {
this.productLoading = false
}
},
initProduct () {

File diff suppressed because it is too large Load Diff
Loading…
Cancel
Save