deason пре 1 година
родитељ
комит
9c4b5d355d
1 измењених фајлова са 7 додато и 1 уклоњено
  1. 7 1
      src/main/resources/templates/login.ftlh

+ 7 - 1
src/main/resources/templates/login.ftlh

@@ -49,7 +49,7 @@
         methods: {
             doLogin() {
                 let url = "${base}/login?domain=" + this.domain + ".ecs.qmth.com.cn&loginName="
-                    + this.loginName + "&password=" + this.password;
+                    + this.encodeStr(this.loginName) + "&password=" + this.encodeStr(this.password);
 
                 axios.post(url).then((response) => {
                     this.$notify({
@@ -64,6 +64,12 @@
                         type: "error",
                     });
                 });
+            },
+            encodeStr(value) {
+                if (value) {
+                    return encodeURIComponent(value);
+                }
+                return "";
             }
         }
     });