Refactor: Inbox store, remove inboxes from sidebar (#387)

* Refactor: Inbox store, remove inboxes from sidebar

* Add a new page for inbox settings

* Show inboxes on sidebar

* Add inbox_members API

* Disable similar-code check

* Fix codeclimate scss issues

* Add widget_color update API and actions

* Add specs for inbox store

* Fix Facebook auth flow

* Fix agent loading, inbox name
This commit is contained in:
Pranav Raj S
2019-12-28 21:56:42 +05:30
committed by Sojan Jose
parent 96f8070e79
commit 5ddc46c474
51 changed files with 1028 additions and 726 deletions

View File

@@ -1,109 +1,97 @@
import { frontendURL } from '../helper/URLHelper';
export default {
menuGroup: {
common: {
routes: [
'home',
'inbox_dashboard',
'inbox_conversation',
'settings_account_reports',
'billing_deactivated',
],
menuItems: {
assignedToMe: {
icon: 'ion-chatbox-working',
label: 'Conversations',
hasSubMenu: false,
key: '',
toState: frontendURL('dashboard'),
toolTip: 'Conversation from all subscribed inboxes',
toStateName: 'home',
},
report: {
icon: 'ion-arrow-graph-up-right',
label: 'Reports',
hasSubMenu: false,
toState: frontendURL('reports'),
toStateName: 'settings_account_reports',
},
settings: {
icon: 'ion-settings',
label: 'Settings',
hasSubMenu: false,
toState: frontendURL('settings'),
toStateName: 'settings_home',
},
inbox: {
icon: 'ion-folder',
label: 'Inboxes',
hasSubMenu: true,
newLink: true,
key: 'inbox',
cssClass: 'menu-title align-justify',
toState: frontendURL('settings/inboxes'),
toStateName: 'settings_inbox_list',
children: [],
},
common: {
routes: [
'home',
'inbox_dashboard',
'inbox_conversation',
'settings_account_reports',
'billing_deactivated',
],
menuItems: {
assignedToMe: {
icon: 'ion-chatbox-working',
label: 'Conversations',
hasSubMenu: false,
key: '',
toState: frontendURL('dashboard'),
toolTip: 'Conversation from all subscribed inboxes',
toStateName: 'home',
},
report: {
icon: 'ion-arrow-graph-up-right',
label: 'Reports',
hasSubMenu: false,
toState: frontendURL('reports'),
toStateName: 'settings_account_reports',
},
settings: {
icon: 'ion-settings',
label: 'Settings',
hasSubMenu: false,
toState: frontendURL('settings'),
toStateName: 'settings_home',
},
},
settings: {
routes: [
'agent_list',
'agent_new',
'canned_list',
'canned_new',
'settings_inbox',
'settings_inbox_new',
'settings_inbox_list',
'settings_inboxes_page_channel',
'settings_inboxes_add_agents',
'settings_inbox_finish',
'billing',
],
menuItems: {
back: {
icon: 'ion-ios-arrow-back',
label: 'Home',
hasSubMenu: false,
toStateName: 'home',
toState: frontendURL('dashboard'),
},
agents: {
icon: 'ion-person-stalker',
label: 'Agents',
hasSubMenu: false,
toState: frontendURL('settings/agents/list'),
toStateName: 'agent_list',
},
inboxes: {
icon: 'ion-archive',
label: 'Inboxes',
hasSubMenu: false,
toState: frontendURL('settings/inboxes/list'),
toStateName: 'settings_inbox_list',
},
cannedResponses: {
icon: 'ion-chatbox-working',
label: 'Canned Responses',
hasSubMenu: false,
toState: frontendURL('settings/canned-response/list'),
toStateName: 'canned_list',
},
billing: {
icon: 'ion-card',
label: 'Billing',
hasSubMenu: false,
toState: frontendURL('settings/billing'),
toStateName: 'billing',
},
account: {
icon: 'ion-beer',
label: 'Account Settings',
hasSubMenu: false,
toState: frontendURL('settings/account'),
toStateName: 'account',
},
},
settings: {
routes: [
'agent_list',
'agent_new',
'canned_list',
'canned_new',
'settings_inbox',
'settings_inbox_new',
'settings_inbox_list',
'settings_inbox_show',
'settings_inboxes_page_channel',
'settings_inboxes_add_agents',
'settings_inbox_finish',
'billing',
],
menuItems: {
back: {
icon: 'ion-ios-arrow-back',
label: 'Home',
hasSubMenu: false,
toStateName: 'home',
toState: frontendURL('dashboard'),
},
agents: {
icon: 'ion-person-stalker',
label: 'Agents',
hasSubMenu: false,
toState: frontendURL('settings/agents/list'),
toStateName: 'agent_list',
},
inboxes: {
icon: 'ion-archive',
label: 'Inboxes',
hasSubMenu: false,
toState: frontendURL('settings/inboxes/list'),
toStateName: 'settings_inbox_list',
},
cannedResponses: {
icon: 'ion-chatbox-working',
label: 'Canned Responses',
hasSubMenu: false,
toState: frontendURL('settings/canned-response/list'),
toStateName: 'canned_list',
},
billing: {
icon: 'ion-card',
label: 'Billing',
hasSubMenu: false,
toState: frontendURL('settings/billing'),
toStateName: 'billing',
},
account: {
icon: 'ion-beer',
label: 'Account Settings',
hasSubMenu: false,
toState: frontendURL('settings/account'),
toStateName: 'account',
},
},
},

View File

@@ -27,7 +27,8 @@
"PLACEHOLDER": "Enter your website domain (eg: acme.com)"
},
"WIDGET_COLOR": {
"LABEL": "Widget Color"
"LABEL": "Widget Color",
"PLACEHOLDER": "Update the widget color used in widget"
},
"SUBMIT_BUTTON":"Create inbox"
},
@@ -52,10 +53,11 @@
"LOADING_FB": "Authenticating you with Facebook...",
"ERROR_FB_AUTH": "Something went wrong, Please refresh page...",
"CREATING_CHANNEL": "Creating your Inbox...",
"TITLE": "Configure Inbox Deatails",
"DESC": "an addendum to this post, you can absolutely support what Im doing by working with me at Reach by Creatomic. Get in touch: jon@creatomic.co for content, podcasts, marketing campaignswe do a lot and we do it well. If you can help me hit that monthly rev. target by letting me help you find more customers and make more money, thats a win win."
"TITLE": "Configure Inbox Details",
"DESC": ""
},
"AGENTS": {
"BUTTON_TEXT": "Add agents",
"ADD_AGENTS": "Adding Agents to your Inbox..."
},
"FINISH": {
@@ -66,6 +68,12 @@
},
"REAUTH": "Reauthorize",
"VIEW": "View",
"EDIT": {
"API": {
"SUCCESS_MESSAGE": "Widget color updated successfully",
"ERROR_MESSAGE": "Could not update widget color. Please try again later."
}
},
"DELETE": {
"BUTTON_TEXT": "Delete",
"CONFIRM": {