Re: Django Template Based If Statement Issue

2014-05-12 Thread donarb
On Monday, May 12, 2014 3:37:47 PM UTC-7, G Z wrote: > > ok its still not putting out the vm data i get > > > Grant - google.com - 7029855378 - zuk...@gmail.com - 2332 > oakland st > - - > > > {% for customer in customers %} > {{ customer.NAME }} - {{ customer.W

Re: Django Template Based If Statement Issue

2014-05-12 Thread G Z
> > ok its still not putting out the vm data i get Grant - google.com - 7029855378 - zuk...@gmail.com - 2332 oakland st - - {% for customer in customers %} {{ customer.NAME }} - {{ customer.WEBSITE }} - {{customer.PHONE}} - {{ customer.EMAIL }} - {{ customer.

Re: Django Template Based If Statement Issue

2014-05-12 Thread G Z
this is my models from django.db import models # Create your models here. class Customer(models.Model): NAME = models.CharField(max_length=200) WEBSITE = models.CharField(max_length=200) PHONE = models.CharField(max_length=200) EMAIL = models.CharField(max_length=200) ADDRES

Re: Django Template Based If Statement Issue

2014-05-12 Thread G Z
also thank you so much for your help. On Monday, May 12, 2014 4:00:27 PM UTC-6, Tom Evans wrote: > > On Mon, May 12, 2014 at 10:47 PM, G Z > > wrote: > > I'm just trying to associate each vm tied to the customers id and > display > > the vms under the customer that are associated with his id.

Re: Django Template Based If Statement Issue

2014-05-12 Thread Tom Evans
On Mon, May 12, 2014 at 10:47 PM, G Z wrote: > I'm just trying to associate each vm tied to the customers id and display > the vms under the customer that are associated with his id. > Normally, you would have some sort of relationship between those models, and the template code would look someth

Re: Django Template Based If Statement Issue

2014-05-12 Thread G Z
so as you can see when ever the vm field customer id matches the customers name i want to display the vm with the customer. To create a table of vms that each customer has. I also will be associating a third database with vmspecs to each vm. I know there is an easier way to do this with django

Re: Django Template Based If Statement Issue

2014-05-12 Thread G Z
I'm just trying to associate each vm tied to the customers id and display the vms under the customer that are associated with his id. On Monday, May 12, 2014 3:02:34 PM UTC-6, G Z wrote: > > Views.py > > > from django.shortcuts import render > from django.http import HttpResponse > from vmware.mo

Re: Django Template Based If Statement Issue

2014-05-12 Thread Tom Evans
On Mon, May 12, 2014 at 10:02 PM, G Z wrote: > Views.py > > > from django.shortcuts import render > from django.http import HttpResponse > from vmware.models import Customer > from django.shortcuts import render_to_response > from vmware.models import Vms > > def index(request): > customer