Changeset 018bce2 for src/webapp/webclient/js/main.js
- Timestamp:
- Aug 8, 2017, 11:23:36 AM (9 years ago)
- Branches:
- debian/bullseye, debian/jessie
- Children:
- 9aa387f
- Parents:
- a68d628 (diff), 24d4504 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - File:
-
- 1 moved
-
src/webapp/webclient/js/main.js (moved) (moved from src/webapp/webclient/javascript/main.js ) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/webapp/webclient/js/main.js
ra68d628 r018bce2 121 121 } 122 122 123 function uploadMap(form) 124 { 125 $.ajax({ 126 type: "POST", 127 url: "../webservice/mapupload.php", 128 data: $(form).serialize(), 129 success: function(data){ 130 if(("error" in data) && data["error"] == 1){ 131 alert("Failed to upload map: "+ data["errormessage"]); 132 return; 133 } 134 alert("Map upload successfully"); 135 }, 136 error: function(jqXHR, exception, errorThrown){ alert("Failed to upload map: "+ exception); } 137 }); 138 } 139 140 123 141 $(document).ready(function() { 124 142 displayDataGet(); … … 127 145 $.getJSON("../webservice/tileserver.php?/map.json", mapSetup); 128 146 129 $("#shutdownButton").click(shutdown); 147 $("shutdown").click(shutdown); 148 149 $("#mapTileUpload").validate({ 150 rules: { 151 mapFile: { 152 required: true 153 } 154 }, 155 submitHandler: function(form){ 156 uploadMap(form); 157 } 158 }); 130 159 });
Note:
See TracChangeset
for help on using the changeset viewer.
