class Bus_Driver_EditForm(r.FlaskForm): #TODO: List the fields here, FIELDS MUST BE PREFIXED WITH rgen_ # The names here after the rgen_ prefix must correspond to a var name in the respective model rgen_name = r.StringField('Renew Name',validators=[r.InputRequired(),r.Length(min=4,max=40)]) rgen_contact_no = r.StringField('Renew Contact Number',validators=[r.InputRequired(),r.Length(min=10,max=11)]) #TODO: List select fields here, FIELDS MUST BE PREFIXED WITH rgensel_ # The names here after the rgen_ prefix must correspond to a var name in the respective model fKeylist = {}
class EditForm(r.FlaskForm): rgen_long = r.StringField( 'Renew Longitude', validators=[r.InputRequired(), r.Length(min=1, max=10)]) rgen_lati = r.StringField( 'Renew Latitude', validators=[r.InputRequired(), r.Length(min=1, max=10)]) rgensel_route_id = r.SelectField('Reassigned Route', choices=[('0', 'No link')]) #rgentim_time = r.DateField('New T-stamp', widget=r.DatePickerWidget(),default=r.datetime.datetime.now()) fKeylist = {"route_id": ("Georoute", "name")}
class Truck_EditForm(r.FlaskForm): #TODO: List the fields here, FIELDS MUST BE PREFIXED WITH rgen_ # The names here after the rgen_ prefix must correspond to a var name in the respective model rgen_long = r.StringField( 'Renew Longitude', validators=[r.InputRequired(), r.Length(min=1, max=10)]) rgen_lati = r.StringField( 'Renew Latitude', validators=[r.InputRequired(), r.Length(min=1, max=10)]) #TODO: List select fields here, FIELDS MUST BE PREFIXED WITH rgensel_ # The names here after the rgen_ prefix must correspond to a var name in the respective model fKeylist = {}
class EditForm(r.FlaskForm): rgen_name = r.StringField('Renew Georoute Name', validators=[ r.InputRequired(), r.Length(min=1, max=r.lim.MAX_USERNAME_SIZE) ]) fKeylist = {}
class Bus_AddForm(r.FlaskForm): #TODO: List the fields here, FIELDS MUST BE PREFIXED WITH rgen_ # The names here after the rgen_ prefix must correspond to a var name in the respective model rgen_reg_no = r.StringField('New Registered Number',validators=[r.InputRequired(),r.Length(min=1,max=10)]) #TODO: List select fields here, FIELDS MUST BE PREFIXED WITH rgensel_ # The names here after the rgen_ prefix must correspond to a var name in the respective model fKeylist = {}
class AddForm(r.FlaskForm): #TODO: List the fields here, FIELDS MUST BE PREFIXED WITH rgen_ # The names here after the rgen_ prefix must correspond to a var name in the respective model rgen_long = r.StringField( 'New Longitude', validators=[r.InputRequired(), r.Length(min=1, max=10)]) rgen_lati = r.StringField( 'New Latitude', validators=[r.InputRequired(), r.Length(min=1, max=10)]) #sample datepicker widget (allows date selection), use the rgentim_ prefix rgentim_time = r.DateField('T stamp', widget=r.DatePickerWidget(), default=r.datetime.datetime.now()) #TODO: List select fields here, FIELDS MUST BE PREFIXED WITH rgensel_ # The names here after the rgen_ prefix must correspond to a var name in the respective model rgensel_route_id = r.SelectField('Assigned Route', choices=[('0', 'No route')]) fKeylist = {"route_id": ("Georoute", "name")}