Re: Re: WOPopUpButton
Lawrence Kendall <[email protected]>
| Newsgroups | gmane.comp.web.webobjects.newbies |
|---|---|
| Message-ID | <[email protected]> |
No Problem....
Yes.... I would have another table in the database. I assume you are
using EOModel?? In EOModel, add a new entity and enter the field names
I described before. In your database (DB) add your table and the
fields.
Once you have added this table, add the priceTypeID field to the
product entity and make a relationship between them. Make sure you
also add the priceTypeID to the Product table in the DB.
Once you have entered your data in the DB (EDU - Education etc) then
just hook it up. All Good!! ;)
I can send you some screen grabs if you need extra help. Let me know
how you go.
Cheers then,
Larry.
On 10/02/2005, at 5:39 PM, madamimadamtimallen wrote:
Does this mean I would need to have another table in my database or can
I create it
putting all the data into the application?
Thanks for responding by the way
> The way I would do this is to set up an entity in my model called
> "PriceType" or something.
>
> PriceType would contain an ID plus two fields, "longName" and
> "shortName".
>
> In your component have a priceTypeDisplayGroup and an
itemForPriceType.
>
> Your WOPopUpButton should have the following keys filled in:
>
> displayString = itemForPriceType.shortName
> item = itemForPriceType
> list = pricTypeDisplayGroup.displayedObjects
> noSelectionString = "-Please Select-"
> selection = productDetailDisplayGroup.queryMatch.priceType
>
> That's it.
>
> Cheers then,
>
> Larry.
>
> ~~~~~~~~~~~~~~~~~~~~~~~~
>
> I forgot to mention....
>
> add a relationship to your product entity, so your Product entity
will
> have a "priceTpyeID" field and you connect that to the ID in the
> PriceType entity.
>
> Therefore, your selection key on the WOPopUpButton should be:
>
> selection = productDisplayGroup.queryMatch.pricetype
>
> Cheers then,
>
> Larry.
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/webobjects-newbies/
<*> To unsubscribe from this group, send an email to:
[email protected]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/