Skip to content

Commit

Permalink
added: voice-twilio action category
Browse files Browse the repository at this point in the history
  • Loading branch information
Gabriele Panico committed Nov 28, 2024
1 parent 55cb5fb commit 1a02673
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

<div class="box-dw" [class.previewMode]="previewMode">

<div class="reply-info" *ngIf="typeAction === typeActions.RANDOM_REPLY">{{actionList.RANDOM_REPLY.description | translate }}</div>
<div class="reply-info" *ngIf="typeAction === typeActions.RANDOM_REPLY">{{actionList.RANDOM_REPLY.doc+'.DESCRIPTION' | translate }}</div>

<div #scrollMe id="scrollMe"
class="content draggable-list"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

<div class="box-dw" [class.previewMode]="previewMode">

<div class="reply-info" *ngIf="typeAction === typeActions.RANDOM_REPLY">{{actionList.RANDOM_REPLY.description | translate }}</div>
<div class="reply-info" *ngIf="typeAction === typeActions.RANDOM_REPLY">{{actionList.RANDOM_REPLY.doc+'.DESCRIPTION' | translate }}</div>

<div #scrollMe id="scrollMe"
class="content draggable-list"
Expand Down
13 changes: 11 additions & 2 deletions src/app/chatbot-design-studio/utils-actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ export enum TYPE_ACTION_CATEGORY {
INTEGRATIONS = 'Integrations',
SPECIAL = 'Special',
NEW = 'New',
VOICE = 'Voice'
VOICE = 'Voice',
"VOICE-TWILIO" = 'Voice Twilio'
}

export const ACTION_CATEGORY =[
Expand All @@ -73,6 +74,7 @@ export const ACTION_CATEGORY =[
{ type: getKeyByValue(TYPE_ACTION_CATEGORY.INTEGRATIONS, TYPE_ACTION_CATEGORY), name: 'CDSActionCategory.Integrations', src: 'assets/images/actions_category/integrations.svg'},
{ type: getKeyByValue(TYPE_ACTION_CATEGORY.SPECIAL, TYPE_ACTION_CATEGORY), name: 'CDSActionCategory.Special', src: 'assets/images/actions_category/special.svg'},
{ type: getKeyByValue(TYPE_ACTION_CATEGORY.VOICE, TYPE_ACTION_CATEGORY), name: 'CDSActionCategory.Voice', src: 'assets/images/actions_category/voice.svg'},
{ type: getKeyByValue(TYPE_ACTION_CATEGORY['VOICE-TWILIO'], TYPE_ACTION_CATEGORY), name: 'CDSActionCategory.VoiceTwilio', src: 'assets/images/actions_category/voice.svg'},
// { type: getKeyByValue(TYPE_ACTION_CATEGORY.NEW, TYPE_ACTION_CATEGORY), name: TYPE_ACTION_CATEGORY.NEW, src: 'assets/images/actions_category/new.svg'}
]

Expand Down Expand Up @@ -132,6 +134,13 @@ export const ACTIONS_LIST: {[key: string]: {name: string, category: TYPE_ACTION_
BLIND_TRANSFER: { name: 'CDSActionList.NAME.BlindTransfer', category: TYPE_ACTION_CATEGORY.VOICE, type: TYPE_ACTION_VXML.BLIND_TRANSFER, src:"assets/images/actions-voice/blind_transfer.svg", status: "active", plan: PLAN_NAME.F, doc: "" },
PLAY_PROMPT: { name: 'CDSActionList.NAME.PlayPrompt', category: TYPE_ACTION_CATEGORY.VOICE, type: TYPE_ACTION_VXML.PLAY_PROMPT, src:"assets/images/actions-voice/play_prompt.svg", status: "active", plan: PLAN_NAME.F, doc: "" },
SPEECH_FORM: { name: 'CDSActionList.NAME.SpeechForm', category: TYPE_ACTION_CATEGORY.VOICE, type: TYPE_ACTION_VXML.SPEECH_FORM, src:"assets/images/actions-voice/speech_form.svg", status: "active", plan: PLAN_NAME.F, doc: "" },
AUDIO_RECORD: { name: 'CDSActionList.NAME.AudioRecord', category: TYPE_ACTION_CATEGORY.VOICE, type: TYPE_ACTION_VXML.AUDIO_RECORD, src:"assets/images/actions-voice/audio_record.svg", status: "active", plan: PLAN_NAME.F, doc: "" }
AUDIO_RECORD: { name: 'CDSActionList.NAME.AudioRecord', category: TYPE_ACTION_CATEGORY.VOICE, type: TYPE_ACTION_VXML.AUDIO_RECORD, src:"assets/images/actions-voice/audio_record.svg", status: "active", plan: PLAN_NAME.F, doc: "" },

DFTM_FORM_TWILIO: { name: 'CDSActionList.NAME.DTMFForm', category: TYPE_ACTION_CATEGORY['VOICE-TWILIO'], type: TYPE_ACTION_VXML.DTMF_FORM, src:"assets/images/actions-voice/dtmf_form.svg", status: "active", plan: PLAN_NAME.F, doc: "" },
DTMF_MENU_TWILIO: { name: 'CDSActionList.NAME.DTMFMenu', category: TYPE_ACTION_CATEGORY['VOICE-TWILIO'], type: TYPE_ACTION_VXML.DTMF_MENU, src:"assets/images/actions-voice/dtmf_menu.svg", status: "active", plan: PLAN_NAME.F, doc: "" },
BLIND_TRANSFER_TWILIO: { name: 'CDSActionList.NAME.BlindTransfer', category: TYPE_ACTION_CATEGORY['VOICE-TWILIO'], type: TYPE_ACTION_VXML.BLIND_TRANSFER, src:"assets/images/actions-voice/blind_transfer.svg", status: "active", plan: PLAN_NAME.F, doc: "" },
PLAY_PROMPT_TWILIO: { name: 'CDSActionList.NAME.PlayPrompt', category: TYPE_ACTION_CATEGORY['VOICE-TWILIO'], type: TYPE_ACTION_VXML.PLAY_PROMPT, src:"assets/images/actions-voice/play_prompt.svg", status: "active", plan: PLAN_NAME.F, doc: "" },
SPEECH_FORM_TWILIO: { name: 'CDSActionList.NAME.SpeechForm', category: TYPE_ACTION_CATEGORY['VOICE-TWILIO'], type: TYPE_ACTION_VXML.SPEECH_FORM, src:"assets/images/actions-voice/speech_form.svg", status: "active", plan: PLAN_NAME.F, doc: "" },

}

1 change: 1 addition & 0 deletions src/app/utils/project-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ export class ProjectPlanUtils {
this.project = this.projectService.getCurrentProject();
this.checkIfKBSCanLoad();
this.checkIfActionCategoryIsInProject(TYPE_ACTION_CATEGORY.VOICE);
this.checkIfActionCategoryIsInProject(TYPE_ACTION_CATEGORY['VOICE-TWILIO']);
this.checkActionCanShow(TYPE_ACTION.CONNECT_BLOCK)
}

Expand Down
3 changes: 2 additions & 1 deletion src/assets/i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -543,7 +543,8 @@
"Flow":"Flow",
"Integrations":"Integrations",
"Special":"Special",
"Voice":"Voice"
"Voice":"Voice",
"VoiceTwilio":"Voice Twilio"
},
"CDSOperatorList":{
"equalAsNumbers":"equal As Numbers",
Expand Down

0 comments on commit 1a02673

Please sign in to comment.