This commit is contained in:
@@ -64,18 +64,28 @@ app.ravLicense = (function () {
|
||||
});
|
||||
|
||||
var submitData = app.utilB.objectifyFormDataArray(formData);
|
||||
//do features separately, above can't deal with multi select and we need to add schedtechs anyway
|
||||
let features = [];
|
||||
features.push({
|
||||
Feature: "ServiceTechs",
|
||||
Count: Number($("#techcount").val())
|
||||
});
|
||||
let options = $("#options").val();
|
||||
|
||||
//clean up the data before submit
|
||||
debugger;
|
||||
for (let i = 0; i < options.length; i++) {
|
||||
features.push({ Feature: options[i], Count: 0 });
|
||||
}
|
||||
|
||||
submitData["features"]=features;
|
||||
//submit
|
||||
// alert("STUB submit");
|
||||
// alert("STUB submit");
|
||||
app.api.createRavLicense(submitData, function (res) {
|
||||
if (res.error) {
|
||||
$.gevent.publish('app-show-error', res.msg);
|
||||
} else {
|
||||
$('#key').val(res);
|
||||
return false;
|
||||
}
|
||||
if (res.error) {
|
||||
$.gevent.publish("app-show-error", res.msg);
|
||||
} else {
|
||||
$("#key").val(res);
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
return false; //prevent default
|
||||
|
||||
Reference in New Issue
Block a user