2018-06-15 11:03:24 -04:00
|
|
|
import AdminEmailIncomingsController from "admin/controllers/admin-email-incomings";
|
|
|
|
import debounce from "discourse/lib/debounce";
|
|
|
|
import IncomingEmail from "admin/models/incoming-email";
|
2016-01-18 18:57:55 -05:00
|
|
|
|
|
|
|
export default AdminEmailIncomingsController.extend({
|
|
|
|
filterIncomingEmails: debounce(function() {
|
2018-06-15 11:03:24 -04:00
|
|
|
IncomingEmail.findAll(this.get("filter")).then(incomings =>
|
|
|
|
this.set("model", incomings)
|
|
|
|
);
|
2016-01-18 18:57:55 -05:00
|
|
|
}, 250).observes("filter.{from,to,subject,error}")
|
|
|
|
});
|