Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Next »

 

Description

Submit buttons are aesthetically similar to normal buttons but their behaviour differs from normal buttons with respect to the following:

  • They allow data captured on the view to be submitted to a unit
  • They do not allow for usage without an action function binding

 

 

Example

View XML
<textarea label="input.workout_comments">
	<binding variable="uWorkout">
		<attribute name="comments"/>
	</binding>
</textarea>
 
<submit label="button.save_workout" action="saveWorkout"/>
Backing unit
unit Workouts;
 
Workout uWorkout;
 
void init() {
	uWorkout = Workout:new();
}
 
.
.
.
 
DSL_VIEWS saveWorkout() {
	uWorkout.endTstamp = Date:now();
	uWorkout.save();
	return DSL_VIEWS.Workouts;
}
en.lang file entry
button.save_workout = Save workout

 

 

 

Additional Mentions and References

 

 

  • No labels

0 Comments

You are not logged in. Any changes you make will be marked as anonymous. You may want to Log In if you already have an account.