-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
page-rangefinders.vugu
44 lines (40 loc) · 2.11 KB
/
page-rangefinders.vugu
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<div>
<main:TitleBar>
<span class="w3-bar-item w3-large" vg-content='fmt.Sprintf("%d Rangefinders", len(c.Site.Rangefinders))'></span>
<button class="w3-bar-item w3-button w3-right w3-large w3-ripple w3-teal" @click="c.handleAdd()"><i class="fas fa-plus"></i></button>
</main:TitleBar>
<div class="w3-container">
<ul class="w3-ul w3-card">
<li vg-for="_, rangefinder := range c.Site.RangefindersSorted()" class="w3-bar">
<span @click="rangefinder.Delete()" class="w3-bar-item w3-button w3-large w3-right"><i class="far fa-trash-alt"></i></span>
<span @click='c.Navigate("/rangefinder/" + rangefinder.Key(), nil)' class="w3-bar-item w3-button w3-large w3-right"><i class="far fa-edit"></i></span>
<div class="w3-bar-item">
<span class="w3-large" vg-content="rangefinder.Name"></span>
<span vg-content="rangefinder.Key()"></span><br>
</div>
<div class="w3-container">
<span class="w3-large">Measurements</span>
<ul class="w3-ul w3-card">
<li vg-for="_, measurement := range rangefinder.MeasurementsSorted()" class="w3-bar">
<span @click="measurement.Delete()" class="w3-bar-item w3-button w3-large w3-right"><i class="far fa-trash-alt"></i></span>
<span @click='c.Navigate("/rangefinder/" + rangefinder.Key() + "/measurement/" + measurement.Key(), nil)' class="w3-bar-item w3-button w3-large w3-right"><i class="far fa-edit"></i></span>
<div class="w3-bar-item">
<main:PointViewComponent :Width="150" :Height="100" :Site="c.Site" :PointKey="measurement.P1"></main:PointViewComponent>
</div>
<div class="w3-bar-item">
<main:PointViewComponent :Width="150" :Height="100" :Site="c.Site" :PointKey="measurement.P2"></main:PointViewComponent>
</div>
<div class="w3-bar-item">
<div class="w3-large" vg-content="measurement.Key()"></div><br>
<div vg-content='fmt.Sprintf("SSR: %.4f", measurement.ResidualSqr())'></div>
<div vg-content='fmt.Sprintf("Dist: %.4f", measurement.MeasuredDistance)'></div>
</div>
</li>
</ul>
</div>
</li>
</ul>
</div>
</div>
<script type="application/x-go">
</script>