5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-27 00:36:22 +00:00
panel/app/views/posts/attributes/_geo.haml

24 lines
937 B
Text
Raw Permalink Normal View History

.row{ data: { controller: 'geo' } }
2020-02-16 22:51:43 +00:00
.col
.form-group
= label_tag "#{base}_#{attribute}_lat",
2020-02-16 22:51:43 +00:00
post_label_t(attribute, :lat, post: post)
= text_field(*field_name_for(base, attribute, :lat),
2020-02-16 22:51:43 +00:00
value: metadata.value['lat'],
**field_options(attribute, metadata),
data: { target: 'geo.lat' })
2020-02-16 22:51:43 +00:00
= render 'posts/attribute_feedback',
post: post, attribute: [attribute, :lat], metadata: metadata
.col
.form-group
= label_tag "#{base}_#{attribute}_lng",
2020-02-16 22:51:43 +00:00
post_label_t(attribute, :lng, post: post)
= text_field(*field_name_for(base, attribute, :lng),
2020-02-16 22:51:43 +00:00
value: metadata.value['lng'],
**field_options(attribute, metadata),
data: { target: 'geo.lng' })
2020-02-16 22:51:43 +00:00
= render 'posts/attribute_feedback',
2020-03-30 20:37:04 +00:00
post: post, attribute: [attribute, :lng], metadata: metadata
.col-12.mb-3
%div{ data: { target: 'geo.map' }, style: 'height: 250px' }