Rende usabili i filtri destinatari e permette di eliminare le bozze email.
Le listbox non applicavano sport e altri criteri; ora i filtri sono checkbox, c'è «mai contattati» e dal cruscotto si cancellano le bozze. La lista organizzazioni allinea le colonne al foglio campagna. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -3,17 +3,27 @@ import { Controller } from "@hotwired/stimulus"
|
||||
export default class extends Controller {
|
||||
static targets = ["intent"]
|
||||
|
||||
disconnect() {
|
||||
clearTimeout(this.refreshTimer)
|
||||
}
|
||||
|
||||
refresh() {
|
||||
this.persistOpenSections()
|
||||
this.setIntent("preview")
|
||||
this.element.requestSubmit()
|
||||
clearTimeout(this.refreshTimer)
|
||||
this.refreshTimer = setTimeout(() => this.submitPreview(), 250)
|
||||
}
|
||||
|
||||
apply() {
|
||||
clearTimeout(this.refreshTimer)
|
||||
this.persistOpenSections()
|
||||
this.setIntent("apply")
|
||||
}
|
||||
|
||||
submitPreview() {
|
||||
this.persistOpenSections()
|
||||
this.setIntent("preview")
|
||||
this.element.requestSubmit()
|
||||
}
|
||||
|
||||
persistOpenSections() {
|
||||
this.element.querySelectorAll("input[data-open-section]").forEach((input) => input.remove())
|
||||
this.element.querySelectorAll("details[data-section]").forEach((details) => {
|
||||
|
||||
Reference in New Issue
Block a user