Просмотр исходного кода

修改精品课程样式与编辑权限

11wqe1 2 недель назад
Родитель
Сommit
0b7af54e05
2 измененных файлов с 40 добавлено и 17 удалено
  1. 12 0
      src/assets/icon/liyuan/courseEditC.svg
  2. 28 17
      src/components/pages/liyuan/CourseCon.vue

+ 12 - 0
src/assets/icon/liyuan/courseEditC.svg

@@ -0,0 +1,12 @@
+<svg width="28" height="28" viewBox="0 0 28 28" fill="none" xmlns="http://www.w3.org/2000/svg">
+<g clip-path="url(#clip0_61_67)">
+<path d="M27.75 14C27.75 6.40608 21.5939 0.25 14 0.25C6.40608 0.25 0.25 6.40608 0.25 14C0.25 21.5939 6.40608 27.75 14 27.75C21.5939 27.75 27.75 21.5939 27.75 14Z" stroke="#C4C4C4" stroke-width="0.5"/>
+<path d="M14 8H9.33333C8.97971 8 8.64057 8.14048 8.39052 8.39052C8.14048 8.64057 8 8.97971 8 9.33333V18.6667C8 19.0203 8.14048 19.3594 8.39052 19.6095C8.64057 19.8595 8.97971 20 9.33333 20H18.6667C19.0203 20 19.3594 19.8595 19.6095 19.6095C19.8595 19.3594 20 19.0203 20 18.6667V14" stroke="#606266" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
+<path d="M18.2494 7.75015C18.5146 7.48493 18.8743 7.33594 19.2494 7.33594C19.6245 7.33594 19.9842 7.48493 20.2494 7.75015C20.5146 8.01537 20.6636 8.37508 20.6636 8.75015C20.6636 9.12522 20.5146 9.48493 20.2494 9.75015L14.2407 15.7595C14.0824 15.9176 13.8869 16.0334 13.6721 16.0961L11.7567 16.6561C11.6994 16.6729 11.6386 16.6739 11.5807 16.659C11.5228 16.6442 11.47 16.6141 11.4277 16.5718C11.3854 16.5296 11.3553 16.4767 11.3405 16.4189C11.3257 16.361 11.3267 16.3002 11.3434 16.2428L11.9034 14.3275C11.9664 14.1128 12.0824 13.9175 12.2407 13.7595L18.2494 7.75015Z" stroke="#606266" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
+</g>
+<defs>
+<clipPath id="clip0_61_67">
+<rect width="28" height="28" fill="white"/>
+</clipPath>
+</defs>
+</svg>

+ 28 - 17
src/components/pages/liyuan/CourseCon.vue

@@ -18,13 +18,13 @@
               </el-option>
             </el-select>
 
-            <el-select v-model="groupA" @change="search" v-if="role == '1'" placeholder="所有者">
+            <el-select v-model="groupA" clearable @change="search" v-if="role == '1'" placeholder="所有者">
               <el-option value="4" label="全部"></el-option>
               <el-option value="2" label="我的课程"></el-option>
               <el-option value="3" label="协同课程"></el-option>
               <el-option value="1" label="他人课程"></el-option>
             </el-select>
-            <el-select v-model="groupA" @change="search" v-else placeholder="所有者">
+            <el-select v-model="groupA" clearable @change="search" v-else placeholder="所有者">
               <el-option value="0" label="全部"></el-option>
               <el-option value="2" label="我的课程"></el-option>
               <el-option value="3" label="协同课程"></el-option>
@@ -45,7 +45,7 @@
           <div class="ConblockTit">
               {{ i.title }}
           </div>
-          <div style="display: flex;gap: 10px;color: #969BA3;font-size: 12px;">
+          <div style="display: flex;gap: 10px;color: #969BA3;font-size: 14px;">
               <span v-if="i.state == 1">阶段模式</span>
               <span v-if="i.state == 2">任务模式</span>
               <span v-if="i.state == 3">极简模式</span>
@@ -53,7 +53,7 @@
               <span v-if="i.state == 6">上课模式</span>
               <span>@{{ i.school }}</span>
 
-          </div>
+            </div>
            <img class="PimgL" :src="i.cover != null && i.cover != ''
               ? JSON.parse(i.cover).length > 0
                 ? JSON.parse(i.cover)[0].url
@@ -61,7 +61,7 @@
               : mr
               " alt />
           <div class="foot">
-            <img style="cursor: pointer;" @click="goToCourse(i.courseId)" src="../../../assets/icon/liyuan/courseEdit.svg" alt="">
+            <img style="cursor: pointer;" @click="goToCourse(i.courseId,i.userid)" src="../../../assets/icon/liyuan/courseEditC.svg" alt="">
             <div class="ent" @click="entCourse(i)">进入</div>
           </div>
         </div>
@@ -260,7 +260,8 @@ export default {
       
        window.topU.postMessage({ cid: item.courseId, screenType: "3" }, "*");
     },
-    goToCourse(courseId) {
+    goToCourse(courseId,uid) {
+        if (this.userid != uid) return this.$message.info('课程创建者才可编辑哦')
         sessionStorage.setItem('gotype', 'backCourseCon');
 
         this.goToCourse4(courseId)
@@ -305,11 +306,11 @@ export default {
 
 <style scoped>
 .teacherDevelop{
+  display: flex;
+  flex-direction: column;
   width: 100%;
   height: 100%;
   padding: 40px 90px;
-  display: flex;
-  flex-direction: column;
   box-sizing: border-box;
   background: #FAFAFA;
 
@@ -343,16 +344,22 @@ export default {
 }
 .courseListSearch >>> .el-select .el-input__inner{
   border-radius: 20px;
-  height: 28px;
+  height: 40px;
   width: 110px;
-  border: 1px solid #969BA3 !important;
-  color: #969BA3;
+  /* border: 1px solid #969BA3 !important; */
+  color: #606266;
+}
+.courseListSearch>>> .el-input__inner::-webkit-input-placeholder {
+  color: #606266 !important;
 }
+/* .courseListSearch >>> .el-input__placeholder{
+  color: #606266 !important;
+} */
 .courseListSearch >>> .el-input__icon{
-  line-height: 28px;
+  line-height: 40px;
 }
 .serachCon >>> .el-input__inner{
-  height: 28px !important;
+  height: 40px !important;
   border-radius: 20px !important;
   width: 300px !important;
   border: none;
@@ -381,6 +388,7 @@ export default {
   object-fit: cover;
 }
 .ConblockTit{
+  font-size: 18px;
   -webkit-line-clamp: 1;
   display: -webkit-box;
   -webkit-box-orient: vertical;
@@ -394,9 +402,8 @@ export default {
   gap: 10px;
 }
 .foot > .ent{
-  border: 1px solid #000000;
-  width: 68;
-  height: 28;
+  border: 1px solid #bcbcbc;
+  color: #606266;
   opacity: 1;
   gap: 10px;
   cursor: pointer;
@@ -407,6 +414,11 @@ export default {
   padding-left: 20px;
   border-width: 1px;
 }
+.ent:hover{
+    border: 1px solid #4080FF;
+    background: #4080FF;
+    color: #fff;
+}
 .moreL{
   font-family: PingFang HK;
   font-size: 16px;
@@ -414,6 +426,5 @@ export default {
   align-items: center;
   color: #969BA3;
   justify-content: flex-end;
-  cursor: pointer;
 }
 </style>