]> git.openstreetmap.org Git - rails.git/blob - app/views/changeset/list_bbox.rhtml
Add 'history' tab + Move 'recent changes' changeset list to re-use the same _changese...
[rails.git] / app / views / changeset / list_bbox.rhtml
1 <h1>History</h1>
2 <%
3 if @bbox!=nil
4         lon1 = @bbox[0] 
5         lat1 = @bbox[1] 
6         lon2 = @bbox[2]
7         lat2 = @bbox[3] 
8
9         %>
10 <p>
11 Changsets within the area: 
12 (<a href='/?lat=<%= lat1 %>&lon=<%= lon1 %>&zoom=14'><%= format("%0.3f",lat1) -%>,<%= format("%0.3f",lon1) -%></a>) to 
13 (<a href='/?lat=<%= lat2 %>&lon=<%= lon2 %>&zoom=14'><%= format("%0.3f",lat2) -%>,<%= format("%0.3f",lon2) -%></a>)   
14 </p>
15
16 <%      if @edits.nil? or @edits.empty? %>
17 <p><b>No changesets</b></p>
18 <%      else %>
19
20 <%= render :partial => 'changeset_paging_nav' %>
21
22 <table id="keyvalue" cellpadding="3">
23   <tr>
24     <th>ID</th>
25     <th>Saved at</th>
26     <th>User</th>
27     <th>Comment</th>
28     <th>Area</th>
29     <th></th>
30   </tr>
31   <%= render :partial => 'changeset', :locals => {:showusername => true}, :collection => @edits unless @edits.nil? %>
32 </table>
33
34 <%= render :partial => 'changeset_paging_nav' %>
35
36 <%
37         end
38
39 else 
40         #bbox is nil. happens if the user surfs to this page directly.
41 %>
42
43 <p>No area specified</p>
44 <p>First use the <a href="/" title="view the map">view tab</a> to pan and zoom to an area of interest, then click the history tab</p>
45
46 <%
47 end
48 %>
49 <br>
50 <br>