Browse Source

test cookie

huaisianhuang 4 năm trước cách đây
mục cha
commit
6805a32e4b
1 tập tin đã thay đổi với 1 bổ sung0 xóa
  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') { // 英文版訊息