Add name field i beta program
This commit is contained in:
		
					parent
					
						
							
								9c2c0e9a73
							
						
					
				
			
			
				commit
				
					
						80ecb963b3
					
				
			
		
					 6 changed files with 38 additions and 4 deletions
				
			
		
							
								
								
									
										21
									
								
								datacenterlight/migrations/0005_betaaccess_name.py
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								datacenterlight/migrations/0005_betaaccess_name.py
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,21 @@ | ||||||
|  | # -*- coding: utf-8 -*- | ||||||
|  | # Generated by Django 1.9.4 on 2017-03-31 00:38 | ||||||
|  | from __future__ import unicode_literals | ||||||
|  | 
 | ||||||
|  | from django.db import migrations, models | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | class Migration(migrations.Migration): | ||||||
|  | 
 | ||||||
|  |     dependencies = [ | ||||||
|  |         ('datacenterlight', '0004_betaaccessvm'), | ||||||
|  |     ] | ||||||
|  | 
 | ||||||
|  |     operations = [ | ||||||
|  |         migrations.AddField( | ||||||
|  |             model_name='betaaccess', | ||||||
|  |             name='name', | ||||||
|  |             field=models.CharField(default='name', max_length=250), | ||||||
|  |             preserve_default=False, | ||||||
|  |         ), | ||||||
|  |     ] | ||||||
|  | @ -14,6 +14,7 @@ class BetaAccessVMType(models.Model): | ||||||
| 
 | 
 | ||||||
| class BetaAccess(models.Model): | class BetaAccess(models.Model): | ||||||
|     email = models.CharField(max_length=250) |     email = models.CharField(max_length=250) | ||||||
|  |     name = models.CharField(max_length=250) | ||||||
|     # vm = models.ForeignKey(BetaAccessVM) |     # vm = models.ForeignKey(BetaAccessVM) | ||||||
| 
 | 
 | ||||||
|     def __str__(self): |     def __str__(self): | ||||||
|  |  | ||||||
|  | @ -228,3 +228,6 @@ a#forgotpassword { | ||||||
|     background-color: #607D8B; |     background-color: #607D8B; | ||||||
|     border-color: #607D8B; |     border-color: #607D8B; | ||||||
| } | } | ||||||
|  | .form-300{ | ||||||
|  |     width: 300px; | ||||||
|  | } | ||||||
										
											
												File diff suppressed because one or more lines are too long
											
										
									
								
							|  | @ -46,10 +46,15 @@ | ||||||
|                         </div> |                         </div> | ||||||
|                     {% endfor %} |                     {% endfor %} | ||||||
|                     <p class="total">At a monthly total of <span id="valueTotal">0</span>chf per day</p> |                     <p class="total">At a monthly total of <span id="valueTotal">0</span>chf per day</p> | ||||||
|                     <div class="form-group row email align-items-center"> |                     <div class="form-group"> | ||||||
|                         <label for="example-email-input" class="col-form-label">You can reach me at</label> |                         <label for="example-email-input" class="col-form-label">You can reach me at</label> | ||||||
|                         <div> |                         <div  class="form-group form-300"> | ||||||
|                             <input class="form-control" name="email" type="email" placeholder="email" id="example-email-input"> |                             <label for="email" class="col-form-label">Email</label> | ||||||
|  |                             <input class="form-control" name="email" type="email" placeholder="Your email" id="example-email-input"> | ||||||
|  |                         </div> | ||||||
|  |                          <div  class="form-group form-300"> | ||||||
|  |                             <label for="name" class="col-form-label">Name</label> | ||||||
|  |                             <input class="form-control" name="name" type="text" placeholder="Your name" id="name"> | ||||||
|                         </div> |                         </div> | ||||||
|                     </div> |                     </div> | ||||||
|                     <div class="notice"> |                     <div class="notice"> | ||||||
|  |  | ||||||
|  | @ -40,6 +40,7 @@ class BetaProgramView(CreateView): | ||||||
|         context = { |         context = { | ||||||
|             'base_url': "{0}://{1}".format(self.request.scheme, self.request.get_host()), |             'base_url': "{0}://{1}".format(self.request.scheme, self.request.get_host()), | ||||||
|             'email': data.get('email'), |             'email': data.get('email'), | ||||||
|  |             'name': data.get('name'), | ||||||
|             'vms': vms |             'vms': vms | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue