diff --git a/src/components/flow/routers/ticket/TicketRouterForm.module.scss b/src/components/flow/routers/ticket/TicketRouterForm.module.scss index a53bf8d5d..831a1a591 100644 --- a/src/components/flow/routers/ticket/TicketRouterForm.module.scss +++ b/src/components/flow/routers/ticket/TicketRouterForm.module.scss @@ -4,6 +4,6 @@ margin-top: 8px; } -.body { +.note { margin-top: 8px; } \ No newline at end of file diff --git a/src/components/flow/routers/ticket/TicketRouterForm.tsx b/src/components/flow/routers/ticket/TicketRouterForm.tsx index bfcfb295a..13f5cc06b 100644 --- a/src/components/flow/routers/ticket/TicketRouterForm.tsx +++ b/src/components/flow/routers/ticket/TicketRouterForm.tsx @@ -25,7 +25,7 @@ export interface TicketRouterFormState extends FormState { assignee: FormEntry; topic: FormEntry; subject: StringEntry; - body: StringEntry; + note: StringEntry; resultName: StringEntry; } @@ -51,7 +51,7 @@ export default class TicketRouterForm extends React.Component< assignee?: User; topic?: Topic; subject?: string; - body?: string; + note?: string; resultName?: string; }, submitting = false @@ -74,8 +74,8 @@ export default class TicketRouterForm extends React.Component< updates.subject = validate(i18n.t('forms.subject', 'Subject'), keys.subject, []); } - if (keys.hasOwnProperty('body')) { - updates.body = validate(i18n.t('forms.body', 'Body'), keys.body, []); + if (keys.hasOwnProperty('note')) { + updates.note = validate(i18n.t('forms.note', 'Note'), keys.note, []); } if (keys.hasOwnProperty('resultName')) { @@ -103,8 +103,8 @@ export default class TicketRouterForm extends React.Component< return this.handleUpdate({ subject }, submitting); } - private handleBodyUpdate(body: string): boolean { - return this.handleUpdate({ body }); + private handleNoteUpdate(note: string): boolean { + return this.handleUpdate({ note }); } private handleResultNameUpdate(value: string): void { @@ -124,7 +124,7 @@ export default class TicketRouterForm extends React.Component< const valid = this.handleUpdate( { subject: this.state.subject.value, - body: this.state.body.value, + note: this.state.note.value, resultName: this.state.resultName.value }, true @@ -185,12 +185,12 @@ export default class TicketRouterForm extends React.Component< /> -
+
diff --git a/src/components/flow/routers/ticket/__snapshots__/TicketRouterForm.test.tsx.snap b/src/components/flow/routers/ticket/__snapshots__/TicketRouterForm.test.tsx.snap index 8dbee494b..a7769f928 100644 --- a/src/components/flow/routers/ticket/__snapshots__/TicketRouterForm.test.tsx.snap +++ b/src/components/flow/routers/ticket/__snapshots__/TicketRouterForm.test.tsx.snap @@ -96,7 +96,7 @@ exports[`TicketRouterForm render should render 1`] = `
@@ -275,7 +275,7 @@ exports[`TicketRouterForm updates should save changes 1`] = `
diff --git a/src/components/flow/routers/ticket/helpers.ts b/src/components/flow/routers/ticket/helpers.ts index 6f3ed9dcf..9ed17e0a8 100644 --- a/src/components/flow/routers/ticket/helpers.ts +++ b/src/components/flow/routers/ticket/helpers.ts @@ -19,7 +19,7 @@ export const getOriginalAction = (settings: NodeEditorSettings): OpenTicket => { export const nodeToState = (settings: NodeEditorSettings): TicketRouterFormState => { let subject = { value: '@run.flow.name' }; - let body = { value: '' }; + let note = { value: '' }; let resultName = { value: 'Result' }; let assignee: FormEntry = { value: null }; let topic: FormEntry = { value: null }; @@ -27,7 +27,7 @@ export const nodeToState = (settings: NodeEditorSettings): TicketRouterFormState if (getType(settings.originalNode) === Types.split_by_ticket) { const action = getOriginalAction(settings) as OpenTicket; subject = { value: action.subject }; - body = { value: action.body }; + note = { value: action.body }; topic = { value: action.topic }; assignee = { value: action.assignee }; resultName = { value: action.result_name }; @@ -37,7 +37,7 @@ export const nodeToState = (settings: NodeEditorSettings): TicketRouterFormState assignee, topic, subject, - body, + note, resultName, valid: true }; @@ -58,7 +58,7 @@ export const stateToNode = ( const newAction: OpenTicket = { uuid, type: Types.open_ticket, - body: state.body.value, + body: state.note.value, topic: state.topic.value, assignee: state.assignee.value, result_name: state.resultName.value diff --git a/src/config/i18n/cs/resource.json b/src/config/i18n/cs/resource.json index ae7b5c0f7..b3590e8ba 100644 --- a/src/config/i18n/cs/resource.json +++ b/src/config/i18n/cs/resource.json @@ -217,7 +217,7 @@ "email_recipient_name": "Příjemce", "email_recipient_placeholder": "Komu", "email_recipient_prompt": "Zadejte e-mailovou adresu", - "enter_a_body": "Zadejte obsah zprávy", + "enter_a_note": "Zadejte poznámku (volitelný)", "enter_a_subject": "Zadejte předmět", "enter_a_url": "Zadejte URL", "enter_field_value": "Zadejte novou hodnotu pro [[field]]", @@ -250,6 +250,7 @@ "minimum_value": "Minimální hodnota", "must_be_less_than": "musí být menší než", "name": "Název", + "note": "Poznámku", "operand": "Operand", "operator": "operátor", "pdf_url": "URL adresa PDF dokumentu", diff --git a/src/config/i18n/defaults.json b/src/config/i18n/defaults.json index 68b599539..b064de1b5 100644 --- a/src/config/i18n/defaults.json +++ b/src/config/i18n/defaults.json @@ -217,7 +217,7 @@ "email_recipient_name": "Recipient", "email_recipient_placeholder": "To", "email_recipient_prompt": "Enter email address", - "enter_a_body": "Enter a body (optional)", + "enter_a_note": "Enter a note (optional)", "enter_a_subject": "Enter a subject", "enter_a_url": "Enter a URL", "enter_field_value": "Enter a new value for [[field]]", @@ -250,6 +250,7 @@ "minimum_value": "Minimum value", "must_be_less_than": "must be less than", "name": "Name", + "note": "Note", "operand": "Operand", "operator": "operator", "pdf_url": "PDF Document URL", diff --git a/src/config/i18n/es/resource.json b/src/config/i18n/es/resource.json index f23c94fb4..e610cd6dc 100644 --- a/src/config/i18n/es/resource.json +++ b/src/config/i18n/es/resource.json @@ -217,7 +217,7 @@ "email_recipient_name": "Destinatario", "email_recipient_placeholder": "Para", "email_recipient_prompt": "Introducir la dirección de correo electrónico", - "enter_a_body": "Introducir cuerpo (opcional)", + "enter_a_note": "Introducir nota (opcional)", "enter_a_subject": "Introducir asunto", "enter_a_url": "Introducir URL", "enter_field_value": "Ingrese un nuevo valor para [[field]]", @@ -250,6 +250,7 @@ "minimum_value": "Valor mínimo", "must_be_less_than": "debe ser menor que", "name": "Nombre", + "note": "Nota", "operand": "Operando", "operator": "operador", "pdf_url": "URL de Documento PDF", diff --git a/src/config/i18n/fr/resource.json b/src/config/i18n/fr/resource.json index d766d7158..f3cf24be0 100644 --- a/src/config/i18n/fr/resource.json +++ b/src/config/i18n/fr/resource.json @@ -217,7 +217,7 @@ "email_recipient_name": "Bénéficiaire", "email_recipient_placeholder": "À", "email_recipient_prompt": "Entrer l'adresse e-mail", - "enter_a_body": "Entrez un corps", + "enter_a_note": "Entrez une note (facultatif)", "enter_a_subject": "Entrez un sujet", "enter_a_url": "Entrez une URL", "enter_field_value": "Enter a new value for [[field]]", @@ -250,6 +250,7 @@ "minimum_value": "Valeur minimum", "must_be_less_than": "doit être inférieur à", "name": "Nom", + "note": "Note", "operand": "Opérande", "operator": "opérateur", "pdf_url": "PDF Document URL", diff --git a/src/config/i18n/mn/resource.json b/src/config/i18n/mn/resource.json index df7b6766f..71c50140a 100644 --- a/src/config/i18n/mn/resource.json +++ b/src/config/i18n/mn/resource.json @@ -217,7 +217,7 @@ "email_recipient_name": "Хүлээн авагч", "email_recipient_placeholder": "руу", "email_recipient_prompt": "Имэйл хаягаа оруулна уу", - "enter_a_body": "Их биеийг оруулна уу", + "enter_a_note": "Тэмдэглэл оруулна уу", "enter_a_subject": "Сэдвийг оруулна уу", "enter_a_url": "URL оруулна уу", "enter_field_value": "[[field]]-д шинэ утга оруулна уу", @@ -250,6 +250,7 @@ "minimum_value": "Хамгийн бага утга", "must_be_less_than": "-аас бага байх ёстой", "name": "Нэр", + "note": "тэмдэглэл", "operand": "Операнд", "operator": "оператор", "pdf_url": "PDF баримт бичгийн URL", diff --git a/src/config/i18n/pt-br/resource.json b/src/config/i18n/pt-br/resource.json index e0d76e443..f63da8b59 100644 --- a/src/config/i18n/pt-br/resource.json +++ b/src/config/i18n/pt-br/resource.json @@ -217,7 +217,7 @@ "email_recipient_name": "Destinatário", "email_recipient_placeholder": "Para", "email_recipient_prompt": "Insira o endereço de email", - "enter_a_body": "Insira um corpo", + "enter_a_note": "Insira uma nota (opcional)", "enter_a_subject": "Insira um assunto", "enter_a_url": "Insira um URL", "enter_field_value": "Insira um novo valor para [[field]]", @@ -250,6 +250,7 @@ "minimum_value": "Valor mínimo", "must_be_less_than": "deve ser menor que", "name": "Nome", + "note": "Nota", "operand": "Operando", "operator": "operador", "pdf_url": "PDF Document URL",