Browse Source

test cookie

huaisianhuang 3 years ago
parent
commit
6805a32e4b
1 changed files with 1 additions and 0 deletions
  1. 1 0
      html/login.js

+ 1 - 0
html/login.js

@@ -55,6 +55,7 @@ function login(){
         data: data
     }).then(res => {
         console.log(res.data);
+        document.cookie = 'jwt_token='+res.data.access_token;
         if(res.data.access_token!=null) {
             var title = "登入成功";
             if (lang == 'en') { // 英文版訊息