From: Yasin Date: Thu, 19 Sep 2013 12:30:30 +0000 (+0200) Subject: Reg:Warning Msg added, MyAccount: delete,download in progess. Css: common css moved... X-Git-Tag: myslice-0.2-3~6^2~2 X-Git-Url: http://git.onelab.eu/?p=myslice.git;a=commitdiff_plain;h=58e9556fdd0693e331a25d13517a7244349ebc27 Reg:Warning Msg added, MyAccount: delete,download in progess. Css: common css moved to onelab.css --- diff --git a/portal/accountview.py b/portal/accountview.py index 5671b51c..35b52097 100644 --- a/portal/accountview.py +++ b/portal/accountview.py @@ -132,16 +132,15 @@ def account_process(request): private_key = k.as_pem() private_key = ''.join(private_key.split()) public_key = "ssh-rsa " + public_key - print "testing" # Saving to DB keypair = '{"user_public_key":"'+ public_key + '", "user_private_key":"'+ private_key + '"}' # keypair = re.sub("\r", "", keypair) # keypair = re.sub("\n", "\\n", keypair) # #keypair = keypair.rstrip('\r\n') # keypair = ''.join(keypair.split()) - user_params = { 'config': keypair} + user_params = { 'config': keypair, 'auth_type':'managed'} manifold_update_account(request,user_params) - return HttpResponse('Success: New Keypair Generated! %s' % keypair) + return HttpResponse('Success: New Keypair Generated!') elif 'upload_key' in request.POST: up_file = request.FILES['pubkey'] @@ -155,12 +154,12 @@ def account_process(request): #file_content = re.sub("\n", "\\n",file_content) file_content = ''.join(file_content.split()) # update manifold account table - user_params = { 'config': file_content} + user_params = { 'config': file_content, 'auth_type':'user'} manifold_update_account(request,user_params) - return HttpResponse('Success: Publickey uploaded! Old records overwritten') + return HttpResponse('Success: Publickey uploaded! Please delegate your credentials using SFA: http://trac.myslice.info/wiki/DelegatingCredentials') else: return HttpResponse('Please upload a valid RSA public key [.txt or .pub].') else: - message = 'You submitted an empty form.' + message = 'Under Construction.' return HttpResponse(message) diff --git a/portal/static/css/account_view_html.css b/portal/static/css/account_view_html.css index dd77998d..cd6e478f 100644 --- a/portal/static/css/account_view_html.css +++ b/portal/static/css/account_view_html.css @@ -146,14 +146,6 @@ code { /***** Notifications *****/ -.warning { - border: 1px solid red; - margin: 20px 60px; - padding: 10px 20px; - color: red; - background-color: #f2dbdb; - text-align: center; -} .warning2 { border: 1px solid red; margin: 20px 60px; diff --git a/portal/static/css/onelab.css b/portal/static/css/onelab.css index 70418c0b..b11396c3 100644 --- a/portal/static/css/onelab.css +++ b/portal/static/css/onelab.css @@ -14,3 +14,13 @@ div.onelab-title{ background-color: #e0f0f0; } +/***** Notifications *****/ +.warning { + border: 1px solid red; + margin: 20px 60px; + padding: 10px 20px; + color: red; + background-color: #f2dbdb; + text-align: center; +} + diff --git a/portal/templates/account-view.html b/portal/templates/account-view.html index 4e97f9d7..346c41f8 100644 --- a/portal/templates/account-view.html +++ b/portal/templates/account-view.html @@ -1,6 +1,7 @@ {% extends "layout-unfold1.html" %} {% block head %} + diff --git a/portal/templates/registration_view.html b/portal/templates/registration_view.html index 7e1c1d7b..2589961a 100644 --- a/portal/templates/registration_view.html +++ b/portal/templates/registration_view.html @@ -1,6 +1,6 @@ {% extends "layout-unfold1.html" %} -{% block head %} +{% block head %} @@ -77,17 +77,20 @@

Retype the password

- + + +

Account Delegation: Automatic (Recommended)