[MA] labaled options

Lukas Renggli renggli at iam.unibe.ch
Fri Apr 13 09:08:55 MEST 2007


> Consider that I have an option selector that is addable - there are a
> set set of options, plus the user can add his own.  I'll have to do a
> database query to come up with the available set of options and it
> will vary.  How will this work?

Create (or update) your description dynamically on the instance side:

Address>>description
	^ super description copy
		add: ((MASingleOptionDescription auto: 'country' label: 'Country')
  			optionsAndLabels: self superComplicatedQuery;
			default: #fr;
			beRequired;
   			yourself);
		yourself

Lukas

-- 
Lukas Renggli
http://www.lukas-renggli.ch




More information about the smallwiki mailing list