From 4c29fe114cded0837969712559c1fc76f79b401e Mon Sep 17 00:00:00 2001 From: megavrilinvv Date: Fri, 2 Dec 2022 12:57:53 +0300 Subject: [PATCH] =?UTF-8?q?[WIP]=20=D0=98=D1=81=D0=BF=D1=80=D0=B0=D0=B2?= =?UTF-8?q?=D0=B8=D0=BB=20=D0=BD=D0=B0=D0=B7=D0=B2=D0=B0=D0=BD=D0=B8=D0=B5?= =?UTF-8?q?=20=D0=90=D0=B4=D1=80=D0=B5=D1=81=20=D0=B8=20=D1=83=D0=B2=D0=B5?= =?UTF-8?q?=D0=B4=D0=BE=D0=BC=D0=BB=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BF=D1=80?= =?UTF-8?q?=D0=B8=20=D0=BD=D0=B5=D0=BF=D1=80=D0=B0=D0=B2=D0=B8=D0=BB=D1=8C?= =?UTF-8?q?=D0=BD=D0=BE=D0=BC=20=D0=B2=D0=B2=D0=BE=D0=B4=D0=B5=20=D0=A4?= =?UTF-8?q?=D0=98=D0=9E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/base/BaseClientFormCreate.vue | 22 ++++++++++++-------- src/pages/clients/utils/tableConfig.js | 2 +- 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/src/components/base/BaseClientFormCreate.vue b/src/components/base/BaseClientFormCreate.vue index 1c47ac7..79330a3 100644 --- a/src/components/base/BaseClientFormCreate.vue +++ b/src/components/base/BaseClientFormCreate.vue @@ -384,19 +384,23 @@ export default { }, checkFormFullness() { if (!this.infoClient.basic.full_name) { - this.addErrrorNotification(); + this.addErrrorNotification( + "Не заполнено ФИО клиента", + "Пожалуйста, заполните ФИО клиента" + ); + return false; + } + if (this.infoClient.basic.full_name.split(" ").length < 3) { + this.addErrrorNotification( + "Не корректное ФИО клиента", + "Пожалуйста, введите ФИО клиента правильно" + ); return false; } return true; }, - addErrrorNotification() { - addNotification( - new Date().getTime(), - "Не заполнено ФИО клиента", - "Пожалуйста, заполните ФИО клиента", - "error", - 5000 - ); + addErrrorNotification(title, message) { + addNotification(new Date().getTime(), title, message, "error", 5000); }, addSuccessNotification() { addNotification( diff --git a/src/pages/clients/utils/tableConfig.js b/src/pages/clients/utils/tableConfig.js index d27b0ec..b6099ec 100644 --- a/src/pages/clients/utils/tableConfig.js +++ b/src/pages/clients/utils/tableConfig.js @@ -153,7 +153,7 @@ export const detail = { rowFlex: true, }, addresses: { - title: "Адреса", + title: "Адрес", options: { join_adress: "Полный адрес", },