v30495092 fix attribute href

This commit is contained in:
2019-01-11 02:33:01 +01:00
parent 06ab23bdca
commit e8da6536d9
3 changed files with 46 additions and 30 deletions
+1 -1
View File
@@ -1,4 +1,4 @@
/*Generated on:Fri Jan 11 2019 02:21:48 GMT+0100 (CET)*/ /*Generated on:Fri Jan 11 2019 02:33:00 GMT+0100 (CET)*/
var AutomaticDispose_Branch = "master"; var AutomaticDispose_Branch = "master";
var AutomaticDispose_URL = "https://jf.git.rest/Jomaar/automatic-dispose/raw/branch/"; var AutomaticDispose_URL = "https://jf.git.rest/Jomaar/automatic-dispose/raw/branch/";
var da_lss_adis_time = new Date().getTime(); var da_lss_adis_time = new Date().getTime();
+15 -7
View File
@@ -1,4 +1,4 @@
/*Generated on:Fri Jan 11 2019 02:21:48 GMT+0100 (CET)*/ /*Generated on:Fri Jan 11 2019 02:33:00 GMT+0100 (CET)*/
/* /*
* Dexie.js - a minimalistic wrapper for IndexedDB * Dexie.js - a minimalistic wrapper for IndexedDB
* =============================================== * ===============================================
@@ -18819,27 +18819,35 @@ class AutomaticDispose {
CollectInvolvedVehicles() { CollectInvolvedVehicles() {
let self = this; let self = this;
$("#mission_vehicle_driving tbody").find("tr").each(function (_, elem) { $("#mission_vehicle_driving tbody").find("tr").each(function (_, elem) {
var VehicleID = $(elem).find("a").first().attr("href").substr($(elem).find("a").first().attr("href").lastIndexOf("/") + 1); var f = $(elem).find("a").first()
var VehicleName = $(elem).find("a").first().text(); var attr = f.attr("href")
var VehicleType = $(elem).find("a").first().attr("vehicle_type_id"); if (typeof attr !== 'undefined' && attr !== false) {
var VehicleID = f.attr("href").substr(f.attr("href").lastIndexOf("/") + 1);
var VehicleName = f.text();
var VehicleType = f.attr("vehicle_type_id");
self.Vehicles[VehicleID] = { self.Vehicles[VehicleID] = {
"id": VehicleID, "id": VehicleID,
"name": VehicleName, "name": VehicleName,
"type": VehicleType "type": VehicleType
} }
}
}); });
$("#mission_vehicle_at_mission tbody").find("tr").each(function (_, elem) { $("#mission_vehicle_at_mission tbody").find("tr").each(function (_, elem) {
var VehicleID = $(elem).find("a").first().attr("href").substr($(elem).find("a").first().attr("href").lastIndexOf("/") + 1); var f = $(elem).find("a").first()
var VehicleName = $(elem).find("a").first().text(); var attr = f.attr("href")
var VehicleType = $(elem).find("a").first().attr("vehicle_type_id"); if (typeof attr !== 'undefined' && attr !== false) {
var VehicleID = f.attr("href").substr(f.attr("href").lastIndexOf("/") + 1);
var VehicleName = f.text();
var VehicleType = f.attr("vehicle_type_id");
self.Vehicles[VehicleID] = { self.Vehicles[VehicleID] = {
"id": VehicleID, "id": VehicleID,
"name": VehicleName, "name": VehicleName,
"type": VehicleType "type": VehicleType
} }
}
}); });
return self.Vehicles; return self.Vehicles;
+14 -6
View File
@@ -1465,27 +1465,35 @@ class AutomaticDispose {
CollectInvolvedVehicles() { CollectInvolvedVehicles() {
let self = this; let self = this;
$("#mission_vehicle_driving tbody").find("tr").each(function (_, elem) { $("#mission_vehicle_driving tbody").find("tr").each(function (_, elem) {
var VehicleID = $(elem).find("a").first().attr("href").substr($(elem).find("a").first().attr("href").lastIndexOf("/") + 1); var f = $(elem).find("a").first()
var VehicleName = $(elem).find("a").first().text(); var attr = f.attr("href")
var VehicleType = $(elem).find("a").first().attr("vehicle_type_id"); if (typeof attr !== 'undefined' && attr !== false) {
var VehicleID = f.attr("href").substr(f.attr("href").lastIndexOf("/") + 1);
var VehicleName = f.text();
var VehicleType = f.attr("vehicle_type_id");
self.Vehicles[VehicleID] = { self.Vehicles[VehicleID] = {
"id": VehicleID, "id": VehicleID,
"name": VehicleName, "name": VehicleName,
"type": VehicleType "type": VehicleType
} }
}
}); });
$("#mission_vehicle_at_mission tbody").find("tr").each(function (_, elem) { $("#mission_vehicle_at_mission tbody").find("tr").each(function (_, elem) {
var VehicleID = $(elem).find("a").first().attr("href").substr($(elem).find("a").first().attr("href").lastIndexOf("/") + 1); var f = $(elem).find("a").first()
var VehicleName = $(elem).find("a").first().text(); var attr = f.attr("href")
var VehicleType = $(elem).find("a").first().attr("vehicle_type_id"); if (typeof attr !== 'undefined' && attr !== false) {
var VehicleID = f.attr("href").substr(f.attr("href").lastIndexOf("/") + 1);
var VehicleName = f.text();
var VehicleType = f.attr("vehicle_type_id");
self.Vehicles[VehicleID] = { self.Vehicles[VehicleID] = {
"id": VehicleID, "id": VehicleID,
"name": VehicleName, "name": VehicleName,
"type": VehicleType "type": VehicleType
} }
}
}); });
return self.Vehicles; return self.Vehicles;