Velocipede's User, Sales, and Bike Inventory Web App
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

56 lines
2.1 KiB

= top_menu link_to_dashboard
%h1 Add Time Entry
- time = Time.now
- date_format, time_format = '%m/%d/%Y', '%l:%M %p'
- mjs_date_format, mjs_time_format = 'MM/DD/YYYY', 'h:mm A'
.row
.col-xs-12.col-sm-6.col-lg-4
%fieldset
.form-group.form-inline
= text_field_tag nil, time.strftime(date_format), id: 'date_id', placeholder: 'Date', class: 'form-control',
size: 12, data: {format: mjs_date_format}
.help-block
.form-group.timepickers.form-inline
.form-group
%label.visible-xs Start time
= text_field_tag nil, time.strftime(time_format), id: 'start_time_id', placeholder: 'Start time',
class: 'form-control', size: 8, data: {format: mjs_time_format}
.hidden#start_date
.help-block
.form-group.dash.hidden-xs
—
.form-group
%label.visible-xs End time
= text_field_tag nil, time.strftime(time_format), id: 'end_time_id', placeholder: 'End time',
class: 'form-control', size: 8, data: {format: mjs_time_format}
.hidden#end_date
.help-block
.form-group
.btn-group(data-toggle="buttons")
%label.btn.btn-default
= radio_button_tag 'action_id', 1, false, autocomplete: 'off'
Volunteer
%label.btn.btn-default
= radio_button_tag 'action_id', 2, false, autocomplete: 'off'
Personal
%label.btn.btn-default
= radio_button_tag 'action_id', 3, false, autocomplete: 'off'
Staff
.hidden#log_action_id
.help-block
.form-group
= select_tag :bike_id, options_for_select(@bikes), class: 'form-control'
.form-group
= text_area_tag nil, nil, id: 'description_id', placeholder: 'Work description', class: 'form-control', rows: 5
.control-group
.controls
= button_tag 'Add Time Entry', id: 'add_time_entry_submit', class: 'btn btn-primary', data: {url: api_create_time_entry_path, forward: '.'}