lsc 1 year ago
parent
commit
d4158a9fc2

+ 1 - 1
dist/index.html

@@ -18,7 +18,7 @@
       border-radius: 10px;
       -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, .3);
       background-color: rgba(0, 0, 0, 0.1);
-    }</style><link href=./static/css/app.3121685c8a088e4ca549832db00eadbf.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.e97d134e001cf57d792e.js></script><script type=text/javascript src=./static/js/app.a2abc0b9f0a68678048f.js></script></body></html><script>function stopSafari() {
+    }</style><link href=./static/css/app.617f76978bfc5b66ad5a8d8d03f2561f.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.e97d134e001cf57d792e.js></script><script type=text/javascript src=./static/js/app.ea7ed2db6a5dfbe5728c.js></script></body></html><script>function stopSafari() {
     //阻止safari浏览器双击放大功能
     let lastTouchEnd = 0  //更新手指弹起的时间
     document.documentElement.addEventListener("touchstart", function (event) {

File diff suppressed because it is too large
+ 0 - 0
dist/static/css/app.3121685c8a088e4ca549832db00eadbf.css.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/css/app.617f76978bfc5b66ad5a8d8d03f2561f.css


File diff suppressed because it is too large
+ 0 - 0
dist/static/css/app.617f76978bfc5b66ad5a8d8d03f2561f.css.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/app.a2abc0b9f0a68678048f.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/app.ea7ed2db6a5dfbe5728c.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/app.ea7ed2db6a5dfbe5728c.js.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/manifest.3ad1d5771e9b13dbdad2.js.map


+ 142 - 0
src/components/directive/el-drag-dialog/drag.js

@@ -0,0 +1,142 @@
+export default {
+  bind(el, binding, vnode) {
+    const dialogHeaderEl = el.querySelector('.pzTop')
+    const dragDom = el
+    dialogHeaderEl.style.cssText += ';cursor:move;'
+    // dragDom.style.cssText += ';top:0px;'
+
+    // 获取原有属性 ie dom元素.currentStyle 火狐谷歌 window.getComputedStyle(dom元素, null);
+    const getStyle = (function() {
+      if (window.document.currentStyle) {
+        return (dom, attr) => dom.currentStyle[attr]
+      } else {
+        return (dom, attr) => getComputedStyle(dom, false)[attr]
+      }
+    })()
+    dialogHeaderEl.ontouchstart = (e) => {
+      if(e.target.className != "pzClose"){
+        e.preventDefault()
+      }
+      // 鼠标按下,计算当前元素距离可视区的距离
+      const disX = e.touches[0].pageX - dialogHeaderEl.offsetLeft
+      const disY = e.touches[0].pageY - dialogHeaderEl.offsetTop
+
+      const dragDomWidth = dragDom.offsetWidth
+      const dragDomHeight = dragDom.offsetHeight
+
+      const screenWidth = document.body.clientWidth
+      const screenHeight = document.body.clientHeight
+
+      const minDragDomLeft = dragDom.offsetLeft
+      const maxDragDomLeft = screenWidth - dragDom.offsetLeft - dragDomWidth
+
+      const minDragDomTop = dragDom.offsetTop
+      const maxDragDomTop = screenHeight - dragDom.offsetTop - dragDomHeight
+
+      // 获取到的值带px 正则匹配替换
+      let styL = getStyle(dragDom, 'left')
+      let styT = getStyle(dragDom, 'top')
+
+      if (styL.includes('%')) {
+        styL = +document.body.clientWidth * (+styL.replace(/\%/g, '') / 100)
+        styT = +document.body.clientHeight * (+styT.replace(/\%/g, '') / 100)
+      } else {
+        styL = +styL.replace(/\px/g, '')
+        styT = +styT.replace(/\px/g, '')
+      }
+
+      dialogHeaderEl.ontouchmove = function(e) {
+        e.preventDefault()
+        // 通过事件委托,计算移动的距离
+        let left = e.touches[0].pageX - disX
+        let top = e.touches[0].pageY - disY
+
+        // 边界处理
+        if (-(left) > minDragDomLeft) {
+          left = -minDragDomLeft
+        } else if (left > maxDragDomLeft) {
+          left = maxDragDomLeft
+        }
+
+        if (-(top) > minDragDomTop) {
+          top = -minDragDomTop
+        } else if (top > maxDragDomTop) {
+          top = maxDragDomTop
+        }
+
+        // 移动当前元素
+        dragDom.style.cssText += `;left:${left + styL}px;top:${top + styT}px;`
+
+        // emit onDrag event
+        // vnode.child.$emit('dragDialog')
+      }
+    }
+    dialogHeaderEl.onmousedown = (e) => {
+      // 鼠标按下,计算当前元素距离可视区的距离
+      const disX = e.clientX - dialogHeaderEl.offsetLeft
+      const disY = e.clientY - dialogHeaderEl.offsetTop
+
+      const dragDomWidth = dragDom.offsetWidth
+      const dragDomHeight = dragDom.offsetHeight
+
+      const screenWidth = document.body.clientWidth
+      const screenHeight = document.body.clientHeight
+
+      const minDragDomLeft = dragDom.offsetLeft
+      const maxDragDomLeft = screenWidth - dragDom.offsetLeft - dragDomWidth
+
+      const minDragDomTop = dragDom.offsetTop
+      const maxDragDomTop = screenHeight - dragDom.offsetTop - dragDomHeight
+
+      // 获取到的值带px 正则匹配替换
+      let styL = getStyle(dragDom, 'left')
+      let styT = getStyle(dragDom, 'top')
+
+      if (styL.includes('%')) {
+        styL = +document.body.clientWidth * (+styL.replace(/\%/g, '') / 100)
+        styT = +document.body.clientHeight * (+styT.replace(/\%/g, '') / 100)
+      } else {
+        styL = +styL.replace(/\px/g, '')
+        styT = +styT.replace(/\px/g, '')
+      }
+
+      dialogHeaderEl.onmousemove = function(e) {
+        // 通过事件委托,计算移动的距离
+        let left = e.clientX - disX
+        let top = e.clientY - disY
+
+        // 边界处理
+        if (-(left) > minDragDomLeft) {
+          left = -minDragDomLeft
+        } else if (left > maxDragDomLeft) {
+          left = maxDragDomLeft
+        }
+
+        if (-(top) > minDragDomTop) {
+          top = -minDragDomTop
+        } else if (top > maxDragDomTop) {
+          top = maxDragDomTop
+        }
+
+        // 移动当前元素
+        dragDom.style.cssText += `;left:${left + styL}px;top:${top + styT}px;`
+
+        // emit onDrag event
+        // vnode.child.$emit('dragDialog')
+      }
+
+      document.onmouseup = function(e) {
+        dialogHeaderEl.onmousemove = null
+        document.onmouseup = null
+        dialogHeaderEl.ontouchmove = null
+        document.ontouchend = null
+      }
+      document.ontouchend = function(e) {
+        dialogHeaderEl.onmousemove = null
+        document.onmouseup = null
+        dialogHeaderEl.ontouchmove = null
+        document.ontouchend = null
+      }
+    }
+  }
+}

+ 13 - 0
src/components/directive/el-drag-dialog/index.js

@@ -0,0 +1,13 @@
+import drag from './drag'
+
+const install = function(Vue) {
+  Vue.directive('el-drag-dialog', drag)
+}
+
+if (window.Vue) {
+  window['el-drag-dialog'] = drag
+  Vue.use(install); // eslint-disable-line
+}
+
+drag.install = install
+export default drag

+ 30 - 6
src/components/easy2/studyStudent.vue

@@ -5221,6 +5221,11 @@
         </div> -->
         <div class="checkbox">
           <div class="check" style="font-size: 25px">评课笔记</div>
+          <el-select v-model="pzStype" @change="selectPz" class="selectBox">
+            <el-option label="时间降序" :value="1"></el-option>
+            <el-option label="时间升序" :value="2"></el-option>
+            <el-option label="我的评课" :value="3"></el-option>
+          </el-select>
           <img src="../../assets/pzBtn.png" @click="pzDialog = false" alt="" />
         </div>
       </div>
@@ -5270,7 +5275,7 @@
         </div>
       </div>
     </div>
-    <div v-if="addPzDialog == true" class="addDialogCss">
+    <div v-if="addPzDialog == true" class="addDialogCss" v-el-drag-dialog>
       <div class="pzTop">
         <div class="teacherPz">
           <div class="teacherPzImg">
@@ -5279,7 +5284,7 @@
           <div style="margin-left: 10px; height: 25px">教师批注</div>
         </div>
         <div @click="addPzDialog = false">
-          <img src="../../assets/close1.png" alt="" />
+          <img src="../../assets/close1.png" class="pzClose" alt="" />
         </div>
       </div>
       <div class="addPzBox">
@@ -7321,6 +7326,7 @@ export default {
       dialogVisibleWordCloud: false,
       wordCloudData: [],
       isPickStudent: [],
+      pzStype:1,
     };
   },
   methods: {
@@ -10852,9 +10858,11 @@ export default {
         cid: this.id,
         s: this.courseType,
         t: this.taskCount,
+        type: this.pzStype,
+        uid: this.userid,
       };
       this.ajax
-        .get(this.$store.state.api + "selectPzList", params)
+        .get(this.$store.state.api + "selectPzListType", params)
         .then((res) => {
           this.pzList = res.data[0];
         })
@@ -16086,6 +16094,7 @@ export default {
   justify-content: space-between;
   height: 40px;
   border-radius: 15px 15px 0 0;
+  user-select: none;
 }
 
 .pzTop2 .checkbox {
@@ -16251,15 +16260,15 @@ export default {
 
 .addDialogCss {
   position: fixed;
-  right: 37%;
-  top: 50%;
   width: 600px;
-  transform: translateY(-50%);
   height: 70%;
   min-height: 450px;
   box-shadow: 0px 0 8px 0px #555555;
   border-radius: 15px;
   z-index: 999;
+  left: 50%;
+  top: 50%;
+  margin:-18% 0 0 -300px;
 }
 
 .teacherPz {
@@ -17364,4 +17373,19 @@ ol {
   align-items: flex-start;
   flex-wrap: wrap;
 }
+
+.selectBox {
+  width: 110px;
+  margin-left: 10px;
+  margin: 0 10px 0 auto;
+}
+
+.selectBox>>>.el-input__inner {
+  height: 30px;
+  line-height: 30px;
+}
+
+.selectBox>>>.el-input__icon {
+  line-height: 30px;
+}
 </style>

+ 30 - 6
src/components/easy3/studyStudent.vue

@@ -8696,6 +8696,11 @@
         </div> -->
         <div class="checkbox">
           <div class="check" style="font-size: 25px">评课笔记</div>
+          <el-select v-model="pzStype" @change="selectPz" class="selectBox">
+            <el-option label="时间降序" :value="1"></el-option>
+            <el-option label="时间升序" :value="2"></el-option>
+            <el-option label="我的评课" :value="3"></el-option>
+          </el-select>
           <img src="../../assets/pzBtn.png" @click="pzDialog = false" alt="" />
         </div>
       </div>
@@ -8757,7 +8762,7 @@
         </div>
       </div>
     </div>
-    <div v-if="addPzDialog == true" class="addDialogCss">
+    <div v-if="addPzDialog == true" class="addDialogCss" v-el-drag-dialog>
       <div class="pzTop">
         <div class="teacherPz">
           <div class="teacherPzImg">
@@ -8766,7 +8771,7 @@
           <div style="margin-left: 10px; height: 25px">教师批注</div>
         </div>
         <div @click="addPzDialog = false">
-          <img src="../../assets/close1.png" alt="" />
+          <img src="../../assets/close1.png" class="pzClose" alt="" />
         </div>
       </div>
       <div class="addPzBox">
@@ -11953,6 +11958,7 @@ export default {
       dialogVisibleWordCloud: false,
       wordCloudData: [],
       isPickStudent: [],
+      pzStype:1,
     };
   },
   methods: {
@@ -15359,9 +15365,11 @@ export default {
         cid: this.id,
         s: this.courseType,
         t: this.taskCount,
+        type: this.pzStype,
+        uid: this.userid,
       };
       this.ajax
-        .get(this.$store.state.api + "selectPzList", params)
+        .get(this.$store.state.api + "selectPzListType", params)
         .then((res) => {
           this.pzList = res.data[0];
         })
@@ -20581,6 +20589,7 @@ export default {
   justify-content: space-between;
   height: 40px;
   border-radius: 15px 15px 0 0;
+  user-select: none;
 }
 
 .pzTop2 .checkbox {
@@ -20746,15 +20755,15 @@ export default {
 
 .addDialogCss {
   position: fixed;
-  right: 37%;
-  top: 50%;
   width: 600px;
-  transform: translateY(-50%);
   height: 70%;
   min-height: 450px;
   box-shadow: 0px 0 8px 0px #555555;
   border-radius: 15px;
   z-index: 999;
+  left: 50%;
+  top: 50%;
+  margin:-18% 0 0 -300px;
 }
 
 .teacherPz {
@@ -21857,4 +21866,19 @@ ol {
   align-items: flex-start;
   flex-wrap: wrap;
 }
+
+.selectBox {
+  width: 110px;
+  margin-left: 10px;
+  margin: 0 10px 0 auto;
+}
+
+.selectBox>>>.el-input__inner {
+  height: 30px;
+  line-height: 30px;
+}
+
+.selectBox>>>.el-input__icon {
+  line-height: 30px;
+}
 </style>

+ 31 - 7
src/components/student/studyStudent.vue

@@ -659,6 +659,11 @@
         </div> -->
         <div class="checkbox">
           <div class="check" style="font-size: 25px">评论</div>
+          <el-select v-model="pzStype" @change="selectPz" class="selectBox">
+            <el-option label="时间降序" :value="1"></el-option>
+            <el-option label="时间升序" :value="2"></el-option>
+            <el-option label="我的评课" :value="3"></el-option>
+          </el-select>
           <img src="../../assets/pzBtn.png" @click="(pzDialog = false), setVHeight()" alt="" />
         </div>
       </div>
@@ -786,7 +791,7 @@
         </div>
       </div>
     </div>
-    <div v-if="addPzDialog == true" class="addDialogCss">
+    <div v-if="addPzDialog == true" class="addDialogCss" v-el-drag-dialog>
       <div class="pzTop">
         <div class="teacherPz">
           <div class="teacherPzImg">
@@ -795,7 +800,7 @@
           <div style="margin-left: 10px; height: 25px">教师批注</div>
         </div>
         <div @click="addPzDialog = false">
-          <img src="../../assets/close1.png" alt="" />
+          <img src="../../assets/close1.png" class="pzClose" alt="" />
         </div>
       </div>
       <div class="addPzBox">
@@ -1233,7 +1238,8 @@ export default {
       },
       psJson4: {
         z: 0,
-      }
+      },
+      pzStype:1,
     };
   },
   methods: {
@@ -1391,9 +1397,11 @@ export default {
         cid: this.id,
         s: this.courseType,
         t: this.taskCount,
+        type: this.pzStype,
+        uid: this.userid,
       };
       this.ajax
-        .get(this.$store.state.api + "selectPzList", params)
+        .get(this.$store.state.api + "selectPzListType", params)
         .then((res) => {
           this.pzList = res.data[0];
         })
@@ -5147,6 +5155,7 @@ export default {
   justify-content: space-between;
   height: 40px;
   border-radius: 15px 15px 0 0;
+  user-select: none;
 }
 
 .pzTop2 .checkbox {
@@ -5349,15 +5358,15 @@ export default {
 
 .addDialogCss {
   position: fixed;
-  right: 37%;
-  top: 50%;
   width: 600px;
-  transform: translateY(-50%);
   height: 70%;
   min-height: 450px;
   box-shadow: 0px 0 8px 0px #555555;
   border-radius: 15px;
   z-index: 999;
+  left: 50%;
+  top: 50%;
+  margin:-18% 0 0 -300px;
 }
 
 .teacherPz {
@@ -6103,4 +6112,19 @@ ol {
 .tcMember+.tcMember::before {
   content: "、";
 }
+
+.selectBox {
+  width: 110px;
+  margin-left: 10px;
+  margin: 0 10px 0 auto;
+}
+
+.selectBox>>>.el-input__inner {
+  height: 30px;
+  line-height: 30px;
+}
+
+.selectBox>>>.el-input__icon {
+  line-height: 30px;
+}
 </style>

+ 31 - 7
src/components/studio/studyStudent.vue

@@ -644,6 +644,11 @@
         </div> -->
         <div class="checkbox">
           <div class="check" style="font-size: 25px">评论</div>
+          <el-select v-model="pzStype" @change="selectPz" class="selectBox">
+            <el-option label="时间降序" :value="1"></el-option>
+            <el-option label="时间升序" :value="2"></el-option>
+            <el-option label="我的评课" :value="3"></el-option>
+          </el-select>
           <img src="../../assets/pzBtn.png" @click="(pzDialog = false), setVHeight()" alt="" />
         </div>
       </div>
@@ -772,7 +777,7 @@
         </div>
       </div>
     </div>
-    <div v-if="addPzDialog == true" class="addDialogCss">
+    <div v-if="addPzDialog == true" class="addDialogCss" v-el-drag-dialog>
       <div class="pzTop">
         <div class="teacherPz">
           <div class="teacherPzImg">
@@ -781,7 +786,7 @@
           <div style="margin-left: 10px; height: 25px">教师批注</div>
         </div>
         <div @click="addPzDialog = false">
-          <img src="../../assets/close1.png" alt="" />
+          <img src="../../assets/close1.png" class="pzClose" alt="" />
         </div>
       </div>
       <div class="addPzBox">
@@ -1219,7 +1224,8 @@ export default {
       },
       psJson4: {
         z: 0,
-      }
+      },
+      pzStype:1,
     };
   },
   methods: {
@@ -1377,9 +1383,11 @@ export default {
         cid: this.id,
         s: this.courseType,
         t: this.taskCount,
+        type: this.pzStype,
+        uid: this.userid,
       };
       this.ajax
-        .get(this.$store.state.api + "selectPzList", params)
+        .get(this.$store.state.api + "selectPzListType", params)
         .then((res) => {
           this.pzList = res.data[0];
         })
@@ -5031,6 +5039,7 @@ export default {
   justify-content: space-between;
   height: 40px;
   border-radius: 15px 15px 0 0;
+  user-select: none;
 }
 
 .pzTop2 .checkbox {
@@ -5234,15 +5243,15 @@ export default {
 
 .addDialogCss {
   position: fixed;
-  right: 37%;
-  top: 50%;
   width: 600px;
-  transform: translateY(-50%);
   height: 70%;
   min-height: 450px;
   box-shadow: 0px 0 8px 0px #555555;
   border-radius: 15px;
   z-index: 999;
+  left: 50%;
+  top: 50%;
+  margin:-18% 0 0 -300px;
 }
 
 .teacherPz {
@@ -5988,4 +5997,19 @@ ol {
 .tcMember+.tcMember::before {
   content: "、";
 }
+
+.selectBox {
+  width: 110px;
+  margin-left: 10px;
+  margin: 0 10px 0 auto;
+}
+
+.selectBox>>>.el-input__inner {
+  height: 30px;
+  line-height: 30px;
+}
+
+.selectBox>>>.el-input__icon {
+  line-height: 30px;
+}
 </style>

+ 31 - 7
src/components/studyStudent.vue

@@ -7351,6 +7351,11 @@
         </div> -->
         <div class="checkbox">
           <div class="check" style="font-size: 25px">评课笔记</div>
+          <el-select v-model="pzStype" @change="selectPz" class="selectBox">
+            <el-option label="时间降序" :value="1"></el-option>
+            <el-option label="时间升序" :value="2"></el-option>
+            <el-option label="我的评课" :value="3"></el-option>
+          </el-select>
           <img src="../assets/pzBtn.png" @click="pzDialog = false" alt="" />
         </div>
       </div>
@@ -7412,7 +7417,7 @@
         </div>
       </div>
     </div>
-    <div v-if="addPzDialog == true" class="addDialogCss">
+    <div v-if="addPzDialog == true" class="addDialogCss" v-el-drag-dialog>
       <div class="pzTop">
         <div class="teacherPz">
           <div class="teacherPzImg">
@@ -7421,7 +7426,7 @@
           <div style="margin-left: 10px; height: 25px">教师批注</div>
         </div>
         <div @click="addPzDialog = false">
-          <img src="../assets/close1.png" alt="" />
+          <img src="../assets/close1.png" class="pzClose" alt="" />
         </div>
       </div>
       <div class="addPzBox">
@@ -10656,6 +10661,7 @@ export default {
       worksSid: "",
       wordCloudData: [],
       isPickStudent: [],
+      pzStype:1,
     };
   },
   methods: {
@@ -14703,9 +14709,11 @@ export default {
         cid: this.id,
         s: this.courseType,
         t: this.taskCount,
+        type: this.pzStype,
+        uid: this.userid,
       };
       this.ajax
-        .get(this.$store.state.api + "selectPzList", params)
+        .get(this.$store.state.api + "selectPzListType", params)
         .then((res) => {
           this.pzList = res.data[0];
         })
@@ -18706,7 +18714,7 @@ export default {
 }
 
 .toolBox {
-  padding: 15px 0 0 25px;
+  padding: 15px 0 10px 25px;
   display: flex;
   position: relative;
 }
@@ -19760,6 +19768,7 @@ export default {
   justify-content: space-between;
   height: 40px;
   border-radius: 15px 15px 0 0;
+  user-select: none;
 }
 
 .pzTop2 .checkbox {
@@ -19925,15 +19934,15 @@ export default {
 
 .addDialogCss {
   position: fixed;
-  right: 37%;
-  top: 50%;
   width: 600px;
-  transform: translateY(-50%);
   height: 70%;
   min-height: 450px;
   box-shadow: 0px 0 8px 0px #555555;
   border-radius: 15px;
   z-index: 999;
+  left: 50%;
+  top: 50%;
+  margin:-18% 0 0 -300px;
 }
 
 .teacherPz {
@@ -21026,4 +21035,19 @@ ol {
   align-items: flex-start;
   flex-wrap: wrap;
 }
+
+.selectBox {
+  width: 110px;
+  margin-left: 10px;
+  margin: 0 10px 0 auto;
+}
+
+.selectBox>>>.el-input__inner {
+  height: 30px;
+  line-height: 30px;
+}
+
+.selectBox>>>.el-input__icon {
+  line-height: 30px;
+}
 </style>

+ 3 - 1
src/main.js

@@ -16,10 +16,12 @@ import 'video.js/dist/video-js.css' //videoJs的样式
 import 'vue-video-player/src/custom-theme.css' //vue-video-player的样式
 import VueCookies from 'vue-cookies'
 import hevueImgPreview from './components/tools/hevue-img-preview'
+import drag from './components/directive/el-drag-dialog';
+
 
 Vue.use(VideoPlayer).use(VueCookies).use(hevueImgPreview, {
     clickMaskCLose: true
-})
+}).use(drag)
 Vue.prototype.$echarts = echarts
 Vue.prototype.$equipment=function(){
     let flag = navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i);

Some files were not shown because too many files changed in this diff