2019-08-14 09:48:44 +00:00
|
|
|
/* global axios */
|
|
|
|
|
2019-10-27 05:18:26 +00:00
|
|
|
import ApiClient from './ApiClient';
|
2019-08-14 09:48:44 +00:00
|
|
|
|
2019-10-27 05:18:26 +00:00
|
|
|
class CannedResponse extends ApiClient {
|
|
|
|
constructor() {
|
2020-03-09 17:57:10 +00:00
|
|
|
super('canned_responses', { accountScoped: true });
|
2019-10-27 05:18:26 +00:00
|
|
|
}
|
2019-08-14 09:48:44 +00:00
|
|
|
|
2019-10-27 05:18:26 +00:00
|
|
|
get({ searchKey }) {
|
|
|
|
const url = searchKey ? `${this.url}?search=${searchKey}` : this.url;
|
|
|
|
return axios.get(url);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export default new CannedResponse();
|