lsc il y a 2 ans
Parent
commit
52be2a69d8

+ 1 - 1
dist/index.html

@@ -25,4 +25,4 @@
       height: 100%;
       width: 100%;
       background: #e6eaf0;
-    }</style><link href=./static/css/app.ffa842f1e85cc2655aefa1654bb013f7.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.3512a67a6213c2df4180.js></script><script type=text/javascript src=./static/js/vendor.e8eb4c1cc481dbb543fc.js></script><script type=text/javascript src=./static/js/app.3f451a4734fd3ff98b50.js></script></body></html><script>document.domain = document.domain.split(".").slice(-2).join(".");</script>
+    }</style><link href=./static/css/app.9f7c0ab8e086bb07b0fa865e5d0dde28.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.3512a67a6213c2df4180.js></script><script type=text/javascript src=./static/js/vendor.e8eb4c1cc481dbb543fc.js></script><script type=text/javascript src=./static/js/app.21b748ecff94a6d13c2d.js></script></body></html><script>document.domain = document.domain.split(".").slice(-2).join(".");</script>

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
dist/static/css/app.9f7c0ab8e086bb07b0fa865e5d0dde28.css


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
dist/static/css/app.9f7c0ab8e086bb07b0fa865e5d0dde28.css.map


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
dist/static/css/app.ffa842f1e85cc2655aefa1654bb013f7.css.map


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
dist/static/js/app.21b748ecff94a6d13c2d.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
dist/static/js/app.21b748ecff94a6d13c2d.js.map


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
dist/static/js/app.3f451a4734fd3ff98b50.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
dist/static/js/manifest.3512a67a6213c2df4180.js.map


+ 1 - 1
src/components/pages/Grid.vue

@@ -749,7 +749,7 @@ export default {
             _this.progress = parseInt((evt.loaded * 80) / evt.total);
           })
           .send(function (err, data) {
-            this.progress = 100;
+            _this.progress = 100;
             setTimeout(() => {
               _this.proVisible = false;
             }, 1000);

+ 64 - 4
src/components/pages/library.vue

@@ -1,5 +1,5 @@
 <template>
-  <div class="pb_content" style="overflow: auto;">
+  <div class="pb_content" style="overflow: auto">
     <div class="pb_head top">
       <span>素材库</span>
       <div v-if="choose == 0" @click="addImg($event)">
@@ -142,6 +142,19 @@
         style="width: 100%; height: 100%"
       ></video-player>
     </el-dialog>
+    <div v-if="proVisible" class="mask">
+      <div class="progressBox">
+        <div class="lbox">
+          <img :src="require('../../assets/loading.gif')" />上传中,请稍后
+        </div>
+        <el-progress
+          :text-inside="true"
+          :stroke-width="20"
+          :percentage="progress"
+          style="width: 80%"
+        ></el-progress>
+      </div>
+    </div>
   </div>
 </template>
 
@@ -189,6 +202,8 @@ export default {
         },
       },
       playerO: {},
+      proVisible: false,
+      progress: 0,
     };
   },
   methods: {
@@ -218,14 +233,15 @@ export default {
 
       var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
       var _this = this;
-
+      _this.progress = 0;
+      _this.proVisible = true;
       if (file) {
         var params = {
           Key:
             file.name.split(".")[0] +
             new Date().getTime() +
             "." +
-            file.name.split(".")[file.name.split(".").length-1],
+            file.name.split(".")[file.name.split(".").length - 1],
           ContentType: file.type,
           Body: file,
           "Access-Control-Allow-Credentials": "*",
@@ -241,8 +257,13 @@ export default {
           .on("httpUploadProgress", function (evt) {
             //这里可以写进度条
             // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+            _this.progress = parseInt((evt.loaded * 80) / evt.total);
           })
           .send(function (err, data) {
+            _this.progress = 100;
+            setTimeout(() => {
+              _this.proVisible = false;
+            }, 1000);
             if (err) {
               var a = _this.$refs.upload1.uploadFiles;
               a.splice(a.length - 1, a.length);
@@ -291,7 +312,7 @@ export default {
             file.name.split(".")[0] +
             new Date().getTime() +
             "." +
-            file.name.split(".")[file.name.split(".").length-1],
+            file.name.split(".")[file.name.split(".").length - 1],
           ContentType: file.type,
           Body: file,
           "Access-Control-Allow-Credentials": "*",
@@ -513,4 +534,43 @@ export default {
   flex-wrap: wrap;
   min-height: 250px;
 }
+
+.mask {
+  background-color: rgba(0, 0, 0, 0);
+  position: fixed;
+  top: 0;
+  left: 0;
+  width: 100%;
+  height: 100%;
+  z-index: 20000;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+.progressBox {
+  width: 500px;
+  height: 180px;
+  background: #fff;
+  border-radius: 10px;
+  box-shadow: 0 0 6px 1px #bfbfbf;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  flex-direction: column;
+}
+.progressBox .lbox {
+  height: 100px;
+  font-size: 19px;
+  display: flex;
+  align-items: center;
+}
+
+.progressBox .lbox img {
+  width: 40px;
+  margin-right: 20px;
+}
+
+.progressBox >>> .el-progress-bar__outer {
+  background-color: #d1dfff !important;
+}
 </style>

+ 60 - 1
src/components/pages/libraryGM.vue

@@ -142,6 +142,19 @@
         style="width: 100%; height: 100%"
       ></video-player>
     </el-dialog>
+    <div v-if="proVisible" class="mask">
+      <div class="progressBox">
+        <div class="lbox">
+          <img :src="require('../../assets/loading.gif')" />上传中,请稍后
+        </div>
+        <el-progress
+          :text-inside="true"
+          :stroke-width="20"
+          :percentage="progress"
+          style="width: 80%"
+        ></el-progress>
+      </div>
+    </div>
   </div>
 </template>
 
@@ -189,6 +202,8 @@ export default {
         },
       },
       playerO: {},
+      proVisible: false,
+      progress: 0,
     };
   },
   methods: {
@@ -218,7 +233,8 @@ export default {
 
       var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
       var _this = this;
-
+      _this.progress = 0;
+      _this.proVisible = true;
       if (file) {
         var params = {
           Key:
@@ -241,8 +257,13 @@ export default {
           .on("httpUploadProgress", function (evt) {
             //这里可以写进度条
             // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+            _this.progress = parseInt((evt.loaded * 80) / evt.total);
           })
           .send(function (err, data) {
+            _this.progress = 100;
+            setTimeout(() => {
+              _this.proVisible = false;
+            }, 1000);
             if (err) {
               var a = _this.$refs.upload1.uploadFiles;
               a.splice(a.length - 1, a.length);
@@ -525,4 +546,42 @@ export default {
   color: #5c549f;
 }
 
+.mask {
+  background-color: rgba(0, 0, 0, 0);
+  position: fixed;
+  top: 0;
+  left: 0;
+  width: 100%;
+  height: 100%;
+  z-index: 20000;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+.progressBox {
+  width: 500px;
+  height: 180px;
+  background: #fff;
+  border-radius: 10px;
+  box-shadow: 0 0 6px 1px #bfbfbf;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  flex-direction: column;
+}
+.progressBox .lbox {
+  height: 100px;
+  font-size: 19px;
+  display: flex;
+  align-items: center;
+}
+
+.progressBox .lbox img {
+  width: 40px;
+  margin-right: 20px;
+}
+
+.progressBox >>> .el-progress-bar__outer {
+  background-color: #d1dfff !important;
+}
 </style>

Certains fichiers n'ont pas été affichés car il y a eu trop de fichiers modifiés dans ce diff