On 6/6/07, Bryan Veloso <[EMAIL PROTECTED]> wrote:
>
> Alright, example model:
>
> # Baseball
> baseball = models.PositiveIntegerField('Baseball Skill Level',
> blank=True, null=True, maxlength=4)
> baseball_approved = models.BooleanField('Approved', default=False)
> baseball_proof = models.ImageField('Proof', upload_to="/images/proof/
> baseball", height_field='baseball_height',
> width_field='baseball_width', blank=True)
> baseball_width = models.IntegerField(blank=True, null=True,
> editable=False)
> baseball_height = models.IntegerField(blank=True, null=True,
> editable=False)
>
> Workflow is this:
>
> 1) Person inputs score.
> 2) Score isn't "valid" (meaning it won't show up on standings) if
> 'baseball_approved' is false. In order for the score to be approved,
> they have to upload an image.
> 3) Person uploads an image.
> 4) 'baseball_approved' is marked true.
>
> So, I'm thinking you need to play with views or signals or something
> to do this. Any guidance?

I think you need to work on your workflow a little more. You will
definitely need to play with views; I'm not sure what you think
signals will acheive.

You need to think in terms of "what HTML pages can I present to the
user, in what order; and what conditions must be met to move from page
1 to page 2".

The other red flag that is waving to me is the 'baseball_approved'
attribute. From the description of your workflow, it isn't obvious
that you actually want to/need to store unapproved objects in the
database. If you don't need to, drop that flag, and just refrain from
saving the model until you have an 'approvable' set of data.

Yours,
Russ Magee %-)

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to