mirror of
https://github.com/docusealco/docuseal.git
synced 2026-06-23 04:10:11 +00:00
queue page field detection
This commit is contained in:
@@ -953,6 +953,7 @@ export default {
|
||||
isLoadingBlankPage: false,
|
||||
isSaving: false,
|
||||
isDetectingPageFields: false,
|
||||
detectFieldsQueue: [],
|
||||
detectingAnalyzingProgress: null,
|
||||
detectingFieldsAddedCount: null,
|
||||
selectedSubmitter: null,
|
||||
@@ -2783,6 +2784,12 @@ export default {
|
||||
})
|
||||
},
|
||||
detectFieldsForPage ({ page, attachmentUuid }) {
|
||||
if (this.isDetectingPageFields) {
|
||||
this.detectFieldsQueue.push({ page, attachmentUuid })
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
this.isDetectingPageFields = true
|
||||
this.detectingAnalyzingProgress = null
|
||||
this.detectingFieldsAddedCount = null
|
||||
@@ -2968,6 +2975,10 @@ export default {
|
||||
setTimeout(() => {
|
||||
this.detectingFieldsAddedCount = null
|
||||
}, 1000)
|
||||
|
||||
if (this.detectFieldsQueue.length) {
|
||||
this.detectFieldsForPage(this.detectFieldsQueue.shift())
|
||||
}
|
||||
})
|
||||
},
|
||||
save ({ force } = { force: false }) {
|
||||
|
||||
Reference in New Issue
Block a user