import React from "react"; import Head from 'next/head'; import Image from 'next/image'; import Link from "next/link"; import cookie from 'cookie'; import numeral from "numeral"; import pluralize from 'pluralize-ru'; import { SpinnerCircular } from 'spinners-react'; import Select from 'react-select'; import { connect } from "react-redux"; import { withRouter } from 'next/router'; import debounce from 'debounce-promise'; import { get as _get } from 'lodash'; import QuestionnaireForm from "../QuestionnaireForm"; import CalendarDatePicker from '../../../CalendarDatePicker'; import FilesList from "../FilesList"; import Modal from "../../../../pages/components/Modal/modal"; import countries from "../../../../lib/countries.json"; import citizenships from "../../../../lib/citizenships.json"; import doctypes_personal from "../../../../lib/doctypes_personal.json"; import doctypes_corporate from "../../../../lib/doctypes_corporate.json"; import { reduxWrapper } from '../../../../store'; import moment from "moment"; import AddressSuggests from "../../AddressSuggests"; import InputMask from 'react-input-mask'; import SuggestsInput from "../../SuggestsInput"; import { getCitizenshipTitleByCode } from "../../../../utils/citizenship"; import { removeAttachmentFiles, saveQuestionnaire, getSuggests, checkDocumentData } from "../../../../actions"; import DocumentIssuerSuggestsInput from "../../DocumentIssuerSuggestsInput"; import FormMessage from "../FormMessage"; const is_valid_inn = (i) => { if ( i.match(/\D/) ) return false; var inn = i.match(/(\d)/g); if ( inn.length == 10 ) { return inn[9] == String((( 2*inn[0] + 4*inn[1] + 10*inn[2] + 3*inn[3] + 5*inn[4] + 9*inn[5] + 4*inn[6] + 6*inn[7] + 8*inn[8] ) % 11) % 10); } else if ( inn.length == 12 ) { return inn[10] == String((( 7*inn[0] + 2*inn[1] + 4*inn[2] + 10*inn[3] + 3*inn[4] + 5*inn[5] + 9*inn[6] + 4*inn[7] + 6*inn[8] + 8*inn[9] ) % 11) % 10) && inn[11] == String((( 3*inn[0] + 7*inn[1] + 2*inn[2] + 4*inn[3] + 10*inn[4] + 3*inn[5] + 5*inn[6] + 9*inn[7] + 4*inn[8] + 6*inn[9] + 8*inn[10] ) % 11) % 10); } return false; } const suggestsInnDebounce = (query) => { return getSuggests("inn", { query }); } const suggestsInn = debounce(suggestsInnDebounce, 200); const signer_template = { not_head_person: true, lastname: "", firstname: "", middlename: "", no_middle_name: false, jobtitle: "", signer_rule_basic: "", signer_rule_basic_add: "", docdate: "", docnumber: "", delegation_agreement: false, telephone: "", email: "", }; const identity_document_template = { doctype: "", seria: "", docnumber: "", issuedate: "", code: "", issueby: "", issueby_search_dadata: "", placebirth: "", citizenship: { title: "", code: "", }, registration_address: { name: "", fias_id: "", } }; class Form_3_Signer extends QuestionnaireForm { constructor(props) { super(props); this.state = { main: { title: null, inn: null, kpp: null, email: null, telephone: null, websiteurl: null, financial_loan: null, is_individual_executive: false, individual_executive_inn: "", individual_executive_kpp: "", individual_executive_oop: "", individual_executive_docnum: "", individual_executive_docdate: "", high_level: "", board_of_directors: "", collective_executive: "", individual_executive: "", other_control: "", }, head_person: { lastname: "", firstname: "", middlename: "", no_middle_name: false, jobtitle: "Генеральный директор", telephone: "", email: "", identity_document: { doctype: "", seria: "", docnumber: "", issuedate: "", code: "", issueby: "", issueby_search_dadata: "", placebirth: "", citizenship: { title: "", code: "", }, registration_address: { name: "", fias_id: "", } }, /* Запрос 2024-02-08 на удаление даты назначения и даты окончания полномочий assignment_date: "", credentials_dateend: "", indefinite: false, */ }, signatory_person: { not_head_person: false, lastname: "", firstname: "", middlename: "", no_middle_name: false, jobtitle: "", signer_rule_basic: "", signer_rule_basic_add: "", docdate: "", docnumber: "", delegation_agreement: false, telephone: "", email: "", identity_document: { doctype: "", seria: "", docnumber: "", issuedate: "", code: "", issueby: "", issueby_search_dadata: "", placebirth: "", citizenship: { title: "", code: "", }, registration_address: { name: "", fias_id: "", } } }, delegation_files: [], head_person_files: [], signatory_person_files: [], signatory_corporate_files: [], loading: false, modal_show_personal_data: false, status: "empty", errors: [], signer_from_list: true, client_contacts: [], }; this.ref_form = React.createRef(); this.ref_submit = React.createRef(); } static getDerivedStateFromProps(nextProps, prevState) { return { main: nextProps.questionnaire.main, head_person: nextProps.questionnaire.head_person, head_person_files: nextProps.questionnaire.head_person_files, delegation_files: nextProps.questionnaire.delegation_files, signatory_person: nextProps.questionnaire.signatory_person, signatory_person_files: nextProps.questionnaire.signatory_person_files, signatory_corporate_files: nextProps.questionnaire.signatory_corporate_files, status: nextProps.questionnaire.status, client_contacts: nextProps.questionnaire.client_contacts, }; } componentDidMount() { const { main, signatory_person } = this.state; /* Запрос 2024-02-08 на удаление даты назначения и даты окончания полномочий if( main.inn !== null && main.inn.length === 12) { this._handle_onCheckboxFieldChange("head_person.indefinite", true); } */ if(signatory_person.lastname !== null || signatory_person.lastname !== undefined || signatory_person.lastname !== "") { this.setState({ signer_from_list: false }); } } _handle_onCitizenshipChange = (name, value) => { let citizenship = getCitizenshipTitleByCode(value); this._handle_onFieldChange(name, { title: citizenship, code: value, }); } _handle_onIssuerCodeChange = (branch, option) => { this._removeError(`${ branch }.identity_document.code`); if(typeof option === "string") { this._handle_onTextFieldChange(`${ branch }.identity_document.code`, option); } else { this._handle_onBranchChange([ { name: `${ branch }.identity_document.code`, value: option.data.code }, { name: `${ branch }.identity_document.issueby`, value: option.value }, ]); this._removeError(`${ branch }.identity_document.issueby`); } } _handle_onIssuerChange = (branch, option) => { this._removeError(`${ branch }.identity_document.issueby`); if(typeof option === "string") { this._handle_onTextFieldChange(`${ branch }.identity_document.issueby`, option); } else { this._handle_onBranchChange([ { name: `${ branch }.identity_document.code`, value: option.data.code }, { name: `${ branch }.identity_document.issueby`, value: option.value }, ]); this._removeError(`${ branch }.identity_document.code`); } } /* Запрос 2024-02-08 на удаление даты назначения и даты окончания полномочий _handle_onIndefiniteChange = () => { const { head_person } = this.state; const indefinite = !head_person.indefinite ? true : false; this._handle_onCheckboxFieldChange("head_person.indefinite", indefinite); this._removeError("head_person.credentials_dateend"); if(!indefinite) { setTimeout(() => { this._handle_onCheckboxFieldChange("head_person.credentials_dateend", ""); }, 10); } } */ _handle_onChangeDelegationAgreement = () => { const { signatory_person, delegation_files } = this.state; if(!signatory_person.delegation_agreement) { this._handle_onCheckboxFieldChange("signatory_person.delegation_agreement", true); } else { removeAttachmentFiles(delegation_files); this._handle_onBranchChange([ { name: "signatory_person.delegation_agreement", value: false, }, { name: "main.individual_executive_inn", value: "", }, { name: "main.individual_executive_kpp", value: "", }, { name: "main.individual_executive_oop", value: "", }, { name: "main.individual_executive_docnum", value: "", }, { name: "main.individual_executive_docdate", value: "", }, { name: "delegation_files", value: [], }, ]); } } _handle_onInnChange = (inn) => { this._handle_onTextFieldChange("main.individual_executive_inn", inn); suggestsInn(inn.replace(/[^\d]+/g, '')) .then((result) => { if(result?.suggestions.length > 0) { if(inn.replace(/[^\d]+/g, '').length > 10) { this._handle_onTextFieldChange("main.individual_executive_oop", result?.suggestions[0]?.data?.name?.full_with_opf); } else { this._handle_onBranchChange([ { name: "main.individual_executive_oop", value: result?.suggestions[0]?.data?.name?.full_with_opf, }, { name: "main.individual_executive_kpp", value: result?.suggestions[0]?.data?.kpp, }]); } } }) .catch(() => { }); } _handle_onDocumentTypeChange = (branch, element) => { this._handle_onBranchChange([ { name: `${ branch }.identity_document.doctype`, value: element.value }, { name: `${ branch }.identity_document.citizenship_code`, value: parseInt(element.value, 10) === 100000000 ? 643 : null }, ]); } _handle_onSignerFromListSelect = (contact) => { //console.log(contact); const signer = { ...JSON.parse(JSON.stringify(signer_template)), ...contact }; if(signer.identity_document === undefined || signer.identity_document === null) { signer.identity_document = JSON.parse(JSON.stringify(identity_document_template)); } this._handle_onBranchChange([ { name: "signatory_person", value: signer }, { name: "signatory_person_files", value: [] }, { name: "signatory_corporate_files", value: [] }, ]); this.setState({ signer_from_list: false }, () => { }); } _handle_onNextPage = (event) => { event.preventDefault(); this.setState({ loading: true }, async () => { const errors = []; const { main, head_person, signatory_person, delegation_files, head_person_files, signatory_person_files, signatory_corporate_files, } = this.state; const head_person_check = [ "lastname", "firstname", "jobtitle", "email", "identity_document.seria", "identity_document.docnumber", "identity_document.issuedate", "identity_document.placebirth", "identity_document.citizenship_code", "identity_document.registration_address.name", /* Запрос 2024-02-08 на удаление даты назначения и даты окончания полномочий "assignment_date", */ ]; if(parseInt(_get(head_person, "identity_document.doctype"), 10) === 100000000) { head_person_check.push("identity_document.code"); head_person_check.push("identity_document.issueby"); } for(let i in head_person_check) { const v = _get(head_person, head_person_check[i]); if(v === "" || v === null) { errors.push(`head_person.${ head_person_check[i] }`); } } /* Запрос 2024-02-08 на удаление даты назначения и даты окончания полномочий if(head_person.assignment_date !== undefined && head_person.assignment_date !== null && head_person.assignment_date !== "") { try { const date = moment(head_person.assignment_date); const today = moment(); if(date > today) { errors.push(`head_person.assignment_date`); errors.push(`head_person.assignment_date_invalid`); } } catch(e) { errors.push(`head_person.assignment_date`); errors.push(`head_person.assignment_date_invalid`); } } if(!head_person.indefinite) { if(head_person.credentials_dateend === undefined || head_person.credentials_dateend === null || head_person.credentials_dateend === "") { errors.push(`head_person.credentials_dateend`); } if(head_person.credentials_dateend !== undefined && head_person.credentials_dateend !== null && head_person.credentials_dateend !== "") { try { const date = moment(head_person.credentials_dateend); const today = moment(); if(date < today) { errors.push(`head_person.credentials_dateend`); errors.push(`head_person.credentials_dateend_invalid`); } } catch(e) { errors.push(`head_person.credentials_dateend`); errors.push(`head_person.credentials_dateend_invalid`); } } } */ if(head_person.telephone === "" || head_person.telephone === null || isNaN(parseInt(head_person.telephone.replace(/[^\d]+/g, ''), 10)) || parseInt(head_person.telephone.replace(/[^\d]+/g, ''), 10).toString().length < 11) { errors.push(`head_person.telephone`); } const email_regex = new RegExp(/[^@\s]+@[^@\s]+\.[^@\s]+/); if(!email_regex.test(head_person.email)) { errors.push(`head_person.email`); } //8004 //930118 if(parseInt(_get(head_person, "identity_document.doctype"), 10) === 100000000 && errors.indexOf("head_persor.identity_document.seria") < 0 && errors.indexOf("head_persor.identity_document.docnumber") < 0) { const head_person_document_check_response = await checkDocumentData({ seria: head_person.identity_document.seria, number: head_person.identity_document.docnumber, }); if(head_person_document_check_response[0] !== undefined && head_person_document_check_response[0].qc !== 0) { errors.push(`head_person.identity_document.invalid`); errors.push(`head_person.identity_document.seria`); errors.push(`head_person.identity_document.docnumber`); } } //переданы if(signatory_person.delegation_agreement) { const main_check = [ "individual_executive_inn", "individual_executive_kpp", "individual_executive_oop", "individual_executive_docnum", "individual_executive_docdate", ]; for(let i in main_check) { let v = _get(main, main_check[i]); if(main_check[i] === "individual_executive_inn") { if(v !== null && !is_valid_inn(v.replace(/[^\d]+/g, ''))) { errors.push(`main.individual_executive_inn`); } } else { if(v === "" || v === null) { errors.push(`main.${ main_check[i] }`); } } } if(delegation_files.length === 0) { errors.push(`delegation_files`); } } //иной подписант if(signatory_person.not_head_person) { const signatory_person_check = [ "lastname", "firstname", "jobtitle", "signer_rule_basic", "email", "identity_document.seria", "identity_document.docnumber", "identity_document.issuedate", "identity_document.placebirth", "identity_document.citizenship.code", "identity_document.registration_address.name", ]; if(parseInt(_get(signatory_person, "identity_document.doctype"), 10) === 100000000) { signatory_person_check.push("identity_document.code"); signatory_person_check.push("identity_document.issueby"); } if(parseInt(signatory_person.signer_rule_basic, 10) === 100000003) { signatory_person_check.push("signer_rule_basic_add"); } if(signatory_person.telephone === "" || signatory_person.telephone === null || isNaN(parseInt(signatory_person.telephone.replace(/[^\d]+/g, ''), 10)) || parseInt(signatory_person.telephone.replace(/[^\d]+/g, ''), 10).toString().length < 11) { errors.push(`signatory_person.telephone`); } const email_regex = new RegExp(/[^@\s]+@[^@\s]+\.[^@\s]+/); if(!email_regex.test(signatory_person.email)) { errors.push(`signatory_person.email`); } if(signatory_person_files.length === 0) { errors.push(`signatory_person_files`); } if(parseInt(signatory_person.signer_rule_basic, 10) === 100000000 || parseInt(signatory_person.signer_rule_basic, 10) === 100000003) { signatory_person_check.push("docdate"); signatory_person_check.push("docnumber"); if(signatory_corporate_files.length === 0) { errors.push(`signatory_corporate_files`); } } for(let i in signatory_person_check) { let v = _get(signatory_person, signatory_person_check[i]); if(v === "" || v === null) { errors.push(`signatory_person.${ signatory_person_check[i] }`); } } if(parseInt(_get(signatory_person, "identity_document.doctype"), 10) === 100000000 && errors.indexOf("signatory_person.identity_document.seria") < 0 && errors.indexOf("signatory_person.identity_document.docnumber") < 0) { const signatory_person_document_check_response = await checkDocumentData({ seria: signatory_person.identity_document.seria, number: signatory_person.identity_document.docnumber, }); if(signatory_person_document_check_response[0] !== undefined && signatory_person_document_check_response[0].qc !== 0) { errors.push(`signatory_person.identity_document.invalid`); errors.push(`signatory_person.identity_document.seria`); errors.push(`signatory_person.identity_document.docnumber`); } } if(head_person.lastname !== null && head_person.lastname !== "" && head_person.firstname !== null && head_person.firstname !== "") { if(signatory_person.lastname !== null && signatory_person.lastname !== "" && signatory_person.firstname !== null && signatory_person.firstname !== "") { if(head_person.lastname === signatory_person.lastname && head_person.firstname === signatory_person.firstname) { errors.push(`signatory_person.identical`); } } } } if(head_person_files.length === 0) { errors.push(`head_person_files`); } this.setState({ errors, loading: false }, () => { window.scroll(0, 0); if(errors.length === 0) { this.ref_submit.current.click(); } }); }); } _handle_onFormSubmit = (event) => { event.preventDefault(); this._handle_onCheckboxFieldChange("step", 4); setTimeout(() => { saveQuestionnaire(); this.props.onNextStep("shareholders"); }, 10); } render() { const { checking } = this.props; const { loading, main, head_person, signatory_person, status, errors, head_person_files, signatory_person_files, signatory_corporate_files, delegation_files, signer_from_list, client_contacts, } = this.state; //console.log({ errors }); let head_person_citizenship = { label: getCitizenshipTitleByCode(head_person.identity_document.citizenship.code), code: head_person.identity_document.citizenship.code }; let signatory_person_citizenship = { label: getCitizenshipTitleByCode(signatory_person.identity_document.citizenship.code), code: signatory_person.identity_document.citizenship.code }; return (
{if (e.key === 'Enter') e.preventDefault() }} className={`questionnaire questionnaire_3 ${ checking && "disabled" }`}>

3. Информация о единоличном исполнительном органе, подписанте договора лизинга

{ errors.length > 0 && ( ) }
-1 ? "error" : "" } type="lastname" id="head_person.lastname" name="head_person.lastname" value={ this._checkStrValue(head_person.lastname) } placeholder="Введите фамилию" onChange={ (value) => { this._removeError("head_person.lastname"); this._handle_onTextFieldChange("head_person.lastname", value); } } required={ true } disabled={ checking } />
-1 ? "error" : "" } type="firstname" id="head_person.firstname" name="head_person.firstname" value={ this._checkStrValue(head_person.firstname) } placeholder="Введите имя" onChange={ (value) => { this._removeError("head_person.firstname"); this._handle_onTextFieldChange("head_person.firstname", value) } } required={ true } disabled={ checking } />
{ this._removeError("head_person.middlename"); this._handle_onTextFieldChange("head_person.middlename", value) } } required={ false } disabled={ checking } />
!inputValue ? noOptionsText :"Ничего не найдено" } isSearchable={ true } className="autocomlete" classNamePrefix="react-select" value={ head_person_citizenship.code !== null ? head_person_citizenship : undefined } onChange={ (element) => { this._removeError("head_person.identity_document.citizenship"); this._handle_onCitizenshipChange(`head_person.identity_document.citizenship`, element.value) } } required={ true } isDisabled={ checking } />
) }
-1 ? "error" : "" } value={ this._checkStrValue(head_person.identity_document.registration_address.name) } fias={ this._checkStrValue(head_person.identity_document.registration_address.fias_id) } placeholder="Укажите адрес регистрации" onChange={ (data) => { this._removeError("head_person.identity_document.registration_address.name"); this._handle_onTextFieldChange("head_person.identity_document.registration_address", data) } } required={ true } disabled={ checking } />
-1 ? "error" : "" } id="head_person.jobtitle" name="head_person.jobtitle" value={ this._checkStrValue(head_person.jobtitle) } placeholder="Укажите должность" onChange={ (event) => { this._removeError(event.target.name); this._handle_onTextFieldChange(event.target.name, event.target.value); } } required={ true } disabled={ checking } />
-1 ? "error" : "" } mask='+7 (999) 999 99 99' id={ "head_person.telephone" } name={ "head_person.telephone" } value={ this._checkStrValue(head_person.telephone) } placeholder="Введите номер телефона" onChange={ (event) => { if(event.target.value !== "" && !isNaN(parseInt(event.target.value.replace(/[^\d]+/g, ''), 10)) && parseInt(event.target.value.replace(/[^\d]+/g, ''), 10) > 7) { this._removeError("head_person.telephone"); } this._handle_onTextFieldChange(event.target.name, event.target.value); } } required={ true } disabled={ checking } />
-1 ? "error" : "" } id={ "head_person.email" } name={ "head_person.email" } value={ this._checkStrValue(head_person.email) } placeholder="Введите E-mail" onChange={ (event) => { this._removeError(event.target.name); this._handle_onTextFieldChange(event.target.name, event.target.value); } } pattern="[^@\s]+@[^@\s]+\.[^@\s]+" required={ true } disabled={ checking } />
{/*} Запрос 2024-02-08 на удаление даты назначения и даты окончания полномочий { errors.indexOf("head_person.assignment_date_invalid") > -1 && ( ) }
-1 ? "error" : "" } placeholder="ДД.ММ.ГГГГ" max={ moment().toDate() } id={ "head_person.assignment_date" } value={ this._checkStrValue(head_person.assignment_date) !== "" ? this._checkStrValue(head_person.assignment_date) : null } onChange={ (date, raw) => { this._removeError([ "head_person.assignment_date", "head_person.assignment_date_invalid" ]); this._handle_onDateFieldChange("head_person.assignment_date", date, raw) } } required={ true } disabled={ checking } style={{ maxWidth: "320px" }} />
this._handle_onIndefiniteChange() } disabled={ checking } />
*/} {/*} { !head_person.indefinite && ( { errors.indexOf("head_person.credentials_dateend_invalid") > -1 && ( ) }
-1 ? "error" : "" } min={ moment().toDate() } placeholder="ДД.ММ.ГГГГ" id={ "head_person.credentials_dateend" } value={ this._checkStrValue(head_person.credentials_dateend) !== "" ? this._checkStrValue(head_person.credentials_dateend) : null } onChange={ (date, raw) => { this._removeError([ "head_person.credentials_dateend", "head_person.credentials_dateend_invalid" ]); this._handle_onDateFieldChange("head_person.credentials_dateend", date, raw) } } required={ true } disabled={ checking } style={{maxWidth: "320px"}} />
) } {*/} { errors.indexOf("head_person_files") > -1 && ( ) } { this._removeError("head_person_files"); this._handle_onAddFile(name, files); } } onRemoveFile={ this._handle_onRemoveFile } checking={ checking } title="Прикрепить скан паспорта единоличного исполнительного органа" /> {} } value={ head_person_files.length > 0 ? head_person_files.length : "" } required={ true } style={{ opacity: 0.0, height: "0px", marginTop: "-25px", display: "flex" }}/> { main.inn !== null && main.inn.length < 11 && (
{ signatory_person.delegation_agreement && (

Информация об управляющей организации или управляющем

{ errors.indexOf("main.individual_executive_inn") > -1 && ( ) }
-1 ? "error" : "" } style={{ width: "100%" }} mask='999999999999' //maskPlaceholder={ main.individual_executive_inn !== null && main.individual_executive_inn.replace(/[^\d.-]+/g, '').length < 11 ? "_" : " " } alwaysShowMask={ false } id="main.individual_executive_inn" name="main.individual_executive_inn" value={ this._checkStrValue(main.individual_executive_inn) } placeholder="Введите ИНН" onChange={ (event) => { this._removeError(event.target.name); this._handle_onInnChange(event.target.value); } } required={ true } disabled={ checking } />
{ main.individual_executive_inn !== null && main.individual_executive_inn.replace(/[^\d.-]+/g, '').length < 11 && (
-1 ? "error" : "" } style={{ width: "100%" }} mask='9999999999' alwaysShowMask={ false } id="main.individual_executive_kpp" name="main.individual_executive_kpp" value={ this._checkStrValue(main.individual_executive_kpp) } placeholder="Введите КПП" onChange={ (event) => { this._removeError(event.target.name); this._handle_onTextFieldChange(event.target.name, event.target.value); } } required={ true } disabled={ checking } />
) }

-1 ? "error" : "" } style={{ width: "100%" }} id="main.individual_executive_oop" name="main.individual_executive_oop" value={ this._checkStrValue(main.individual_executive_oop) } placeholder="Укажите наименование" onChange={ (event) => { this._removeError(event.target.name); this._handle_onTextFieldChange(event.target.name, event.target.value); } } required={ true } disabled={ checking } />
-1 ? "error" : "" } style={{ width: "100%" }} id="main.individual_executive_docnum" name="main.individual_executive_docnum" value={ this._checkStrValue(main.individual_executive_docnum) } placeholder="Номер договора" onChange={ (event) => { this._removeError(event.target.name); this._handle_onTextFieldChange(event.target.name, event.target.value); } } disabled={ checking } />
-1 ? "error" : "" } style={{ width: "100%", }} placeholder="ДД.ММ.ГГГГ" max={ moment().toDate() } id={ "main.individual_executive_docdate" } value={ this._checkStrValue(main.individual_executive_docdate) !== "" ? this._checkStrValue(main.individual_executive_docdate) : null } onChange={ (date, raw) => { this._removeError("main.individual_executive_docdate"); this._handle_onDateFieldChange("main.individual_executive_docdate", date, raw); } } required={ true } disabled={ checking } />
{ errors.indexOf("delegation_files") > -1 && ( ) } { this._removeError("delegation_files"); this._handle_onAddFile(name, files); } } onRemoveFile={ this._handle_onRemoveFile } checking={ checking } /> {} } value={ delegation_files.length > 0 ? delegation_files.length : "" } required={ true } style={{ opacity: 0.0, height: "0px", marginTop: "-25px", display: "flex" }}/>
) }
) } { errors.indexOf("signatory_person.identical") > -1 && ( ) }
this._handle_onCheckboxFieldChange(event.target.name, !signatory_person.not_head_person ? true : false) } disabled={ checking } />
{ signatory_person.not_head_person && (

Информация о подписанте (заполняется если подписант договора лизинга отличается от единоличного исполнительного органа)

{ !checking && (
{ this.setState({ signer_from_list: signer_from_list ? false : true })} } />
) }
{ signer_from_list ? (
{ client_contacts.map((contact, index) => (
{ this._handle_onSignerFromListSelect(contact) } } disabled={ false } />
)) }
) : (
-1 ? "error" : "" } type="lastname" id="signatory_person.lastname" name="signatory_person.lastname" value={ this._checkStrValue(signatory_person.lastname) } placeholder="Введите фамилию" onChange={ (value) => { this._removeError("signatory_person.lastname"); this._handle_onTextFieldChange("signatory_person.lastname", value); } } required={ true } disabled={ checking } />
-1 ? "error" : "" } type="firstname" id="signatory_person.firstname" name="signatory_person.firstname" value={ this._checkStrValue(signatory_person.firstname) } placeholder="Введите имя" onChange={ (value) => { this._removeError("signatory_person.firstname"); this._handle_onTextFieldChange("signatory_person.firstname", value); } } required={ true } disabled={ checking } />
this._handle_onTextFieldChange("signatory_person.middlename", value) } required={ false } disabled={ checking } />
-1 ? "autocomlete error" : "autocomlete" } id="signatory_person.identity_document.citizenship" name="signatory_person.identity_document.citizenship" options={ citizenships } placeholder="Выберите страну" noOptionsMessage={ ({ inputValue }) => !inputValue ? noOptionsText :"Ничего не найдено" } isSearchable={ true } classNamePrefix="react-select" value={ signatory_person_citizenship.code !== null ? signatory_person_citizenship : undefined } onChange={ (element) => { this._removeError("signatory_person.identity_document.citizenship"); this._handle_onCitizenshipChange(`signatory_person.identity_document.citizenship`, element.value); } } required={ true } isDisabled={ checking } />
) }
-1 ? "error" : "" } value={ this._checkStrValue(signatory_person.identity_document.registration_address.name) } fias={ this._checkStrValue(signatory_person.identity_document.registration_address.fias_id) } onChange={ (data) => { this._removeError("signatory_person.identity_document.registration_address.name"); this._handle_onTextFieldChange("signatory_person.identity_document.registration_address", data); } } required={ true } disabled={ checking } />
-1 ? "error" : "" } id="signatory_person.jobtitle" name="signatory_person.jobtitle" value={ this._checkStrValue(signatory_person.jobtitle) } placeholder="Укажите должность" onChange={ (event) => { this._removeError("signatory_person.jobtitle"); this._handle_onTextFieldChange(event.target.name, event.target.value); } } required={ true } disabled={ checking } />
-1 ? "error" : "" } id={ "signatory_person.telephone" } name={ "signatory_person.telephone" } value={ this._checkStrValue(signatory_person.telephone) } placeholder="Введите номер телефона" onChange={ (event) => { this._removeError("signatory_person.telephone"); this._handle_onTextFieldChange(event.target.name, event.target.value); } } required={ true } disabled={ checking } mask='+7 (999) 999 99 99' />
-1 ? "error" : "" } id="signatory_person.email" name="signatory_person.email" value={ this._checkStrValue(signatory_person.email) } placeholder="E-mail" onChange={ (event) => { this._removeError("signatory_person.email"); this._handle_onTextFieldChange(event.target.name, event.target.value); } } pattern="[^@\s]+@[^@\s]+\.[^@\s]+" required={ true } disabled={ checking } />
{ errors.indexOf("signatory_person_files") > -1 && ( ) } { this._removeError("signatory_person_files"); this._handle_onAddFile(name, files); } } onRemoveFile={ this._handle_onRemoveFile } checking={ checking } /> {} } value={ signatory_person_files.length > 0 ? signatory_person_files.length : "" } required={ true } style={{ opacity: 0.0, height: "0px", marginTop: "-25px", display: "flex" }}/>

Реквизиты документа подтверждающие полномочия на подписание договора лизинга

-1 ? "error" : "" } id="signatory_person.signer_rule_basic_add" name="signatory_person.signer_rule_basic_add" value={ this._checkStrValue(signatory_person.signer_rule_basic_add) } placeholder="Наименование документа" onChange={ (event) => { this._removeError("signatory_person.signer_rule_basic_add"); this._handle_onTextFieldChange(event.target.name, event.target.value); } } required={ true } disabled={ checking } />
) } { (parseInt(signatory_person.signer_rule_basic, 10) === 100000000 || parseInt(signatory_person.signer_rule_basic, 10) === 100000003) && ( <>
-1 ? "error" : "" } id="signatory_person.docnumber" name="signatory_person.docnumber" value={ this._checkStrValue(signatory_person.docnumber) } placeholder="Номер документа" onChange={ (event) => { this._removeError("signatory_person.docnumber"); this._handle_onTextFieldChange(event.target.name, event.target.value); } } required={ true } disabled={ checking } />
-1 ? "error" : "" } style={{ width: "calc(100% - 198px)" }} placeholder="ДД.ММ.ГГГГ" max={ moment().toDate() } id={ "signatory_person.docdate" } value={ this._checkStrValue(signatory_person.docdate) !== "" ? this._checkStrValue(signatory_person.docdate) : null } onChange={ (date, raw) => { this._removeError("signatory_person.docdate"); this._handle_onDateFieldChange("signatory_person.docdate", date, raw); } } required={ true } disabled={ checking } />
{ errors.indexOf("signatory_corporate_files") > -1 && ( ) } { this._removeError("signatory_corporate_files"); this._handle_onAddFile(name, files); } } onRemoveFile={ this._handle_onRemoveFile } checking={ checking } /> {} } value={ signatory_corporate_files.length > 0 ? signatory_corporate_files.length : "" } required={ true } style={{ opacity: 0.0, height: "0px", marginTop: "-25px", display: "flex" }}/> ) }
) }
) } { !checking && (
) }
) } } function mapStateToProps(state, ownProps) { return { questionnaire: state.questionnaire, } } export const getServerSideProps = reduxWrapper.getServerSideProps(store => async ({ req, res, query }) => { } ); export default connect(mapStateToProps)(Form_3_Signer);