Browse Source

Merge branch 'beta'

SanHQin 3 weeks ago
parent
commit
e21b895766

+ 1 - 1
dist/index.html

@@ -37,7 +37,7 @@
       width: 100%;
       background: #e6eaf0;
       font-family: '黑体';
-    }</style><link href=./static/css/app.8c2a8133b99957403ef487482bdaffdc.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.23ea04dc469b57e2b4f8.js></script><script type=text/javascript src=./static/js/vendor.714ff2bfc93f2f096b79.js></script><script type=text/javascript src=./static/js/app.3c119885635e94c7d2c7.js></script></body></html><script>function stopSafari() {
+    }</style><link href=./static/css/app.f1b1a0fd13fa0963549536221dab7c89.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.23ea04dc469b57e2b4f8.js></script><script type=text/javascript src=./static/js/vendor.714ff2bfc93f2f096b79.js></script><script type=text/javascript src=./static/js/app.90998a686a99eb854f91.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.f1b1a0fd13fa0963549536221dab7c89.css


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


File diff suppressed because it is too large
+ 0 - 0
dist/static/css/workPage.2d63977029aad3b3125729e0c03f57c6.css


File diff suppressed because it is too large
+ 0 - 0
dist/static/css/workPage.2d63977029aad3b3125729e0c03f57c6.css.map


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


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


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


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/workPage-manifest.2ece51fa34be51c8610a.js.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/workPage.41ed7956a1ce9890e002.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/workPage.41ed7956a1ce9890e002.js.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/workPage.44ce238c01aaba5b9f86.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/workPage.44ce238c01aaba5b9f86.js.map


+ 1 - 1
dist/workPage.html

@@ -1,4 +1,4 @@
-<!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1"><title>工作页面 - CocoFlow</title><link rel=icon href=../static/logo.ico><link href=./static/css/workPage.056421ef26c31f5e230cfb83ae266086.css rel=stylesheet></head><body><noscript><strong>We're sorry but this app doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app></div><script type=text/javascript src=./static/js/workPage-manifest.2ece51fa34be51c8610a.js></script><script type=text/javascript src=./static/js/workPage-vendor.e1fc95e471d70a1519e8.js></script><script type=text/javascript src=./static/js/workPage.41ed7956a1ce9890e002.js></script></body></html><script>function stopSafari() {
+<!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1"><title>工作页面 - CocoFlow</title><link rel=icon href=../static/logo.ico><link href=./static/css/workPage.2d63977029aad3b3125729e0c03f57c6.css rel=stylesheet></head><body><noscript><strong>We're sorry but this app doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app></div><script type=text/javascript src=./static/js/workPage-manifest.2ece51fa34be51c8610a.js></script><script type=text/javascript src=./static/js/workPage-vendor.e1fc95e471d70a1519e8.js></script><script type=text/javascript src=./static/js/workPage.44ce238c01aaba5b9f86.js></script></body></html><script>function stopSafari() {
     //阻止safari浏览器双击放大功能
     let lastTouchEnd = 0  //更新手指弹起的时间
     document.documentElement.addEventListener("touchstart", function (event) {

+ 11 - 1
src/components/pages/studentManageNew/component/table.vue

@@ -1671,7 +1671,7 @@ export default {
             });
             e.classname = kk.join("/");
           });
-          this.tableData = res.data[0];
+          this.tableData = this.groupByName(res.data[0] || []);
           console.log(
             JSON.parse(JSON.stringify(this.tableData)),
             "this.tableData"
@@ -1686,6 +1686,16 @@ export default {
           console.error(err);
         });
     },
+    // 拼音排序
+    groupByName(list) {
+      return [...list].sort((a, b) => {
+        const nameA = (a && a.username ? a.username : "").trim();
+        const nameB = (b && b.username ? b.username : "").trim();
+        return nameA.localeCompare(nameB, "zh-Hans-CN-u-co-pinyin", {
+          sensitivity: "base"
+        });
+      });
+    },
     // 获取兴趣班
     getInterestClass() {
       this.tab1Loading = true;

+ 21 - 22
src/components/pages/workPage/components/photo.vue

@@ -20,18 +20,10 @@
 
     <!-- 操作按钮区域 -->
     <div class="upload-area">
-      <!-- 拍照按钮 -->
-      <!-- <button class="photo-btn" @click="takePhoto" v-if="isMobile">
-        <span class="plus-icon">+</span>
-        <span>{{ lang.ssTakePhoto }}</span>
-      </button> -->
-      
-      <button class="photo-btn" @click="uploadImage">
+      <button class="photo-btn" @click="uploadImage" v-loading="uploadLoading">
         <span class="plus-icon">+</span>
         <span>{{ lang.ssTakePhoto }}</span>
       </button>
-      <!-- 上传图片按钮 -->
-      <!-- <span class="upload-btn" @click="uploadImage">{{ lang.ssContinueAddImage }}</span> -->
     </div>
   </div>
 </template>
@@ -53,7 +45,8 @@ export default {
         fileList: []
       },
       recordObj: {},
-      isMobile: false
+      isMobile: false,
+      uploadLoading: false
     };
   },
   computed: {
@@ -84,16 +77,14 @@ export default {
     }
   },
   methods: {
-    // 更新作业
     changeWorkData(newValue) {
       this.$emit("changeWorkData", JSON.stringify(newValue));
     },
-    // 拍照功能
     takePhoto() {
       const input = document.createElement('input');
       input.type = 'file';
       input.accept = 'image/*';
-      input.capture = 'environment'; // 使用后置摄像头
+      input.capture = 'environment';
       input.click();
       input.onchange = (e) => {
         if (e.target.files[0]) {
@@ -105,23 +96,32 @@ export default {
         }
       };
     },
-    // 上传图片功能
     uploadImage() {
+      if(this.uploadLoading){
+        return
+      }
       const input = document.createElement('input');
       input.type = 'file';
       input.accept = 'image/*';
+      input.multiple = true;
       input.click();
       input.onchange = (e) => {
-        if (e.target.files[0]) {
-          uploadOneFile(e.target.files[0]).then(res => {
-            res.src = res.url;
-            this.work.fileList = [...this.work.fileList, res];
+        const files = e.target.files;
+        if (files && files.length > 0) {
+          this.uploadLoading = true;
+          const uploadPromises = [];
+          for (let i = 0; i < files.length; i++) {
+            uploadPromises.push(uploadOneFile(files[i]));
+          }
+          Promise.all(uploadPromises).then(results => {
+            const newImages = results.map(res => ({ ...res, src: res.url }));
+            this.work.fileList = [...this.work.fileList, ...newImages];
+            this.uploadLoading = false;
             this.changeWorkData(this.work);
           });
         }
       };
     },
-    // 删除图片
     delImage(index) {
       this.work.fileList.splice(index, 1);
       this.changeWorkData(this.work);
@@ -160,7 +160,6 @@ export default {
   width: 100%;
 }
 
-
 .qaa_img {
   width: 100%;
   height: auto;
@@ -215,7 +214,7 @@ export default {
 .delete-text {
   margin-top: 8px;
   color: #FF2525;
-  font-size: .9rem;  
+  font-size: .9rem;
 }
 
 .upload-area {
@@ -261,4 +260,4 @@ export default {
 .upload-btn:hover {
   color: #85CE61;
 }
-</style>
+</style>

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