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 8 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