Commit e3506c0f authored by 罗超's avatar 罗超

新增版章节

parent 58a79dac
...@@ -32,13 +32,12 @@ module.exports = function (ctx) { ...@@ -32,13 +32,12 @@ module.exports = function (ctx) {
// https://github.com/quasarframework/quasar/tree/dev/extras // https://github.com/quasarframework/quasar/tree/dev/extras
extras: [ extras: [
// 'ionicons-v4', // 'ionicons-v4',
// 'mdi-v5', 'mdi-v5',
// 'fontawesome-v5', // 'fontawesome-v5',
// 'eva-icons', // 'eva-icons',
// 'themify', // 'themify',
// 'line-awesome', // 'line-awesome',
// 'roboto-font-latin-ext', // this or either 'roboto-font', NEVER both! // 'roboto-font-latin-ext', // this or either 'roboto-font', NEVER both!
'roboto-font', // optional, you are not bound to it 'roboto-font', // optional, you are not bound to it
'material-icons' // optional, you are not bound to it 'material-icons' // optional, you are not bound to it
], ],
...@@ -49,8 +48,8 @@ module.exports = function (ctx) { ...@@ -49,8 +48,8 @@ module.exports = function (ctx) {
env: ctx.dev ? { env: ctx.dev ? {
//API: 'http://192.168.1.36:8300/api' //API: 'http://192.168.1.36:8300/api'
API: 'https://localhost:5001/api', // API: 'https://localhost:5001/api',
// API: 'http://192.168.20.24:8300/api', API: 'http://192.168.20.51:8088/api',
// API: 'http://testeduapi.oytour.com/api', // API: 'http://testeduapi.oytour.com/api',
// API: 'http://192.168.20.9:8085/api', // API: 'http://192.168.20.9:8085/api',
// API: 'http://192.168.20.17:8017/api', // API: 'http://192.168.20.17:8017/api',
...@@ -158,7 +157,9 @@ module.exports = function (ctx) { ...@@ -158,7 +157,9 @@ module.exports = function (ctx) {
'QRadio', 'QRadio',
'QBtnGroup' 'QBtnGroup'
], ],
// directives: [], directives: [
'ClosePopup'
],
// Quasar plugins // Quasar plugins
plugins: [ plugins: [
......
...@@ -12,7 +12,7 @@ export default { ...@@ -12,7 +12,7 @@ export default {
<style> <style>
@import url('~assets/css/font.css'); @import url('~assets/css/font.css');
@import url('//at.alicdn.com/t/font_2077629_1jbxfhyh7ir.css'); @import url('//at.alicdn.com/t/font_2077629_lgl3u1kdk1a.css');
html, html,
body, body,
...@@ -23,6 +23,9 @@ body, ...@@ -23,6 +23,9 @@ body,
font-family: -apple-system,BlinkMacSystemFont,'pingfang',' Microsoft YaHei',"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji"; font-family: -apple-system,BlinkMacSystemFont,'pingfang',' Microsoft YaHei',"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";
color: #3f4254; color: #3f4254;
} }
.fullscreen{
z-index: 99999;
}
.q-position-engine{ .q-position-engine{
z-index: 9999; z-index: 9999;
} }
......
...@@ -203,6 +203,78 @@ export function queryChapterTree(data) { ...@@ -203,6 +203,78 @@ export function queryChapterTree(data) {
}) })
} }
/**
* 保存课程章节
* @param {JSON参数} data
*/
export function saveChapter(data) {
return request({
url: "/Course/SetChapter",
method: 'post',
data
})
}
/**
* 保存课程章节
* @param {JSON参数} data
*/
export function getCourseRate(data) {
return request({
url: "/Course/GetCourseRateEnumList",
method: 'post',
data
})
}
/**
* 保存课程章节
* @param {JSON参数} data
*/
export function deleteChapters(data) {
return request({
url: "/Course/BatchRemoveChapter",
method: 'post',
data
})
}
/**
* 保存课程章节
* @param {JSON参数} data
*/
export function setChaptersRate(data) {
return request({
url: "/Course/BatchSetChapterRate",
method: 'post',
data
})
}
/**
* 批量更新章节编号和ID
* @param {JSON参数} data
*/
export function batchUpdateChapterNo(data) {
return request({
url: "/Course/SetBatchChapterNo",
method: 'post',
data
})
}
/**
* 修改章节名称
* @param {JSON参数} data
*/
export function updateChapterName(data) {
return request({
url: "/Course/SetChapterName",
method: 'post',
data
})
}
/** /**
* 获取课程销售端口 * 获取课程销售端口
*/ */
......
...@@ -69,7 +69,8 @@ ...@@ -69,7 +69,8 @@
}, },
watch: { watch: {
value(newVal, oldVal) { value(newVal, oldVal) {
if (!this.isInputChange && newVal) { console.log("监听到变化1",newVal,this.ue.isReady,this.isInputChange)
if (!this.isInputChange) {
if (this.ue) { if (this.ue) {
if (this.ue.isReady !== 1) { if (this.ue.isReady !== 1) {
let self = this; let self = this;
...@@ -84,6 +85,7 @@ ...@@ -84,6 +85,7 @@
}, 100); }, 100);
return; return;
} }
console.log("监听到变化",newVal)
this.ue.setContent(newVal); this.ue.setContent(newVal);
} else { } else {
this.tempContent = newVal; this.tempContent = newVal;
...@@ -222,6 +224,9 @@ ...@@ -222,6 +224,9 @@
fileType + fileType +
'" class="ans-insertaudio-module" module="_insertaudio">' + ' </iframe></p>'; '" class="ans-insertaudio-module" module="_insertaudio">' + ' </iframe></p>';
}, },
reloadNewValue(){
this.isInputChange=false
},
loadUe() { loadUe() {
const _this = this; const _this = this;
//上传附件 //上传附件
......
This diff is collapsed.
This diff is collapsed.
...@@ -144,7 +144,7 @@ ...@@ -144,7 +144,7 @@
<q-item-label>恢复</q-item-label> <q-item-label>恢复</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item style="display:none;" clickable v-close-popup @click="goMycourse(props.row)"> <q-item clickable v-close-popup @click="goMycourse(props.row)">
<q-item-section> <q-item-section>
<q-item-label>详情</q-item-label> <q-item-label>详情</q-item-label>
</q-item-section> </q-item-section>
......
...@@ -84,15 +84,15 @@ ...@@ -84,15 +84,15 @@
<!-- <li :class="{'checkedLi':commonIndex==1}" @click="gotoPage('question',1)"> <!-- <li :class="{'checkedLi':commonIndex==1}" @click="gotoPage('question',1)">
<i class="iconfont icon-tiku"></i>题库 <i class="iconfont icon-tiku"></i>题库
</li> --> </li> -->
<li :class="{'checkedLi':commonIndex==2}" @click="gotoPage('teachplan',2)"> <!-- <li :class="{'checkedLi':commonIndex==2}" @click="gotoPage('teachplan',2)">
<i style="font-size:20px;" class="iconfont icon-PPT"></i>教案 <i style="font-size:20px;" class="iconfont icon-PPT"></i>教案
</li> </li> -->
<li :class="{'checkedLi':commonIndex==3}" @click="gotoPage('chapter',3)"> <li :class="{'checkedLi':commonIndex==3}" @click="gotoPage('chapter',3)">
<i class="iconfont icon-icon_zhangjielianxi"></i>章节 <i class="iconfont icon-icon_zhangjielianxi"></i>章节
</li> </li>
<li :class="{'checkedLi':commonIndex==4}" @click="gotoPage('coursejob',4)"> <!-- <li :class="{'checkedLi':commonIndex==4}" @click="gotoPage('coursejob',4)">
<i class="iconfont icon-icon_zhangjielianxi"></i>作业 <i class="iconfont icon-icon_zhangjielianxi"></i>作业
</li> </li> -->
</ul> </ul>
</div> </div>
</q-list> </q-list>
......
...@@ -698,6 +698,7 @@ const routes = [{ ...@@ -698,6 +698,7 @@ const routes = [{
component: () => component: () =>
import("pages/course/chapter.vue") import("pages/course/chapter.vue")
}, },
{ {
path: "/course/coursejob", //作业管理 path: "/course/coursejob", //作业管理
component: () => component: () =>
...@@ -845,7 +846,11 @@ const routes = [{ ...@@ -845,7 +846,11 @@ const routes = [{
title: '资产管理' title: '资产管理'
}, },
}, },
{
path: "/course/chapter-editor", //章节管理
component: () =>
import("pages/course/chapterEditor.vue")
},
{ {
path: "*", path: "*",
component: () => component: () =>
......
...@@ -24,4 +24,49 @@ export function validateUpperCase(str) { ...@@ -24,4 +24,49 @@ export function validateUpperCase(str) {
export function validatAlphabets(str) { export function validatAlphabets(str) {
const reg = /^[A-Za-z]+$/ const reg = /^[A-Za-z]+$/
return reg.test(str) return reg.test(str)
}
/** 比对数组是否相同 */
export function compareArray(arrA, arrB) {
let isSame = true
if (arrA.length !== arrB.length) {
return false
} else {
arrA.some((el, idx) => {
if (el !== arrB[idx]) {
isSame = false
return true
}
})
}
return isSame
}
/** 比对对象是否相同 */
export function compareObject(objA, objB,ignoreArray, endLoop) {
let isSame = true
let isArray = '[object Array]'
let isObject = '[object Object]'
for (var key in objA) {
if (objB[key] !== '' && !objB[key] && typeof objB[key] !== 'number') {
isSame = false
break
}
let type = Object.prototype.toString.call(objA[key])
if (type === isArray && ignoreArray) {
isSame = compareArray(objA[key], objB[key])
} else if (type === isObject) {
isSame = compareObject(objA[key], objB[key],ignoreArray)
} else if (objA[key] !== objB[key]) {
isSame = false
}
if (!isSame) {
return isSame
}
}
if (isSame && !endLoop) {
isSame = compareObject(objB, objA,ignoreArray, true)
}
return isSame
} }
\ No newline at end of file
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