-
Notifications
You must be signed in to change notification settings - Fork 30
Recovery Reporting Changes #400
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
a167ff2
7c11aa7
998449e
f53635e
bdbef47
89a9494
ccf1a76
0748bdf
5807193
062df3c
44500a2
24c5e13
5e137ec
fa7df9c
a6b488a
bb8c937
cbcba07
d94cf11
be6fc00
ba0174a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
…nd handling of planned tag
- Loading branch information
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -4699,8 +4699,17 @@ function updateRecoveryMarker(recovery) { | |
|
|
||
| div = document.createElement('div'); | ||
|
|
||
| _recovered_text = recovery.recovered ? " Recovered" : " Not Recovered"; | ||
|
|
||
| // Override text is planned field exists and is true | ||
| if(recovery.hasOwnProperty('planned')){ | ||
| if(recovery.planned == true){ | ||
| _recovered_text = " Recovery Planned"; | ||
| } | ||
| } | ||
|
|
||
| html = "<div style='line-height:16px;position:relative;'>"; | ||
| html += "<div><b>"+recovery.serial+(recovery.recovered ? " Recovered" : " Not Recovered")+"</b></div>"; | ||
|
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. and here |
||
| html += "<div><b>"+recovery.serial+_recovered_text+"</b></div>"; | ||
| html += "<hr style='margin:5px 0px'>"; | ||
| html += "<div style='margin-bottom:5px;'><b><i class='icon-location'></i> </b>"+format_coordinates(recovery.lat, recovery.lon, recovery.serial)+"</div>"; | ||
|
|
||
|
|
@@ -4755,6 +4764,7 @@ function updateRecoveryMarker(recovery) { | |
| recovery.recovered = r[i].recovered; | ||
| recovery.description = r[i].description; | ||
| recovery.datetime = r[i].datetime; | ||
| recovery.planned = r[i].planned; | ||
| recovery.fresh = true; | ||
| updateRecoveryMarker(recovery); | ||
|
|
||
|
|
@@ -4808,8 +4818,17 @@ function updateRecoveryPane(r){ | |
| recoveries[r_index] = {marker: null, infobox: null}; | ||
| } | ||
|
|
||
| _recovered_text = r[i].recovered ? " Recovered by " : " Not Recovered by "; | ||
|
|
||
| // Override text is planned field exists and is true | ||
| if(r[i].hasOwnProperty('planned')){ | ||
| if(r[i].planned == true){ | ||
| _recovered_text = " Recovery Planned by "; | ||
| } | ||
| } | ||
|
|
||
| html += "<div style='line-height:16px;position:relative;'>"; | ||
| html += "<div><b><u>"+r[i].serial+(r[i].recovered ? " Recovered by " : " Not Recovered by ")+r[i].recovered_by+"</u></b></div>"; | ||
| html += "<div><b><u>"+r[i].serial+(_recovered_text)+r[i].recovered_by+"</u></b></div>"; | ||
|
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. same xss here |
||
| html += "<div style='margin-bottom:5px;'><b><button style='margin-bottom:0px;' onclick='panToRecovery(\"" + r[i].serial + "\")'><i class='icon-location'></i></button> </b>"+format_coordinates(lat, lon, r[i].serial)+"</div>"; | ||
|
|
||
| var imp = offline.get('opt_imperial'); | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -195,7 +195,16 @@ function drawHistorical (data, station) { | |
| html += "<hr style='margin:0px;margin-top:5px'>"; | ||
|
|
||
| if (recovered) { | ||
| html += "<div><b>"+(recovery_info.recovered ? "Recovered by " : "Not Recovered by ")+recovery_info.recovered_by+"</u></b></div>"; | ||
| _recovered_text = recovery_info.recovered ? "Recovered by " : "Not Recovered by "; | ||
|
||
|
|
||
| // Override text is planned field exists and is true | ||
| if(recovery_info.hasOwnProperty('planned')){ | ||
| if(recovery_info.planned == true){ | ||
| _recovered_text = "Recovery Planned by "; | ||
| } | ||
| } | ||
|
|
||
| html += "<div><b>"+(_recovered_text)+recovery_info.recovered_by+"</u></b></div>"; | ||
| html += "<div><b>Recovery time: </b>"+formatDate(stringToDateUTC(recovery_info.datetime))+"</div>"; | ||
| html += "<div><b>Recovery location: </b>"+recovery_info.position[1]+", "+recovery_info.position[0] + "</div>"; | ||
| html += "<div><b>Recovery notes: </b>"+recovery_info.description+"</div>"; | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove commented out code
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done