Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
COMP90082-ePortfolio-team03
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Tian Ye
COMP90082-ePortfolio-team03
Commits
04411fed
Commit
04411fed
authored
May 31, 2020
by
Alex Xin
Browse files
Options
Downloads
Plain Diff
Merge branch 'master' of
https://gitlab.eng.unimelb.edu.au/973651/comp90082-eportfolio-team03
parents
a0d46213
4ad4d81f
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
web/js/People/change-passward.js
+16
-20
16 additions, 20 deletions
web/js/People/change-passward.js
web/js/login_registerScripts.js
+0
-43
0 additions, 43 deletions
web/js/login_registerScripts.js
with
16 additions
and
63 deletions
web/js/People/change-passward.js
+
16
−
20
View file @
04411fed
...
@@ -69,27 +69,23 @@ function submitEditForm() {
...
@@ -69,27 +69,23 @@ function submitEditForm() {
//退出登录
//退出登录
// quitLoginClick();
// quitLoginClick();
$
.
ajax
({
$
.
confirm
({
type
:
'
post
'
,
title
:
''
,
url
:
'
LoginServlet
'
,
content
:
'
Succeffully Modify the Password !
'
,
data
:
{
autoClose
:
'
ok|3000
'
,
"
type
"
:
"
logout
"
type
:
'
green
'
,
buttons
:
{
ok
:
{
text
:
'
Yes
'
,
btnClass
:
'
btn-primary
'
,
keys
:
[
'
enter
'
,
'
a
'
],
action
:
function
()
{
//点击登录
$
(
'
#loginBtn
'
).
click
();
}
},
},
cancel
:
{
dataType
:
'
text
'
,
text
:
'
No
'
,
success
:
function
(
data
){
btnClass
:
'
btn-primary
'
,
if
(
data
==
"
logout
"
){
keys
:
[
'
ESC
'
],
window
.
location
.
href
=
"
index.html
"
;
}
else
{
alert
(
"
no user now
"
);
}
}
},
error
:
function
(
msg
)
{
alert
(
"
logout failed
"
);
console
.
log
(
msg
)
}
}
});
});
}
else
{
}
else
{
...
...
This diff is collapsed.
Click to expand it.
web/js/login_registerScripts.js
+
0
−
43
View file @
04411fed
...
@@ -184,26 +184,6 @@ function confirmToLogin(){
...
@@ -184,26 +184,6 @@ function confirmToLogin(){
});
});
}
}
// function checkLoginState(){
// var strcookie = document.cookie;
// if(strcookie==null || strcookie.length==0){
// //alert("no login");
// $("#loginbtn").show();
// $("#logout").hide();
// //$("#toHomepage").hide();
// document.getElementById("toHomepage").style.display="none";
// } else{
// var userPhotoStr = strcookie.split(";")[1];
// var userPhoto = userPhotoStr.split("=")[1];
// if(userPhoto=="null") userPhoto="https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=3439779931,834673929&fm=26&gp=0.jpg";
// $("#loginbtn").hide();
// $("#logout").show();
// //$("#toHomepage").show();
// document.getElementById("myPhoto").src = userPhoto;
// document.getElementById("toHomepage").style.display="inline";
// }
// }
function
openHomepage
(){
function
openHomepage
(){
window
.
location
.
href
=
"
person.html
"
;
window
.
location
.
href
=
"
person.html
"
;
}
}
...
@@ -228,29 +208,6 @@ function logout(){
...
@@ -228,29 +208,6 @@ function logout(){
}
}
}
}
});
});
// if(confirm("Sure to logout?")){
// $.ajax({
// type: 'post',
// url: 'LoginServlet',
// data: {
// "type": "logout"
// },
// dataType: 'text',
// success: function(data){
// if(data == "logout"){
// //window.location.href="register.jsp";
// window.location.href="index.html";
// } else{
// alert("no user now");
// }
// },
// error : function(msg) {
// alert("logout failed");
// console.log(msg)
// }
// });
// }
}
}
//Logout without confirm
//Logout without confirm
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment