* feat: add per-inbox signature management - Introduced `InboxSignature` model to manage signatures specific to each inbox. - Added API endpoints for fetching, creating, updating, and deleting inbox signatures. - Updated UI components to support inbox-specific signatures, including overrides for signature position and separator. - Implemented a new composable `useInboxSignatures` for managing inbox signatures in the frontend. - Enhanced existing components to utilize inbox signatures, including the reply box and message signature settings. - Added tests for the new inbox signatures functionality, ensuring proper behavior of the API and model validations. - Updated translations for new UI elements related to inbox signatures. * feat: implement inbox access validation and add related tests * feat: enhance inbox signatures fetching and management logic
26 lines
473 B
JavaScript
26 lines
473 B
JavaScript
/* global axios */
|
|
|
|
const API_BASE = '/api/v1/profile/inbox_signatures';
|
|
|
|
export default {
|
|
getAll(accountId) {
|
|
return axios.get(API_BASE, {
|
|
params: { account_id: accountId },
|
|
});
|
|
},
|
|
|
|
get(inboxId) {
|
|
return axios.get(`${API_BASE}/${inboxId}`);
|
|
},
|
|
|
|
upsert(inboxId, params) {
|
|
return axios.put(`${API_BASE}/${inboxId}`, {
|
|
inbox_signature: params,
|
|
});
|
|
},
|
|
|
|
delete(inboxId) {
|
|
return axios.delete(`${API_BASE}/${inboxId}`);
|
|
},
|
|
};
|