aboutsummaryrefslogtreecommitdiffstats
path: root/www/js
diff options
context:
space:
mode:
authorStruan Donald <struan@exo.org.uk>2012-11-29 13:46:08 +0000
committerStruan Donald <struan@exo.org.uk>2012-11-29 16:10:40 +0000
commit7f71dfd76cb4399f26f65960eb851dcd65831b86 (patch)
tree7a93c0d582ac016ea85d08e6cded91155431676f /www/js
parentbd76c5a63bf951bb213845626cc071a712b2fd25 (diff)
allow report to reset values
Diffstat (limited to 'www/js')
-rw-r--r--www/js/report.js24
1 files changed, 12 insertions, 12 deletions
diff --git a/www/js/report.js b/www/js/report.js
index 43af05a..4b1761a 100644
--- a/www/js/report.js
+++ b/www/js/report.js
@@ -8,22 +8,22 @@ function Report(spec) {
may_show_name: '',
category: '',
phone: '',
- pc: '',
+ pc: ''
};
return {
id: function() { return my_id; },
- lat: function(lat) { if ( lat ) { props.lat = lat; } return props.lat; },
- lon: function(lon) { if ( lon ) { props.lon = lon; } return props.lon; },
- title: function(title) { if ( title ) { props.title = title; } return props.title; },
- detail: function(detail) { if ( detail ) { props.detail = detail; } return props.detail; },
- category: function(category) { if ( category ) { props.category = category; } return props.category; },
- phone: function(phone) { if ( phone ) { props.phone = phone; } return props.phone; },
- pc: function(pc) { if ( pc ) { props.pc = pc; } return props.pc; },
- may_show_name: function(may_show_name) { if ( may_show_name ) { props.may_show_name = may_show_name; } return props.may_show_name; },
- file: function(file) { if ( file ) { props.file = file; } return props.file; },
- name: function(name) { if ( name ) { props.name = name; } return props.name; },
- email: function(email) { if ( email ) { props.email = email; } return props.email; },
+ lat: function(lat) { if ( typeof lat !== 'undefined' ) { props.lat = lat; } return props.lat; },
+ lon: function(lon) { if ( typeof lon !== 'undefined' ) { props.lon = lon; } return props.lon; },
+ title: function(title) { if ( typeof title !== 'undefined' ) { props.title = title; } return props.title; },
+ detail: function(detail) { if ( typeof detail !== 'undefined' ) { props.detail = detail; } return props.detail; },
+ category: function(category) { if ( typeof category !== 'undefined' ) { props.category = category; } return props.category; },
+ phone: function(phone) { if ( typeof phone !== 'undefined' ) { props.phone = phone; } return props.phone; },
+ pc: function(pc) { if ( typeof pc !== 'undefined' ) { props.pc = pc; } return props.pc; },
+ may_show_name: function(may_show_name) { if ( typeof may_show_name !== 'undefined' ) { props.may_show_name = may_show_name; } return props.may_show_name; },
+ file: function(file) { if ( typeof file !== 'undefined' ) { props.file = file; } return props.file; },
+ name: function(name) { if ( typeof name !== 'undefined' ) { props.name = name; } return props.name; },
+ email: function(email) { if ( typeof email !== 'undefined' ) { props.email = email; } return props.email; },
getLastUpdate: function(time) {
if ( time ) {
props.time = time;