diff --git a/tools/otagui/src/components/BatchOTAOptions.vue b/tools/otagui/src/components/BatchOTAOptions.vue
new file mode 100644
index 000000000..6f3126018
--- /dev/null
+++ b/tools/otagui/src/components/BatchOTAOptions.vue
@@ -0,0 +1,96 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/tools/otagui/src/components/FileList.vue b/tools/otagui/src/components/FileList.vue
new file mode 100644
index 000000000..5b0248fec
--- /dev/null
+++ b/tools/otagui/src/components/FileList.vue
@@ -0,0 +1,73 @@
+
+ {{ label }}
+
+
+ Remove selected item
+
+
+
+
+
+
\ No newline at end of file
diff --git a/tools/otagui/src/services/JobSubmission.js b/tools/otagui/src/services/JobSubmission.js
index 4c97486f1..b14a81261 100644
--- a/tools/otagui/src/services/JobSubmission.js
+++ b/tools/otagui/src/services/JobSubmission.js
@@ -28,6 +28,37 @@ export class OTAConfiguration {
this.extra = ''
}
+ /**
+ * Take in multiple paths of target and incremental builds and generate
+ * OTA packages between them. If there are n incremental sources and m target
+ * builds, there will be n x m OTA packages in total. If there is 0
+ * incremental package, full OTA will be generated.
+ * @param {Array} targetBuilds
+ * @param {Array} incrementalSources
+ * @return Array
+ */
+ async sendForms(targetBuilds, incrementalSources = []) {
+ const responses = []
+ if (!this.isIncremental) {
+ responses.push(
+ ... await Promise.all(
+ targetBuilds.map(async (target) => await this.sendForm(target))
+ )
+ )
+ } else {
+ for (const incremental of incrementalSources) {
+ responses.push(
+ ... await Promise.all(
+ targetBuilds.map(
+ async (target) => await this.sendForm(target, incremental)
+ )
+ )
+ )
+ }
+ }
+ return responses
+ }
+
/**
* Start an OTA package generation from target build to incremental source.
* Throw an error if not succeed, otherwise will return the message from
@@ -36,14 +67,16 @@ export class OTAConfiguration {
* @param {String} incrementalSource
* @return String
*/
- async sendForm(targetBuild, incrementalSource='') {
+ async sendForm(targetBuild, incrementalSource = '') {
let jsonOptions = Object.assign({}, this)
jsonOptions.target = targetBuild
jsonOptions.incremental = incrementalSource
jsonOptions.id = uuid.v1()
for (let flag of OTAExtraFlags) {
if (jsonOptions[flag.key]) {
- jsonOptions.extra_keys.push(flag.key)
+ if (jsonOptions.extra_keys.indexOf(flag.key) === -1) {
+ jsonOptions.extra_keys.push(flag.key)
+ }
}
}
try {
diff --git a/tools/otagui/src/views/JobConfigure.vue b/tools/otagui/src/views/JobConfigure.vue
index afd7252ae..dffddd047 100644
--- a/tools/otagui/src/views/JobConfigure.vue
+++ b/tools/otagui/src/views/JobConfigure.vue
@@ -41,11 +41,13 @@