@redneckz/wildless-cms-uni-blocks 0.14.866 → 0.14.867

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (411) hide show
  1. package/bundle/bundle.umd.js +550 -416
  2. package/bundle/bundle.umd.min.js +1 -1
  3. package/bundle/components/ApplicationLeadForm/getLeadFormTaskData.d.ts +4 -5
  4. package/bundle/components/ApplicationLeadForm/useInitApplicationLead.d.ts +6 -0
  5. package/bundle/components/CreditCardForm/getCreditCardFormTaskData.d.ts +1 -3
  6. package/bundle/components/DebitForm/getDebitCardFormTaskData.d.ts +1 -3
  7. package/bundle/retail/adaptors/getCreditFormTaskData.d.ts +1 -3
  8. package/bundle/retail/api/createUserTaskDebit.d.ts +3 -1
  9. package/bundle/retail/api/updateUserTask.d.ts +3 -2
  10. package/bundle/retail/api/updateUserTaskDebit.d.ts +1 -1
  11. package/bundle/retail/components/DraftDialog/parseDraftTask.d.ts +1 -1
  12. package/bundle/retail/components/Fields/InitiateBankruptcyFlgField.d.ts +2 -0
  13. package/bundle/retail/content.d.ts +2 -8
  14. package/bundle/retail/inputs.d.ts +1 -1
  15. package/bundle/retail/model/LeadFormState.d.ts +4 -2
  16. package/bundle/retail/model/NameFieldDef.d.ts +1 -1
  17. package/bundle/retail/model/ReferalData.d.ts +0 -1
  18. package/bundle/retail/utils/getMainFormStateMap.d.ts +2 -0
  19. package/dist/components/ApplicationLeadForm/applicationFormData.js +0 -1
  20. package/dist/components/ApplicationLeadForm/applicationFormData.js.map +1 -1
  21. package/dist/components/ApplicationLeadForm/consents.js +0 -4
  22. package/dist/components/ApplicationLeadForm/consents.js.map +1 -1
  23. package/dist/components/ApplicationLeadForm/getLeadFormTaskData.d.ts +4 -5
  24. package/dist/components/ApplicationLeadForm/getLeadFormTaskData.js +20 -17
  25. package/dist/components/ApplicationLeadForm/getLeadFormTaskData.js.map +1 -1
  26. package/dist/components/ApplicationLeadForm/useApplicationLeadApi.js +12 -11
  27. package/dist/components/ApplicationLeadForm/useApplicationLeadApi.js.map +1 -1
  28. package/dist/components/ApplicationLeadForm/useInitApplicationLead.d.ts +6 -0
  29. package/dist/components/ApplicationLeadForm/useInitApplicationLead.js +20 -12
  30. package/dist/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
  31. package/dist/components/CreditCardForm/creditCardFormStepsData.js +245 -3
  32. package/dist/components/CreditCardForm/creditCardFormStepsData.js.map +1 -1
  33. package/dist/components/CreditCardForm/formStateMap.js +2 -2
  34. package/dist/components/CreditCardForm/formStateMap.js.map +1 -1
  35. package/dist/components/CreditCardForm/getCreditCardFormTaskData.d.ts +1 -3
  36. package/dist/components/CreditCardForm/getCreditCardFormTaskData.js +24 -30
  37. package/dist/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
  38. package/dist/components/CreditCardForm/useCreditCardFormAPI.js +0 -2
  39. package/dist/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
  40. package/dist/components/CreditForm/CreditForm.js +1 -2
  41. package/dist/components/CreditForm/CreditForm.js.map +1 -1
  42. package/dist/components/CreditForm/creditFormStepsData.js +192 -3
  43. package/dist/components/CreditForm/creditFormStepsData.js.map +1 -1
  44. package/dist/components/CreditForm/formStateMap.js +2 -2
  45. package/dist/components/CreditForm/formStateMap.js.map +1 -1
  46. package/dist/components/CreditForm/useCreditFormAPI.js +1 -3
  47. package/dist/components/CreditForm/useCreditFormAPI.js.map +1 -1
  48. package/dist/components/DebitForm/DebitFormStepsData.js +71 -3
  49. package/dist/components/DebitForm/DebitFormStepsData.js.map +1 -1
  50. package/dist/components/DebitForm/getDebitCardFormTaskData.d.ts +1 -3
  51. package/dist/components/DebitForm/getDebitCardFormTaskData.js +16 -22
  52. package/dist/components/DebitForm/getDebitCardFormTaskData.js.map +1 -1
  53. package/dist/components/DebitForm/useDebitFormAPI.js +0 -2
  54. package/dist/components/DebitForm/useDebitFormAPI.js.map +1 -1
  55. package/dist/retail/adaptors/getCreditFormTaskData.d.ts +1 -3
  56. package/dist/retail/adaptors/getCreditFormTaskData.js +24 -33
  57. package/dist/retail/adaptors/getCreditFormTaskData.js.map +1 -1
  58. package/dist/retail/adaptors/getEmploymentData.js +3 -3
  59. package/dist/retail/adaptors/getEmploymentData.js.map +1 -1
  60. package/dist/retail/adaptors/getFamilyStatusAndIncomeData.js +2 -1
  61. package/dist/retail/adaptors/getFamilyStatusAndIncomeData.js.map +1 -1
  62. package/dist/retail/adaptors/getPersonalInfoData.js +4 -2
  63. package/dist/retail/adaptors/getPersonalInfoData.js.map +1 -1
  64. package/dist/retail/api/checkCode.js +1 -1
  65. package/dist/retail/api/checkCode.js.map +1 -1
  66. package/dist/retail/api/createUserTaskDebit.d.ts +3 -1
  67. package/dist/retail/api/createUserTaskDebit.js.map +1 -1
  68. package/dist/retail/api/updateUserTask.d.ts +3 -2
  69. package/dist/retail/api/updateUserTask.js.map +1 -1
  70. package/dist/retail/api/updateUserTaskDebit.d.ts +1 -1
  71. package/dist/retail/components/DraftDialog/DraftDialog.js +1 -2
  72. package/dist/retail/components/DraftDialog/DraftDialog.js.map +1 -1
  73. package/dist/retail/components/DraftDialog/parseDraftTask.d.ts +1 -1
  74. package/dist/retail/components/DraftDialog/parseDraftTask.js +2 -3
  75. package/dist/retail/components/DraftDialog/parseDraftTask.js.map +1 -1
  76. package/dist/retail/components/Fields/DaDataInnField.js +10 -3
  77. package/dist/retail/components/Fields/DaDataInnField.js.map +1 -1
  78. package/dist/retail/components/Fields/InitiateBankruptcyFlgField.d.ts +2 -0
  79. package/dist/retail/components/Fields/InitiateBankruptcyFlgField.js +7 -0
  80. package/dist/retail/components/Fields/InitiateBankruptcyFlgField.js.map +1 -0
  81. package/dist/retail/content.d.ts +2 -8
  82. package/dist/retail/content.js +3 -361
  83. package/dist/retail/content.js.map +1 -1
  84. package/dist/retail/inputs.d.ts +1 -1
  85. package/dist/retail/inputs.js +2 -1
  86. package/dist/retail/inputs.js.map +1 -1
  87. package/dist/retail/model/LeadFormState.d.ts +4 -2
  88. package/dist/retail/model/NameFieldDef.d.ts +1 -1
  89. package/dist/retail/model/ReferalData.d.ts +0 -1
  90. package/dist/retail/utils/getMainFormStateMap.d.ts +2 -0
  91. package/dist/retail/utils/{mainFormStateMap.js → getMainFormStateMap.js} +6 -4
  92. package/dist/retail/utils/getMainFormStateMap.js.map +1 -0
  93. package/lib/components/ApplicationLeadForm/applicationFormData.js +0 -1
  94. package/lib/components/ApplicationLeadForm/applicationFormData.js.map +1 -1
  95. package/lib/components/ApplicationLeadForm/consents.js +0 -4
  96. package/lib/components/ApplicationLeadForm/consents.js.map +1 -1
  97. package/lib/components/ApplicationLeadForm/getLeadFormTaskData.d.ts +4 -5
  98. package/lib/components/ApplicationLeadForm/getLeadFormTaskData.js +20 -17
  99. package/lib/components/ApplicationLeadForm/getLeadFormTaskData.js.map +1 -1
  100. package/lib/components/ApplicationLeadForm/useApplicationLeadApi.js +12 -11
  101. package/lib/components/ApplicationLeadForm/useApplicationLeadApi.js.map +1 -1
  102. package/lib/components/ApplicationLeadForm/useInitApplicationLead.d.ts +6 -0
  103. package/lib/components/ApplicationLeadForm/useInitApplicationLead.js +20 -12
  104. package/lib/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
  105. package/lib/components/CreditCardForm/creditCardFormStepsData.js +244 -2
  106. package/lib/components/CreditCardForm/creditCardFormStepsData.js.map +1 -1
  107. package/lib/components/CreditCardForm/formStateMap.js +2 -2
  108. package/lib/components/CreditCardForm/formStateMap.js.map +1 -1
  109. package/lib/components/CreditCardForm/getCreditCardFormTaskData.d.ts +1 -3
  110. package/lib/components/CreditCardForm/getCreditCardFormTaskData.js +24 -30
  111. package/lib/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
  112. package/lib/components/CreditCardForm/useCreditCardFormAPI.js +0 -2
  113. package/lib/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
  114. package/lib/components/CreditForm/CreditForm.js +1 -2
  115. package/lib/components/CreditForm/CreditForm.js.map +1 -1
  116. package/lib/components/CreditForm/creditFormStepsData.js +191 -2
  117. package/lib/components/CreditForm/creditFormStepsData.js.map +1 -1
  118. package/lib/components/CreditForm/formStateMap.js +2 -2
  119. package/lib/components/CreditForm/formStateMap.js.map +1 -1
  120. package/lib/components/CreditForm/useCreditFormAPI.js +1 -3
  121. package/lib/components/CreditForm/useCreditFormAPI.js.map +1 -1
  122. package/lib/components/DebitForm/DebitFormStepsData.js +70 -2
  123. package/lib/components/DebitForm/DebitFormStepsData.js.map +1 -1
  124. package/lib/components/DebitForm/getDebitCardFormTaskData.d.ts +1 -3
  125. package/lib/components/DebitForm/getDebitCardFormTaskData.js +16 -22
  126. package/lib/components/DebitForm/getDebitCardFormTaskData.js.map +1 -1
  127. package/lib/components/DebitForm/useDebitFormAPI.js +0 -2
  128. package/lib/components/DebitForm/useDebitFormAPI.js.map +1 -1
  129. package/lib/retail/adaptors/getCreditFormTaskData.d.ts +1 -3
  130. package/lib/retail/adaptors/getCreditFormTaskData.js +24 -33
  131. package/lib/retail/adaptors/getCreditFormTaskData.js.map +1 -1
  132. package/lib/retail/adaptors/getEmploymentData.js +3 -3
  133. package/lib/retail/adaptors/getEmploymentData.js.map +1 -1
  134. package/lib/retail/adaptors/getFamilyStatusAndIncomeData.js +2 -1
  135. package/lib/retail/adaptors/getFamilyStatusAndIncomeData.js.map +1 -1
  136. package/lib/retail/adaptors/getPersonalInfoData.js +4 -2
  137. package/lib/retail/adaptors/getPersonalInfoData.js.map +1 -1
  138. package/lib/retail/api/checkCode.js +1 -1
  139. package/lib/retail/api/checkCode.js.map +1 -1
  140. package/lib/retail/api/createUserTaskDebit.d.ts +3 -1
  141. package/lib/retail/api/createUserTaskDebit.js.map +1 -1
  142. package/lib/retail/api/updateUserTask.d.ts +3 -2
  143. package/lib/retail/api/updateUserTask.js.map +1 -1
  144. package/lib/retail/api/updateUserTaskDebit.d.ts +1 -1
  145. package/lib/retail/components/DraftDialog/DraftDialog.js +1 -2
  146. package/lib/retail/components/DraftDialog/DraftDialog.js.map +1 -1
  147. package/lib/retail/components/DraftDialog/parseDraftTask.d.ts +1 -1
  148. package/lib/retail/components/DraftDialog/parseDraftTask.js +2 -3
  149. package/lib/retail/components/DraftDialog/parseDraftTask.js.map +1 -1
  150. package/lib/retail/components/Fields/DaDataInnField.js +10 -3
  151. package/lib/retail/components/Fields/DaDataInnField.js.map +1 -1
  152. package/lib/retail/components/Fields/InitiateBankruptcyFlgField.d.ts +2 -0
  153. package/lib/retail/components/Fields/InitiateBankruptcyFlgField.js +5 -0
  154. package/lib/retail/components/Fields/InitiateBankruptcyFlgField.js.map +1 -0
  155. package/lib/retail/content.d.ts +2 -8
  156. package/lib/retail/content.js +2 -360
  157. package/lib/retail/content.js.map +1 -1
  158. package/lib/retail/inputs.d.ts +1 -1
  159. package/lib/retail/inputs.js +2 -1
  160. package/lib/retail/inputs.js.map +1 -1
  161. package/lib/retail/model/LeadFormState.d.ts +4 -2
  162. package/lib/retail/model/NameFieldDef.d.ts +1 -1
  163. package/lib/retail/model/ReferalData.d.ts +0 -1
  164. package/lib/retail/utils/getMainFormStateMap.d.ts +2 -0
  165. package/lib/retail/utils/{mainFormStateMap.js → getMainFormStateMap.js} +4 -3
  166. package/lib/retail/utils/getMainFormStateMap.js.map +1 -0
  167. package/mobile/bundle/bundle.umd.js +465 -314
  168. package/mobile/bundle/bundle.umd.min.js +1 -1
  169. package/mobile/bundle/components/ApplicationLeadForm/getLeadFormTaskData.d.ts +4 -5
  170. package/mobile/bundle/components/ApplicationLeadForm/useInitApplicationLead.d.ts +6 -0
  171. package/mobile/bundle/components/CreditCardForm/getCreditCardFormTaskData.d.ts +1 -3
  172. package/mobile/bundle/components/DebitForm/getDebitCardFormTaskData.d.ts +1 -3
  173. package/mobile/bundle/retail/adaptors/getCreditFormTaskData.d.ts +1 -3
  174. package/mobile/bundle/retail/api/createUserTaskDebit.d.ts +3 -1
  175. package/mobile/bundle/retail/api/updateUserTask.d.ts +3 -2
  176. package/mobile/bundle/retail/api/updateUserTaskDebit.d.ts +1 -1
  177. package/mobile/bundle/retail/components/DraftDialog/parseDraftTask.d.ts +1 -1
  178. package/mobile/bundle/retail/components/Fields/InitiateBankruptcyFlgField.d.ts +2 -0
  179. package/mobile/bundle/retail/content.d.ts +2 -8
  180. package/mobile/bundle/retail/inputs.d.ts +1 -1
  181. package/mobile/bundle/retail/model/LeadFormState.d.ts +4 -2
  182. package/mobile/bundle/retail/model/NameFieldDef.d.ts +1 -1
  183. package/mobile/bundle/retail/model/ReferalData.d.ts +0 -1
  184. package/mobile/bundle/retail/utils/getMainFormStateMap.d.ts +2 -0
  185. package/mobile/dist/components/ApplicationLeadForm/applicationFormData.js +0 -1
  186. package/mobile/dist/components/ApplicationLeadForm/applicationFormData.js.map +1 -1
  187. package/mobile/dist/components/ApplicationLeadForm/consents.js +0 -4
  188. package/mobile/dist/components/ApplicationLeadForm/consents.js.map +1 -1
  189. package/mobile/dist/components/ApplicationLeadForm/getLeadFormTaskData.d.ts +4 -5
  190. package/mobile/dist/components/ApplicationLeadForm/getLeadFormTaskData.js +20 -17
  191. package/mobile/dist/components/ApplicationLeadForm/getLeadFormTaskData.js.map +1 -1
  192. package/mobile/dist/components/ApplicationLeadForm/useApplicationLeadApi.js +12 -11
  193. package/mobile/dist/components/ApplicationLeadForm/useApplicationLeadApi.js.map +1 -1
  194. package/mobile/dist/components/ApplicationLeadForm/useInitApplicationLead.d.ts +6 -0
  195. package/mobile/dist/components/ApplicationLeadForm/useInitApplicationLead.js +20 -12
  196. package/mobile/dist/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
  197. package/mobile/dist/components/CreditCardForm/creditCardFormStepsData.js +245 -3
  198. package/mobile/dist/components/CreditCardForm/creditCardFormStepsData.js.map +1 -1
  199. package/mobile/dist/components/CreditCardForm/formStateMap.js +2 -2
  200. package/mobile/dist/components/CreditCardForm/formStateMap.js.map +1 -1
  201. package/mobile/dist/components/CreditCardForm/getCreditCardFormTaskData.d.ts +1 -3
  202. package/mobile/dist/components/CreditCardForm/getCreditCardFormTaskData.js +24 -30
  203. package/mobile/dist/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
  204. package/mobile/dist/components/CreditCardForm/useCreditCardFormAPI.js +0 -2
  205. package/mobile/dist/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
  206. package/mobile/dist/components/CreditForm/CreditForm.js +1 -2
  207. package/mobile/dist/components/CreditForm/CreditForm.js.map +1 -1
  208. package/mobile/dist/components/CreditForm/creditFormStepsData.js +192 -3
  209. package/mobile/dist/components/CreditForm/creditFormStepsData.js.map +1 -1
  210. package/mobile/dist/components/CreditForm/formStateMap.js +2 -2
  211. package/mobile/dist/components/CreditForm/formStateMap.js.map +1 -1
  212. package/mobile/dist/components/CreditForm/useCreditFormAPI.js +1 -3
  213. package/mobile/dist/components/CreditForm/useCreditFormAPI.js.map +1 -1
  214. package/mobile/dist/components/DebitForm/DebitFormStepsData.js +71 -3
  215. package/mobile/dist/components/DebitForm/DebitFormStepsData.js.map +1 -1
  216. package/mobile/dist/components/DebitForm/getDebitCardFormTaskData.d.ts +1 -3
  217. package/mobile/dist/components/DebitForm/getDebitCardFormTaskData.js +16 -22
  218. package/mobile/dist/components/DebitForm/getDebitCardFormTaskData.js.map +1 -1
  219. package/mobile/dist/components/DebitForm/useDebitFormAPI.js +0 -2
  220. package/mobile/dist/components/DebitForm/useDebitFormAPI.js.map +1 -1
  221. package/mobile/dist/retail/adaptors/getCreditFormTaskData.d.ts +1 -3
  222. package/mobile/dist/retail/adaptors/getCreditFormTaskData.js +24 -33
  223. package/mobile/dist/retail/adaptors/getCreditFormTaskData.js.map +1 -1
  224. package/mobile/dist/retail/adaptors/getEmploymentData.js +3 -3
  225. package/mobile/dist/retail/adaptors/getEmploymentData.js.map +1 -1
  226. package/mobile/dist/retail/adaptors/getFamilyStatusAndIncomeData.js +2 -1
  227. package/mobile/dist/retail/adaptors/getFamilyStatusAndIncomeData.js.map +1 -1
  228. package/mobile/dist/retail/adaptors/getPersonalInfoData.js +4 -2
  229. package/mobile/dist/retail/adaptors/getPersonalInfoData.js.map +1 -1
  230. package/mobile/dist/retail/api/checkCode.js +1 -1
  231. package/mobile/dist/retail/api/checkCode.js.map +1 -1
  232. package/mobile/dist/retail/api/createUserTaskDebit.d.ts +3 -1
  233. package/mobile/dist/retail/api/createUserTaskDebit.js.map +1 -1
  234. package/mobile/dist/retail/api/updateUserTask.d.ts +3 -2
  235. package/mobile/dist/retail/api/updateUserTask.js.map +1 -1
  236. package/mobile/dist/retail/api/updateUserTaskDebit.d.ts +1 -1
  237. package/mobile/dist/retail/components/DraftDialog/DraftDialog.js +1 -2
  238. package/mobile/dist/retail/components/DraftDialog/DraftDialog.js.map +1 -1
  239. package/mobile/dist/retail/components/DraftDialog/parseDraftTask.d.ts +1 -1
  240. package/mobile/dist/retail/components/DraftDialog/parseDraftTask.js +2 -3
  241. package/mobile/dist/retail/components/DraftDialog/parseDraftTask.js.map +1 -1
  242. package/mobile/dist/retail/components/Fields/DaDataInnField.js +10 -3
  243. package/mobile/dist/retail/components/Fields/DaDataInnField.js.map +1 -1
  244. package/mobile/dist/retail/components/Fields/InitiateBankruptcyFlgField.d.ts +2 -0
  245. package/mobile/dist/retail/components/Fields/InitiateBankruptcyFlgField.js +7 -0
  246. package/mobile/dist/retail/components/Fields/InitiateBankruptcyFlgField.js.map +1 -0
  247. package/mobile/dist/retail/content.d.ts +2 -8
  248. package/mobile/dist/retail/content.js +3 -361
  249. package/mobile/dist/retail/content.js.map +1 -1
  250. package/mobile/dist/retail/inputs.d.ts +1 -1
  251. package/mobile/dist/retail/inputs.js +2 -1
  252. package/mobile/dist/retail/inputs.js.map +1 -1
  253. package/mobile/dist/retail/model/LeadFormState.d.ts +4 -2
  254. package/mobile/dist/retail/model/NameFieldDef.d.ts +1 -1
  255. package/mobile/dist/retail/model/ReferalData.d.ts +0 -1
  256. package/mobile/dist/retail/utils/getMainFormStateMap.d.ts +2 -0
  257. package/mobile/{lib/retail/utils/mainFormStateMap.js → dist/retail/utils/getMainFormStateMap.js} +7 -3
  258. package/mobile/dist/retail/utils/getMainFormStateMap.js.map +1 -0
  259. package/mobile/lib/components/ApplicationLeadForm/applicationFormData.js +0 -1
  260. package/mobile/lib/components/ApplicationLeadForm/applicationFormData.js.map +1 -1
  261. package/mobile/lib/components/ApplicationLeadForm/consents.js +0 -4
  262. package/mobile/lib/components/ApplicationLeadForm/consents.js.map +1 -1
  263. package/mobile/lib/components/ApplicationLeadForm/getLeadFormTaskData.d.ts +4 -5
  264. package/mobile/lib/components/ApplicationLeadForm/getLeadFormTaskData.js +20 -17
  265. package/mobile/lib/components/ApplicationLeadForm/getLeadFormTaskData.js.map +1 -1
  266. package/mobile/lib/components/ApplicationLeadForm/useApplicationLeadApi.js +12 -11
  267. package/mobile/lib/components/ApplicationLeadForm/useApplicationLeadApi.js.map +1 -1
  268. package/mobile/lib/components/ApplicationLeadForm/useInitApplicationLead.d.ts +6 -0
  269. package/mobile/lib/components/ApplicationLeadForm/useInitApplicationLead.js +20 -12
  270. package/mobile/lib/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
  271. package/mobile/lib/components/CreditCardForm/creditCardFormStepsData.js +244 -2
  272. package/mobile/lib/components/CreditCardForm/creditCardFormStepsData.js.map +1 -1
  273. package/mobile/lib/components/CreditCardForm/formStateMap.js +2 -2
  274. package/mobile/lib/components/CreditCardForm/formStateMap.js.map +1 -1
  275. package/mobile/lib/components/CreditCardForm/getCreditCardFormTaskData.d.ts +1 -3
  276. package/mobile/lib/components/CreditCardForm/getCreditCardFormTaskData.js +24 -30
  277. package/mobile/lib/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
  278. package/mobile/lib/components/CreditCardForm/useCreditCardFormAPI.js +0 -2
  279. package/mobile/lib/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
  280. package/mobile/lib/components/CreditForm/CreditForm.js +1 -2
  281. package/mobile/lib/components/CreditForm/CreditForm.js.map +1 -1
  282. package/mobile/lib/components/CreditForm/creditFormStepsData.js +191 -2
  283. package/mobile/lib/components/CreditForm/creditFormStepsData.js.map +1 -1
  284. package/mobile/lib/components/CreditForm/formStateMap.js +2 -2
  285. package/mobile/lib/components/CreditForm/formStateMap.js.map +1 -1
  286. package/mobile/lib/components/CreditForm/useCreditFormAPI.js +1 -3
  287. package/mobile/lib/components/CreditForm/useCreditFormAPI.js.map +1 -1
  288. package/mobile/lib/components/DebitForm/DebitFormStepsData.js +70 -2
  289. package/mobile/lib/components/DebitForm/DebitFormStepsData.js.map +1 -1
  290. package/mobile/lib/components/DebitForm/getDebitCardFormTaskData.d.ts +1 -3
  291. package/mobile/lib/components/DebitForm/getDebitCardFormTaskData.js +16 -22
  292. package/mobile/lib/components/DebitForm/getDebitCardFormTaskData.js.map +1 -1
  293. package/mobile/lib/components/DebitForm/useDebitFormAPI.js +0 -2
  294. package/mobile/lib/components/DebitForm/useDebitFormAPI.js.map +1 -1
  295. package/mobile/lib/retail/adaptors/getCreditFormTaskData.d.ts +1 -3
  296. package/mobile/lib/retail/adaptors/getCreditFormTaskData.js +24 -33
  297. package/mobile/lib/retail/adaptors/getCreditFormTaskData.js.map +1 -1
  298. package/mobile/lib/retail/adaptors/getEmploymentData.js +3 -3
  299. package/mobile/lib/retail/adaptors/getEmploymentData.js.map +1 -1
  300. package/mobile/lib/retail/adaptors/getFamilyStatusAndIncomeData.js +2 -1
  301. package/mobile/lib/retail/adaptors/getFamilyStatusAndIncomeData.js.map +1 -1
  302. package/mobile/lib/retail/adaptors/getPersonalInfoData.js +4 -2
  303. package/mobile/lib/retail/adaptors/getPersonalInfoData.js.map +1 -1
  304. package/mobile/lib/retail/api/checkCode.js +1 -1
  305. package/mobile/lib/retail/api/checkCode.js.map +1 -1
  306. package/mobile/lib/retail/api/createUserTaskDebit.d.ts +3 -1
  307. package/mobile/lib/retail/api/createUserTaskDebit.js.map +1 -1
  308. package/mobile/lib/retail/api/updateUserTask.d.ts +3 -2
  309. package/mobile/lib/retail/api/updateUserTask.js.map +1 -1
  310. package/mobile/lib/retail/api/updateUserTaskDebit.d.ts +1 -1
  311. package/mobile/lib/retail/components/DraftDialog/DraftDialog.js +1 -2
  312. package/mobile/lib/retail/components/DraftDialog/DraftDialog.js.map +1 -1
  313. package/mobile/lib/retail/components/DraftDialog/parseDraftTask.d.ts +1 -1
  314. package/mobile/lib/retail/components/DraftDialog/parseDraftTask.js +2 -3
  315. package/mobile/lib/retail/components/DraftDialog/parseDraftTask.js.map +1 -1
  316. package/mobile/lib/retail/components/Fields/DaDataInnField.js +10 -3
  317. package/mobile/lib/retail/components/Fields/DaDataInnField.js.map +1 -1
  318. package/mobile/lib/retail/components/Fields/InitiateBankruptcyFlgField.d.ts +2 -0
  319. package/mobile/lib/retail/components/Fields/InitiateBankruptcyFlgField.js +5 -0
  320. package/mobile/lib/retail/components/Fields/InitiateBankruptcyFlgField.js.map +1 -0
  321. package/mobile/lib/retail/content.d.ts +2 -8
  322. package/mobile/lib/retail/content.js +2 -360
  323. package/mobile/lib/retail/content.js.map +1 -1
  324. package/mobile/lib/retail/inputs.d.ts +1 -1
  325. package/mobile/lib/retail/inputs.js +2 -1
  326. package/mobile/lib/retail/inputs.js.map +1 -1
  327. package/mobile/lib/retail/model/LeadFormState.d.ts +4 -2
  328. package/mobile/lib/retail/model/NameFieldDef.d.ts +1 -1
  329. package/mobile/lib/retail/model/ReferalData.d.ts +0 -1
  330. package/mobile/lib/retail/utils/getMainFormStateMap.d.ts +2 -0
  331. package/mobile/{dist/retail/utils/mainFormStateMap.js → lib/retail/utils/getMainFormStateMap.js} +4 -5
  332. package/mobile/lib/retail/utils/getMainFormStateMap.js.map +1 -0
  333. package/mobile/src/components/ApplicationLeadForm/applicationFormData.tsx +0 -1
  334. package/mobile/src/components/ApplicationLeadForm/consents.ts +0 -4
  335. package/mobile/src/components/ApplicationLeadForm/getLeadFormTaskData.ts +22 -20
  336. package/mobile/src/components/ApplicationLeadForm/useApplicationLeadApi.tsx +15 -11
  337. package/mobile/src/components/ApplicationLeadForm/useInitApplicationLead.ts +31 -12
  338. package/mobile/src/components/CreditCardForm/creditCardFormStepsData.tsx +246 -6
  339. package/mobile/src/components/CreditCardForm/formStateMap.tsx +2 -2
  340. package/mobile/src/components/CreditCardForm/getCreditCardFormTaskData.ts +24 -34
  341. package/mobile/src/components/CreditCardForm/useCreditCardFormAPI.tsx +0 -2
  342. package/mobile/src/components/CreditForm/CreditForm.tsx +1 -2
  343. package/mobile/src/components/CreditForm/creditFormStepsData.tsx +194 -6
  344. package/mobile/src/components/CreditForm/formStateMap.tsx +2 -2
  345. package/mobile/src/components/CreditForm/useCreditFormAPI.tsx +1 -3
  346. package/mobile/src/components/DebitForm/DebitFormStepsData.tsx +71 -6
  347. package/mobile/src/components/DebitForm/getDebitCardFormTaskData.ts +16 -26
  348. package/mobile/src/components/DebitForm/useDebitFormAPI.tsx +0 -2
  349. package/mobile/src/retail/adaptors/getCreditFormTaskData.ts +26 -39
  350. package/mobile/src/retail/adaptors/getEmploymentData.tsx +3 -3
  351. package/mobile/src/retail/adaptors/getFamilyStatusAndIncomeData.ts +2 -0
  352. package/mobile/src/retail/adaptors/getPersonalInfoData.tsx +4 -2
  353. package/mobile/src/retail/api/checkCode.ts +1 -1
  354. package/mobile/src/retail/api/createUserTaskDebit.ts +3 -1
  355. package/mobile/src/retail/api/updateUserTask.ts +3 -2
  356. package/mobile/src/retail/api/updateUserTaskDebit.ts +1 -1
  357. package/mobile/src/retail/components/DraftDialog/DraftDialog.tsx +1 -2
  358. package/mobile/src/retail/components/DraftDialog/parseDraftTask.ts +2 -5
  359. package/mobile/src/retail/components/Fields/DaDataInnField.tsx +14 -6
  360. package/mobile/src/retail/components/Fields/InitiateBankruptcyFlgField.tsx +10 -0
  361. package/mobile/src/retail/content.tsx +3 -362
  362. package/mobile/src/retail/inputs.tsx +2 -1
  363. package/mobile/src/retail/model/LeadFormState.ts +4 -2
  364. package/mobile/src/retail/model/NameFieldDef.ts +1 -0
  365. package/mobile/src/retail/model/ReferalData.ts +0 -1
  366. package/mobile/src/retail/utils/{mainFormStateMap.ts → getMainFormStateMap.ts} +3 -2
  367. package/package.json +1 -1
  368. package/src/components/ApplicationLeadForm/applicationFormData.tsx +0 -1
  369. package/src/components/ApplicationLeadForm/consents.ts +0 -4
  370. package/src/components/ApplicationLeadForm/getLeadFormTaskData.ts +22 -20
  371. package/src/components/ApplicationLeadForm/useApplicationLeadApi.tsx +15 -11
  372. package/src/components/ApplicationLeadForm/useInitApplicationLead.ts +31 -12
  373. package/src/components/CreditCardForm/creditCardFormStepsData.tsx +246 -6
  374. package/src/components/CreditCardForm/formStateMap.tsx +2 -2
  375. package/src/components/CreditCardForm/getCreditCardFormTaskData.ts +24 -34
  376. package/src/components/CreditCardForm/useCreditCardFormAPI.tsx +0 -2
  377. package/src/components/CreditForm/CreditForm.tsx +1 -2
  378. package/src/components/CreditForm/creditFormStepsData.tsx +194 -6
  379. package/src/components/CreditForm/formStateMap.tsx +2 -2
  380. package/src/components/CreditForm/useCreditFormAPI.tsx +1 -3
  381. package/src/components/DebitForm/DebitFormStepsData.tsx +71 -6
  382. package/src/components/DebitForm/getDebitCardFormTaskData.ts +16 -26
  383. package/src/components/DebitForm/useDebitFormAPI.tsx +0 -2
  384. package/src/retail/adaptors/getCreditFormTaskData.ts +26 -39
  385. package/src/retail/adaptors/getEmploymentData.tsx +3 -3
  386. package/src/retail/adaptors/getFamilyStatusAndIncomeData.ts +2 -0
  387. package/src/retail/adaptors/getPersonalInfoData.tsx +4 -2
  388. package/src/retail/api/checkCode.ts +1 -1
  389. package/src/retail/api/createUserTaskDebit.ts +3 -1
  390. package/src/retail/api/updateUserTask.ts +3 -2
  391. package/src/retail/api/updateUserTaskDebit.ts +1 -1
  392. package/src/retail/components/DraftDialog/DraftDialog.tsx +1 -2
  393. package/src/retail/components/DraftDialog/parseDraftTask.ts +2 -5
  394. package/src/retail/components/Fields/DaDataInnField.tsx +14 -6
  395. package/src/retail/components/Fields/InitiateBankruptcyFlgField.tsx +10 -0
  396. package/src/retail/content.tsx +3 -362
  397. package/src/retail/inputs.tsx +2 -1
  398. package/src/retail/model/LeadFormState.ts +4 -2
  399. package/src/retail/model/NameFieldDef.ts +1 -0
  400. package/src/retail/model/ReferalData.ts +0 -1
  401. package/src/retail/utils/{mainFormStateMap.ts → getMainFormStateMap.ts} +3 -2
  402. package/bundle/retail/utils/mainFormStateMap.d.ts +0 -2
  403. package/dist/retail/utils/mainFormStateMap.d.ts +0 -2
  404. package/dist/retail/utils/mainFormStateMap.js.map +0 -1
  405. package/lib/retail/utils/mainFormStateMap.d.ts +0 -2
  406. package/lib/retail/utils/mainFormStateMap.js.map +0 -1
  407. package/mobile/bundle/retail/utils/mainFormStateMap.d.ts +0 -2
  408. package/mobile/dist/retail/utils/mainFormStateMap.d.ts +0 -2
  409. package/mobile/dist/retail/utils/mainFormStateMap.js.map +0 -1
  410. package/mobile/lib/retail/utils/mainFormStateMap.d.ts +0 -2
  411. package/mobile/lib/retail/utils/mainFormStateMap.js.map +0 -1
@@ -2636,10 +2636,6 @@
2636
2636
  text: 'Согласие на получение информационных материалов',
2637
2637
  docId: 18,
2638
2638
  },
2639
- consentPhotoFlg: {
2640
- text: 'Согласие на фотографирование',
2641
- docId: 17,
2642
- },
2643
2639
  };
2644
2640
  const DEBIT_CARD_CONSENTS = {
2645
2641
  processPersonalDataFlg: {
@@ -2678,7 +2674,6 @@
2678
2674
  { name: 'consentInformFlg' },
2679
2675
  { name: 'consentPfrFlg' },
2680
2676
  { name: 'consentInformMaterialsFlg' },
2681
- { name: 'consentPhotoFlg' },
2682
2677
  { name: 'consentFATCA', required: true },
2683
2678
  ];
2684
2679
  return [
@@ -4451,9 +4446,7 @@
4451
4446
  updateOrganizationFields(store, field, item);
4452
4447
  }, []);
4453
4448
  useEffect(() => {
4454
- if (!esiaAccountTypeCd ||
4455
- !inn ||
4456
- !(employerActivities && employerOrganization && organization && amountWorkers)) {
4449
+ if (!esiaAccountTypeCd || !inn || !isDictionariesAlreadyLoad(store)) {
4457
4450
  return;
4458
4451
  }
4459
4452
  (async () => {
@@ -4465,6 +4458,15 @@
4465
4458
  }, [employerActivities, employerOrganization, organization, amountWorkers]);
4466
4459
  return (jsx(DaDataInputControl, { label: "\u0418\u041D\u041D", isInteger: true, maxLength: 12, ...input, ...field(input?.name ?? ''), onDaDataChange: onDaDataChange, disabled: isEsiaAuthorize(field, input) }));
4467
4460
  });
4461
+ const isDictionariesAlreadyLoad = (store) => {
4462
+ const { employerActivities, employerOrganization, organization, amountWorkers, productType } = store;
4463
+ return [
4464
+ employerOrganization,
4465
+ organization,
4466
+ amountWorkers,
4467
+ productType === 'creditCard' ? employerActivities : true,
4468
+ ].every(Boolean);
4469
+ };
4468
4470
 
4469
4471
  const DeliveryDateFiels = JSX(({ field, input }) => (jsx(DatePickerControl, { label: "\u0414\u0430\u0442\u0430 \u0434\u043E\u0441\u0442\u0430\u0432\u043A\u0438", ...field(input?.name ?? ''), minDate: new Date() })));
4470
4472
 
@@ -4576,6 +4578,8 @@
4576
4578
 
4577
4579
  const InfoCardField = JSX(({ input }) => (jsx(InfoCard, { __html: input?.label })));
4578
4580
 
4581
+ const InitiateBankruptcyFlgField = JSX(({ field, input }) => (jsx(CheckboxWithError, { text: "\u042F \u043F\u043B\u0430\u043D\u0438\u0440\u0443\u044E \u0432 \u0431\u043B\u0438\u0436\u0430\u0439\u0448\u0435\u0435 \u0432\u0440\u0435\u043C\u044F \u0438\u043D\u0438\u0446\u0438\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0434\u0435\u043B\u043E \u043E \u0431\u0430\u043D\u043A\u0440\u043E\u0442\u0441\u0442\u0432\u0435 \u0432 \u043E\u0442\u043D\u043E\u0448\u0435\u043D\u0438\u0438 \u0441\u0435\u0431\u044F", ...field(input?.name ?? '') })));
4582
+
4579
4583
  const JobsNumberField = JSX(({ field, input }) => (jsx(DaDataInputControl, { label: "\u041A\u043E\u043B\u0438\u0447\u0435\u0441\u0442\u0432\u043E \u043C\u0435\u0441\u0442 \u0440\u0430\u0431\u043E\u0442\u044B \u0437\u0430 \u043F\u043E\u0441\u043B\u0435\u0434\u043D\u0438\u0435 5 \u043B\u0435\u0442", placeholder: "\u041A\u043E\u043B\u0438\u0447\u0435\u0441\u0442\u0432\u043E \u043C\u0435\u0441\u0442", isInteger: true, maxLength: 2, ...field(input?.name ?? ''), ...input, disabled: isEsiaAuthorize(field, input) })));
4580
4584
 
4581
4585
  const LastJobExperienceField = JSX(({ field, input }) => (jsx(DaDataInputControl, { label: "\u0421\u0442\u0430\u0436 \u043D\u0430 \u043F\u043E\u0441\u043B\u0435\u0434\u043D\u0435\u043C \u0440\u0430\u0431\u043E\u0447\u0435\u043C \u043C\u0435\u0441\u0442\u0435", placeholder: "\u041A\u043E\u043B\u0438\u0447\u0435\u0441\u0442\u0432\u043E \u043B\u0435\u0442", type: "number", maxLength: 2, ...field(input?.name ?? ''), ...input, disabled: isEsiaAuthorize(field, input) })));
@@ -4914,7 +4918,6 @@
4914
4918
  consentInformFlg: ConsentField,
4915
4919
  consentPfrFlg: ConsentField,
4916
4920
  consentInformMaterialsFlg: ConsentField,
4917
- consentPhotoFlg: ConsentField,
4918
4921
  consentFATCA: ConsentField,
4919
4922
  };
4920
4923
  const InputsRetailMap = {
@@ -4961,6 +4964,7 @@
4961
4964
  wages: WagesField,
4962
4965
  mandatoryPayments: MandatoryPaymentsField,
4963
4966
  bankruptcyFlg: BankruptcyFlgField,
4967
+ initiateBankruptcyFlg: InitiateBankruptcyFlgField,
4964
4968
  shareholderFlg: ShareholderFlgField,
4965
4969
  legalEntityName: LegalEntityNameField,
4966
4970
  creditInRshbCd: CreditInRshbCdField,
@@ -5014,6 +5018,12 @@
5014
5018
 
5015
5019
  const renderSubmitButton = (button, isSending = false) => (jsx(SubmitButton$1, { className: "w-full @xl:w-auto", isLoading: isSending, children: button?.text ? button.text : 'Отправить заявку' }));
5016
5020
 
5021
+ const sessionStore = new Store(); // sessionStorage cache
5022
+ replicate(sessionStore, new StorageAdapter(globalThis?.sessionStorage));
5023
+ function useSessionStore() {
5024
+ return useStore(sessionStore);
5025
+ }
5026
+
5017
5027
  const createDraftTask = async (body) => {
5018
5028
  const res = await fetchRetailJSON('/user-data/createDraftTask', 'POST', body);
5019
5029
  return res || {};
@@ -5042,12 +5052,6 @@
5042
5052
 
5043
5053
  const updateUserTask = (body) => doRequest('/user-data/updateUserTask', 'PUT', body);
5044
5054
 
5045
- const sessionStore = new Store(); // sessionStorage cache
5046
- replicate(sessionStore, new StorageAdapter(globalThis?.sessionStorage));
5047
- function useSessionStore() {
5048
- return useStore(sessionStore);
5049
- }
5050
-
5051
5055
  const Timer = JSX(({ className, seconds }) => (jsx("span", { className: className, children: formatTimer(seconds) })));
5052
5056
  const formatTimer = (seconds) => {
5053
5057
  const minutes = Math.floor(seconds / 60);
@@ -5199,7 +5203,7 @@
5199
5203
 
5200
5204
  const checkCode = async (body) => fetchRetailJSON('/sms/checkCode', 'POST', body).then(saveToken);
5201
5205
  const saveToken = (data) => {
5202
- if (data) {
5206
+ if (data?.access_token && data?.refresh_token) {
5203
5207
  globalThis.sessionStorage.setItem('accessToken', data.access_token);
5204
5208
  globalThis.sessionStorage.setItem('refreshToken', data.refresh_token);
5205
5209
  }
@@ -5431,7 +5435,7 @@
5431
5435
  }, []);
5432
5436
 
5433
5437
  const getFamilyStatusAndIncomeData = (formData) => {
5434
- const { familyStatus, familyMembers, dependents, children, confirmationIncome, wages, mandatoryPayments, additionalIncome, otherIncome, otherPayments, rentalIncome, retirementIncome, snils, armyIdFlg, conscription, } = formData;
5438
+ const { familyStatus, familyMembers, dependents, children, confirmationIncome, wages, mandatoryPayments, additionalIncome, otherIncome, otherPayments, rentalIncome, retirementIncome, snils, armyIdFlg, conscription, initiateBankruptcyFlg, } = formData;
5435
5439
  return {
5436
5440
  maritalStatusCd: familyStatus,
5437
5441
  totalDependents: familyMembers,
@@ -5451,6 +5455,7 @@
5451
5455
  }),
5452
5456
  snils: snils?.replace(/[-\s]/g, ''),
5453
5457
  armyIdFlg,
5458
+ initiateBankruptcyFlg,
5454
5459
  };
5455
5460
  };
5456
5461
  const countIncomeAverage = (wages, retirementIncome) => (Number(wages ?? 0) + Number(retirementIncome ?? 0)).toString();
@@ -5546,10 +5551,10 @@
5546
5551
 
5547
5552
  const parseDraftTask = (task) => {
5548
5553
  const participant = task.participants[0];
5549
- const { classCard: cardCategory, codeWord, paymentSystemTypeCd: paymentSystem, currencyCode: currency, taskSource, } = task;
5554
+ const { classCard: cardCategory, codeWord, paymentSystemTypeCd: paymentSystem, currencyCode: currency, } = task;
5550
5555
  const { loanAmount: moneyValue, creditPeriod: monthsValue, paymentTypeCd } = task;
5551
5556
  const { birthDate: limitedBirthday, midname: middleName, name, surname, birthPlace, dulIssueDate: dulIssueDate, dulIssuedBy, dulNumber, dulSerie, dulSubdivisionCode, educationLevelCd: education, registrationDate: participantDateRegistration, houseTypeCd: housing, genderCd, participantContacts = [], participantAddresses = [], employmentContractDate: beginDate, employmentTypeCd: employment, organizationName, organizationInn: inn, organizationActivityTypeCd: employerActivities, organizationTypeCd: organization, organizationKindCd: employerOrganization, employeesNumberCd: amountWorkers, opf: legalForm, seniority: generalSeniority, generalSeniority: experience5Years, jobsNumber, lastWorkDuration: lastJobExperience, positionCd: positionOrganization, maritalStatusCd: familyStatus, childrenDependents: children, totalDependents: familyMembers, otherDependents: dependents, militaryStatusCd: conscription, participantIncomes, snils, armyIdFlg, bankruptcyFlg, shareholderFlg, nameLegalEntity: legalEntityName, creditInRshbCd, payrollCardRshbFlg: isInsurance, consentInsuranceFlg: isSalaryClient, incomeCertificateCd, profile, } = participant;
5552
- const taskFromDraft = {
5557
+ return {
5553
5558
  currency: currency?.key,
5554
5559
  paymentSystem: getSelectValue(paymentSystem),
5555
5560
  cardCategory: getSelectValue(cardCategory),
@@ -5606,7 +5611,6 @@
5606
5611
  ...getParticipantContacts(participantContacts),
5607
5612
  ...getParticipantGender(genderCd),
5608
5613
  };
5609
- return [taskFromDraft, taskSource === 'ReferalSF'];
5610
5614
  };
5611
5615
 
5612
5616
  const DraftDialog = JSX(function ({ task, isFromLead = false, isDebit = false, sendAspects = noop, onClose = noop, }) {
@@ -5626,13 +5630,12 @@
5626
5630
  };
5627
5631
  const { id: participantId, profile } = participants[0];
5628
5632
  const handleGoToDraft = useCallback(() => {
5629
- const [taskFromDraft, isTaskWithReferalCode] = parseDraftTask(task);
5633
+ const taskFromDraft = parseDraftTask(task);
5630
5634
  retailFormStore.participantId = participantId ?? null;
5631
5635
  retailFormStore.taskId = taskId;
5632
5636
  retailFormStore.profileId = profile?.id ?? null;
5633
5637
  retailFormStore.programId = programmId;
5634
5638
  retailFormStore.leadForm = taskFromDraft;
5635
- retailFormStore.referalData = { isTaskWithReferalCode };
5636
5639
  if (profile?.id) {
5637
5640
  sendAspects(profile.id, taskId);
5638
5641
  }
@@ -5685,10 +5688,9 @@
5685
5688
  };
5686
5689
 
5687
5690
  /* eslint-disable camelcase */
5688
- const getCreditLeadFormTaskData = ({ participantId, taskId, profileId, formData, isTaskWithReferalCode, }) => {
5691
+ const getCreditLeadFormTaskData = ({ participantId, taskId, profileId, formData, marketingInfo, }) => {
5689
5692
  const { name, surname, middleName, limitedBirthday, phone, email } = formData;
5690
- const navigator = locationNavigator();
5691
- const taskSource = isTaskWithReferalCode ? 'ReferalSF' : navigator.origin;
5693
+ const taskSource = getTaskSource(marketingInfo?.utm_source);
5692
5694
  return {
5693
5695
  sendToBank: true,
5694
5696
  taskKind: 'SHORT',
@@ -5715,14 +5717,13 @@
5715
5717
  },
5716
5718
  },
5717
5719
  ],
5718
- marketingInfo: getMarketingInfo(),
5720
+ marketingInfo,
5719
5721
  },
5720
5722
  };
5721
5723
  };
5722
- const getDebitLeadFormTaskData = (formData, programId, isTaskWithReferalCode) => {
5724
+ const getDebitLeadFormTaskData = (formData, programId, marketingInfo) => {
5723
5725
  const { name, surname, middleName, limitedBirthday, phone, email } = formData;
5724
- const navigator = locationNavigator();
5725
- const taskSource = isTaskWithReferalCode ? 'ReferalSF' : navigator.origin;
5726
+ const taskSource = getTaskSource(marketingInfo?.utm_source);
5726
5727
  return {
5727
5728
  task: {
5728
5729
  taskSource,
@@ -5741,18 +5742,24 @@
5741
5742
  }),
5742
5743
  },
5743
5744
  ],
5745
+ marketingInfo: {
5746
+ bannerId: marketingInfo?.bannerId,
5747
+ },
5744
5748
  },
5745
5749
  };
5746
5750
  };
5747
- const getMarketingInfo = () => {
5748
- const params = new URLSearchParams(decodeURIComponent(globalThis.location?.search));
5749
- return {
5750
- utm_campaign: params.get('utm_campaign'),
5751
- utm_medium: params.get('utm_medium'),
5752
- utm_source: params.get('utm_source'),
5753
- utm_content: params.get('utm_content'),
5754
- utm_term: params.get('utm_term'),
5755
- };
5751
+ const getTaskSource = (source) => {
5752
+ switch (source) {
5753
+ case 'referal_sf': {
5754
+ return 'ReferalSF';
5755
+ }
5756
+ case 'vse_svoe': {
5757
+ return 'vseSvoe';
5758
+ }
5759
+ default: {
5760
+ return globalThis.location.origin;
5761
+ }
5762
+ }
5756
5763
  };
5757
5764
 
5758
5765
  const useSaveUserData = () => {
@@ -5792,7 +5799,7 @@
5792
5799
  const [isSending, { setTrue: startSending, setFalse: endSending }] = useBool(false);
5793
5800
  const [ok, setOK] = useState();
5794
5801
  const saveUserData = useSaveUserData();
5795
- const leadFormStore = useLeadFormStore();
5802
+ const sessionStore = useSessionStore();
5796
5803
  const sendAspects = useSendLeadFormAspects({ data });
5797
5804
  const navigator = locationNavigator();
5798
5805
  const goToNextStep = useCallback(() => {
@@ -5808,7 +5815,8 @@
5808
5815
  const profileId = await createUserProfile({
5809
5816
  profile: { phone: formatPhone(transformedFormData.phone) },
5810
5817
  });
5811
- const referalData = leadFormStore.referalData;
5818
+ const referalData = sessionStore.referalData;
5819
+ const marketingInfo = sessionStore.marketingInfo;
5812
5820
  if (!profileId) {
5813
5821
  throw new Error();
5814
5822
  }
@@ -5819,6 +5827,7 @@
5819
5827
  formData: transformedFormData,
5820
5828
  productType,
5821
5829
  referalData,
5830
+ marketingInfo,
5822
5831
  saveUserData,
5823
5832
  sendAspects,
5824
5833
  });
@@ -5874,15 +5883,14 @@
5874
5883
  .filter((_) => formData[_])
5875
5884
  .map((_) => consents[_]?.text);
5876
5885
  };
5877
- const updateUserData = async ({ programId, profileId, formData, productType, referalData, saveUserData, sendAspects, }) => {
5886
+ const updateUserData = async ({ programId, profileId, formData, productType, referalData, marketingInfo, saveUserData, sendAspects, }) => {
5878
5887
  let taskId;
5879
5888
  let participantId;
5880
5889
  const transformedConsents = transformConsentsFields(formData, productType);
5881
- const isTaskWithReferalCode = referalData?.isTaskWithReferalCode;
5882
5890
  await updateUserProfile(getUpdateUserProfileData(profileId, formData, transformedConsents));
5883
5891
  try {
5884
5892
  if (productType === 'debitCard') {
5885
- const debitData = await createUserTaskDebit(getDebitLeadFormTaskData(formData, programId, isTaskWithReferalCode));
5893
+ const debitData = await createUserTaskDebit(getDebitLeadFormTaskData(formData, programId, marketingInfo));
5886
5894
  taskId = debitData.taskId;
5887
5895
  participantId = debitData.participantId;
5888
5896
  }
@@ -5898,10 +5906,10 @@
5898
5906
  taskId,
5899
5907
  profileId,
5900
5908
  formData,
5901
- isTaskWithReferalCode,
5909
+ marketingInfo,
5902
5910
  }));
5903
5911
  }
5904
- if (isTaskWithReferalCode) {
5912
+ if (referalData?.referalCode) {
5905
5913
  await saveReferalInfo({
5906
5914
  taskId,
5907
5915
  ...referalData,
@@ -5915,19 +5923,19 @@
5915
5923
  }
5916
5924
  };
5917
5925
  const transformConsentsFields = (formData, productType) => {
5918
- const { consentOthersFlg, consentPfrFlg, processPersonalDataFlg, consentInformFlg, consentProviderFlg, consentInformMaterialsFlg, consentPhotoFlg, consentFATCA, } = formData;
5926
+ const { consentOthersFlg, consentPfrFlg, processPersonalDataFlg, consentInformFlg, consentProviderFlg, consentInformMaterialsFlg, consentFATCA, } = formData;
5919
5927
  let consents;
5920
5928
  if (productType === 'credit') {
5921
5929
  consents = {
5922
- consentPhotoFlg: consentOthersFlg,
5923
5930
  consentPfrFlg: consentPfrFlg,
5924
5931
  consentInformMaterialsFlg: consentOthersFlg,
5932
+ consentPhotoFlg: false,
5925
5933
  };
5926
5934
  }
5927
5935
  else if (productType === 'creditCard') {
5928
5936
  consents = {
5929
5937
  consentInformMaterialsFlg,
5930
- consentPhotoFlg,
5938
+ consentPhotoFlg: false,
5931
5939
  };
5932
5940
  }
5933
5941
  else {
@@ -6169,10 +6177,11 @@
6169
6177
  return data.every(Boolean);
6170
6178
  };
6171
6179
 
6172
- /* eslint-disable max-lines-per-function */
6180
+ /* eslint-disable camelcase */
6173
6181
  const useInitApplicationLead = ({ inputs, productType, setEsiaStatus, esiaAuthSuccess, }) => {
6174
6182
  const leadFormStore = useLeadFormStore();
6175
6183
  const saveForm = useSetter(leadFormStore, 'leadForm');
6184
+ const sessionStore = useSessionStore();
6176
6185
  const queryFromStorage = globalThis.sessionStorage?.getItem(QUERY_STORAGE_KEY);
6177
6186
  const initialFormState = useMemo(() => getInitialFormState$1(inputs, leadFormStore.leadForm, esiaAuthSuccess), [inputs, leadFormStore.leadForm]);
6178
6187
  const requestEsiaProfile = useCallback(async (code, state) => {
@@ -6199,23 +6208,15 @@
6199
6208
  }, []);
6200
6209
  useEffect(() => {
6201
6210
  leadFormStore.productType = productType;
6202
- const { code, state, referalCode, refererCode, productId } = getLeadQueryParams(leadFormStore.referalData, queryFromStorage);
6211
+ const { code, state, referalCode, refererCode, productId, marketingInfo } = getLeadQueryParams(queryFromStorage, sessionStore);
6203
6212
  if (referalCode) {
6204
- leadFormStore.referalData = {
6213
+ sessionStore.referalData = {
6205
6214
  refererCode,
6206
6215
  referalCode,
6207
6216
  productId,
6208
- isTaskWithReferalCode: true,
6209
- };
6210
- }
6211
- else if (!code) {
6212
- leadFormStore.referalData = {
6213
- refererCode: null,
6214
- referalCode: null,
6215
- productId: null,
6216
- isTaskWithReferalCode: false,
6217
6217
  };
6218
6218
  }
6219
+ sessionStore.marketingInfo = marketingInfo;
6219
6220
  if (code && state) {
6220
6221
  requestEsiaProfile(code, state);
6221
6222
  }
@@ -6226,19 +6227,32 @@
6226
6227
  }, [queryFromStorage]);
6227
6228
  return initialFormState;
6228
6229
  };
6229
- const getLeadQueryParams = (referalData, queryFromStorage) => {
6230
+ const getLeadQueryParams = (queryFromStorage, sessionStore) => {
6231
+ const referalData = sessionStore.referalData;
6232
+ const marketingInfoFromStorage = sessionStore.marketingInfo;
6230
6233
  const queryStorage = new URLSearchParams(decodeURIComponent(queryFromStorage || ''));
6231
6234
  const code = queryStorage.get('code');
6232
6235
  const state = queryStorage.get('state');
6233
6236
  const referalCode = code ? referalData?.referalCode : queryStorage.get('referalCode');
6234
6237
  const refererCode = code ? referalData?.refererCode : queryStorage.get('refererCode');
6235
6238
  const productId = code ? referalData?.productId : queryStorage.get('productId');
6239
+ const marketingInfo = code
6240
+ ? marketingInfoFromStorage
6241
+ : {
6242
+ utm_campaign: queryStorage.get('utm_campaign'),
6243
+ utm_medium: queryStorage.get('utm_medium'),
6244
+ utm_source: queryStorage.get('utm_source'),
6245
+ utm_content: queryStorage.get('utm_content'),
6246
+ utm_term: queryStorage.get('utm_term'),
6247
+ bannerId: queryStorage.get('bannerId'),
6248
+ };
6236
6249
  return {
6237
6250
  code,
6238
6251
  state,
6239
6252
  referalCode,
6240
6253
  refererCode,
6241
6254
  productId,
6255
+ marketingInfo,
6242
6256
  };
6243
6257
  };
6244
6258
 
@@ -7905,7 +7919,7 @@
7905
7919
  }
7906
7920
  };
7907
7921
 
7908
- const mainFormStateMap = [
7922
+ const getMainFormStateMap = (isCredit = false) => [
7909
7923
  {
7910
7924
  surname: '',
7911
7925
  name: '',
@@ -7960,8 +7974,9 @@
7960
7974
  wages: undefined,
7961
7975
  mandatoryPayments: undefined,
7962
7976
  snils: '',
7963
- armyIdFlg: false,
7977
+ armyIdFlg: isCredit ? undefined : false,
7964
7978
  esiaAccountTypeCd: { key: '', text: '' },
7979
+ initiateBankruptcyFlg: isCredit ? false : undefined,
7965
7980
  },
7966
7981
  {
7967
7982
  bankruptcyFlg: false,
@@ -7977,7 +7992,7 @@
7977
7992
  currency: '810',
7978
7993
  codeWord: '',
7979
7994
  },
7980
- ...mainFormStateMap,
7995
+ ...getMainFormStateMap(),
7981
7996
  {
7982
7997
  regionRetail: { key: '', text: '' },
7983
7998
  addressRetail: { key: '', text: '' },
@@ -8018,7 +8033,7 @@
8018
8033
  employmentTypeCd: employment,
8019
8034
  organizationName,
8020
8035
  organizationInn: inn,
8021
- organizationActivityTypeCd: employerActivities,
8036
+ organizationActivityTypeCd: employerActivities?.key ? employerActivities : undefined,
8022
8037
  organizationTypeCd: organization,
8023
8038
  organizationKindCd: employerOrganization,
8024
8039
  employeesNumberCd: amountWorkers,
@@ -8027,17 +8042,17 @@
8027
8042
  generalSeniority: experience5Years,
8028
8043
  jobsNumber,
8029
8044
  lastWorkDuration: lastJobExperience,
8030
- positionCd: positionOrganization,
8045
+ positionCd: positionOrganization?.key ? positionOrganization : undefined,
8031
8046
  participantContacts: getParticipantContacts$1({
8032
8047
  organizationPhone: organizationPhone && formatPhone(organizationPhone),
8033
8048
  }),
8034
8049
  participantAddresses: getParticipantAddresses$1({ organizationAddress }),
8035
- ownershipShare: positionOrganization?.key === 'BUSINESS_OWNER' ? partInBusiness : '',
8050
+ ownershipShare: positionOrganization?.key === 'BUSINESS_OWNER' ? partInBusiness : undefined,
8036
8051
  };
8037
8052
  };
8038
8053
 
8039
8054
  const getPersonalInfoData = (formData) => {
8040
- const { name, surname, middleName, limitedBirthday = '', phone = '', email, sex, birthPlace, dulIssueDate = '', dulIssuedBy, dulNumber, dulSerie, dulSubdivisionCode, education, participantDateRegistration = '', housing, addressRegistration, addressFact, addressMatch, } = formData;
8055
+ const { name, surname, middleName, limitedBirthday = '', phone = '', email, sex, birthPlace, dulIssueDate = '', dulIssuedBy, dulNumber, dulSerie, dulSubdivisionCode, education, participantDateRegistration, housing, addressRegistration, addressFact, addressMatch, } = formData;
8041
8056
  return {
8042
8057
  birthDate: formatDate(limitedBirthday, true),
8043
8058
  midname: middleName,
@@ -8050,7 +8065,9 @@
8050
8065
  dulSerie,
8051
8066
  dulSubdivisionCode,
8052
8067
  educationLevelCd: education,
8053
- registrationDate: formatDate(participantDateRegistration, true),
8068
+ registrationDate: participantDateRegistration
8069
+ ? formatDate(participantDateRegistration, true)
8070
+ : undefined,
8054
8071
  homeMatchFlg: addressMatch,
8055
8072
  houseTypeCd: housing,
8056
8073
  participantContacts: getParticipantContacts$1({
@@ -8106,36 +8123,31 @@
8106
8123
  : {};
8107
8124
  };
8108
8125
 
8109
- const getCreditCardFormTaskData = ({ participantId, taskId, profileId, formData, step = 0, isTaskWithReferalCode, }) => {
8110
- const navigator = locationNavigator();
8111
- const taskSource = isTaskWithReferalCode ? 'ReferalSF' : navigator.origin;
8112
- return {
8113
- sendToBank: true,
8114
- taskKind: 'UNITED',
8115
- task: {
8116
- taskSource,
8117
- id: taskId,
8118
- ...getOfficeCode(formData),
8119
- authorizedAgentId: formData?.bankEmployeeCode,
8120
- participants: [
8121
- {
8122
- id: participantId,
8123
- profile: {
8124
- id: profileId,
8125
- },
8126
- roleCd: {
8127
- key: 'BORROWER',
8128
- value: 'Заемщик',
8129
- },
8130
- ...getCurrentStepData$1(step, formData),
8126
+ const getCreditCardFormTaskData = ({ participantId, taskId, profileId, formData, step = 0, }) => ({
8127
+ sendToBank: true,
8128
+ taskKind: 'UNITED',
8129
+ task: {
8130
+ id: taskId,
8131
+ ...getOfficeCode(formData),
8132
+ authorizedAgentId: formData?.bankEmployeeCode,
8133
+ participants: [
8134
+ {
8135
+ id: participantId,
8136
+ profile: {
8137
+ id: profileId,
8131
8138
  },
8132
- ],
8133
- ...getCardOptionsData(formData),
8134
- ...getDeliveryData(formData),
8135
- files: formData?.files,
8136
- },
8137
- };
8138
- };
8139
+ roleCd: {
8140
+ key: 'BORROWER',
8141
+ value: 'Заемщик',
8142
+ },
8143
+ ...getCurrentStepData$1(step, formData),
8144
+ },
8145
+ ],
8146
+ ...getCardOptionsData(formData),
8147
+ ...getDeliveryData(formData),
8148
+ files: formData?.files,
8149
+ },
8150
+ });
8139
8151
  const getCurrentStepData$1 = (step, formData) => {
8140
8152
  switch (step) {
8141
8153
  case 0:
@@ -8176,7 +8188,6 @@
8176
8188
  const handleSubmit = useCallback(async (formData) => {
8177
8189
  startSending();
8178
8190
  retailFormStore.leadForm = formData;
8179
- const referalData = retailFormStore.referalData;
8180
8191
  try {
8181
8192
  const { taskId, profileId, participantId } = retailFormStore;
8182
8193
  if (taskId && profileId && participantId) {
@@ -8186,7 +8197,6 @@
8186
8197
  profileId,
8187
8198
  step,
8188
8199
  formData: formData,
8189
- isTaskWithReferalCode: referalData?.isTaskWithReferalCode,
8190
8200
  }));
8191
8201
  resetForm(response);
8192
8202
  }
@@ -8223,7 +8233,6 @@
8223
8233
  return (jsxs("form", { onSubmit: handleSubmit, className: "space-y-m", children: [renderStep({ sections, field, step }), jsx(StepsNavigationButtons$1, { isSending: isSending, step: step, onPrevStep: onPrevStep })] }));
8224
8234
  });
8225
8235
 
8226
- /* eslint-disable max-lines */
8227
8236
  const PERSONAL_DATA = [
8228
8237
  {
8229
8238
  title: 'Персональные данные',
@@ -8259,9 +8268,6 @@
8259
8268
  },
8260
8269
  ],
8261
8270
  },
8262
- ];
8263
- const PERSONAL_INFO_CONTENT = [
8264
- ...PERSONAL_DATA,
8265
8271
  {
8266
8272
  inputs: [
8267
8273
  {
@@ -8270,6 +8276,124 @@
8270
8276
  dadata: true,
8271
8277
  filledByEsia: true,
8272
8278
  },
8279
+ ],
8280
+ },
8281
+ ];
8282
+ const DELIVERY_CARD_CONTENT = [
8283
+ {
8284
+ title: 'Регион обслуживания карты',
8285
+ columns: 1,
8286
+ inputs: [],
8287
+ },
8288
+ {
8289
+ inputs: [
8290
+ {
8291
+ name: 'regionRetail',
8292
+ required: true,
8293
+ },
8294
+ ],
8295
+ },
8296
+ {
8297
+ title: 'Способ получения',
8298
+ columns: 1,
8299
+ inputs: [],
8300
+ condition: {
8301
+ name: 'regionHasDelivery',
8302
+ values: [true],
8303
+ },
8304
+ },
8305
+ {
8306
+ inputs: [
8307
+ {
8308
+ name: 'methodObtain',
8309
+ condition: {
8310
+ name: 'regionHasDelivery',
8311
+ values: [true],
8312
+ },
8313
+ },
8314
+ ],
8315
+ },
8316
+ {
8317
+ title: 'Выбор офиса',
8318
+ columns: 1,
8319
+ inputs: [],
8320
+ condition: {
8321
+ name: 'methodObtain',
8322
+ values: ['office'],
8323
+ },
8324
+ },
8325
+ {
8326
+ title: 'Адрес доставки',
8327
+ columns: 1,
8328
+ inputs: [],
8329
+ condition: {
8330
+ name: 'methodObtain',
8331
+ values: ['courier'],
8332
+ },
8333
+ },
8334
+ {
8335
+ inputs: [
8336
+ {
8337
+ name: 'addressCourier',
8338
+ dadata: true,
8339
+ condition: {
8340
+ name: 'methodObtain',
8341
+ values: ['courier'],
8342
+ },
8343
+ required: true,
8344
+ },
8345
+ ],
8346
+ },
8347
+ {
8348
+ columns: 2,
8349
+ inputs: [
8350
+ {
8351
+ name: 'deliveryDate',
8352
+ condition: {
8353
+ name: 'methodObtain',
8354
+ values: ['courier'],
8355
+ },
8356
+ required: true,
8357
+ },
8358
+ {
8359
+ name: 'deliveryTime',
8360
+ condition: {
8361
+ name: 'methodObtain',
8362
+ values: ['courier'],
8363
+ },
8364
+ },
8365
+ ],
8366
+ },
8367
+ {
8368
+ inputs: [
8369
+ {
8370
+ name: 'comment',
8371
+ condition: {
8372
+ name: 'methodObtain',
8373
+ values: ['courier'],
8374
+ },
8375
+ },
8376
+ ],
8377
+ },
8378
+ {
8379
+ inputs: [
8380
+ {
8381
+ name: 'addressRetail',
8382
+ required: true,
8383
+ condition: {
8384
+ name: 'methodObtain',
8385
+ values: ['office'],
8386
+ },
8387
+ },
8388
+ ],
8389
+ },
8390
+ ];
8391
+
8392
+ /* eslint-disable max-lines */
8393
+ const PERSONAL_INFO_CONTENT$1 = [
8394
+ ...PERSONAL_DATA,
8395
+ {
8396
+ inputs: [
8273
8397
  {
8274
8398
  name: 'education',
8275
8399
  required: true,
@@ -8308,7 +8432,7 @@
8308
8432
  inputs: [{ name: 'addressFact', required: true, dadata: true }],
8309
8433
  },
8310
8434
  ];
8311
- const EMPLOYMENT_CONTENT = [
8435
+ const EMPLOYMENT_CONTENT$1 = [
8312
8436
  {
8313
8437
  title: 'Данные о трудоустройстве',
8314
8438
  inputs: [],
@@ -8381,7 +8505,7 @@
8381
8505
  inputs: [{ name: 'organizationAddress', required: true, dadata: true }],
8382
8506
  },
8383
8507
  ];
8384
- const FAMILY_STATUS_AND_INCOME_CONTENT = [
8508
+ const FAMILY_STATUS_AND_INCOME_CONTENT$1 = [
8385
8509
  {
8386
8510
  title: 'Семейное положение',
8387
8511
  },
@@ -8468,41 +8592,6 @@
8468
8592
  inputs: [{ name: 'creditInRshbCd' }],
8469
8593
  },
8470
8594
  ];
8471
- const COMMON_RETAIL_CONTENT = [
8472
- PERSONAL_INFO_CONTENT,
8473
- EMPLOYMENT_CONTENT,
8474
- FAMILY_STATUS_AND_INCOME_CONTENT,
8475
- ADDITIONAL_CONTENT,
8476
- ];
8477
- const DELIVERY_CREDIT_CONTENT = [
8478
- {
8479
- title: 'Отделение Банка',
8480
- columns: 1,
8481
- inputs: [],
8482
- },
8483
- {
8484
- inputs: [{ name: 'regionRetail', required: true }],
8485
- },
8486
- {
8487
- inputs: [{ name: 'addressRetail', required: true }],
8488
- },
8489
- {
8490
- title: 'Код представителя Банка',
8491
- columns: 1,
8492
- inputs: [],
8493
- },
8494
- {
8495
- inputs: [
8496
- {
8497
- name: 'infoCard',
8498
- label: 'Если представитель Банка помогал Вам в заведении заявки, введите здесь его код',
8499
- },
8500
- ],
8501
- },
8502
- {
8503
- inputs: [{ name: 'bankEmployeeCode' }],
8504
- },
8505
- ];
8506
8595
  const CREDIT_CARD_CONTENT = [
8507
8596
  {
8508
8597
  title: 'Параметры карты',
@@ -8517,151 +8606,34 @@
8517
8606
  ],
8518
8607
  },
8519
8608
  ];
8520
- const CALCULATOR_CONTENT = [
8609
+ const DELIVERY_CREDIT_CARD_CONTENT = [
8610
+ ...DELIVERY_CARD_CONTENT,
8521
8611
  {
8522
- columns: 1,
8523
8612
  inputs: [
8524
8613
  {
8525
- name: 'calculator',
8614
+ name: 'infoCard',
8615
+ label: 'Если представитель Банка помогал Вам в заведении заявки, введите здесь его код',
8616
+ condition: {
8617
+ name: 'methodObtain',
8618
+ values: ['office'],
8619
+ },
8526
8620
  },
8527
- ],
8528
- },
8529
- ];
8530
- const DELIVERY_DEBIT_CARD_CONTENT = [
8531
- {
8532
- title: 'Регион обслуживания карты',
8533
- columns: 1,
8534
- inputs: [],
8535
- },
8536
- {
8537
- inputs: [
8538
8621
  {
8539
- name: 'regionRetail',
8540
- required: true,
8541
- },
8542
- ],
8543
- },
8544
- {
8545
- title: 'Способ получения',
8546
- columns: 1,
8547
- inputs: [],
8548
- condition: {
8549
- name: 'regionHasDelivery',
8550
- values: [true],
8551
- },
8552
- },
8553
- {
8554
- inputs: [
8555
- {
8556
- name: 'methodObtain',
8557
- condition: {
8558
- name: 'regionHasDelivery',
8559
- values: [true],
8560
- },
8561
- },
8562
- ],
8563
- },
8564
- {
8565
- title: 'Выбор офиса',
8566
- columns: 1,
8567
- inputs: [],
8568
- condition: {
8569
- name: 'methodObtain',
8570
- values: ['office'],
8571
- },
8572
- },
8573
- {
8574
- title: 'Адрес доставки',
8575
- columns: 1,
8576
- inputs: [],
8577
- condition: {
8578
- name: 'methodObtain',
8579
- values: ['courier'],
8580
- },
8581
- },
8582
- {
8583
- inputs: [
8584
- {
8585
- name: 'addressCourier',
8586
- dadata: true,
8587
- condition: {
8588
- name: 'methodObtain',
8589
- values: ['courier'],
8590
- },
8591
- required: true,
8592
- },
8593
- ],
8594
- },
8595
- {
8596
- columns: 2,
8597
- inputs: [
8598
- {
8599
- name: 'deliveryDate',
8600
- condition: {
8601
- name: 'methodObtain',
8602
- values: ['courier'],
8603
- },
8604
- required: true,
8605
- },
8606
- {
8607
- name: 'deliveryTime',
8608
- condition: {
8609
- name: 'methodObtain',
8610
- values: ['courier'],
8611
- },
8612
- },
8613
- ],
8614
- },
8615
- {
8616
- inputs: [
8617
- {
8618
- name: 'comment',
8619
- condition: {
8620
- name: 'methodObtain',
8621
- values: ['courier'],
8622
- },
8623
- },
8624
- ],
8625
- },
8626
- {
8627
- inputs: [
8628
- {
8629
- name: 'addressRetail',
8630
- required: true,
8631
- condition: {
8632
- name: 'methodObtain',
8633
- values: ['office'],
8634
- },
8635
- },
8636
- ],
8637
- },
8638
- ];
8639
- const DELIVERY_CREDIT_CARD_CONTENT = [
8640
- ...DELIVERY_DEBIT_CARD_CONTENT,
8641
- {
8642
- inputs: [
8643
- {
8644
- name: 'infoCard',
8645
- label: 'Если представитель Банка помогал Вам в заведении заявки, введите здесь его код',
8646
- condition: {
8647
- name: 'methodObtain',
8648
- values: ['office'],
8649
- },
8650
- },
8651
- {
8652
- name: 'bankEmployeeCode',
8653
- condition: {
8654
- name: 'methodObtain',
8655
- values: ['office'],
8656
- },
8622
+ name: 'bankEmployeeCode',
8623
+ condition: {
8624
+ name: 'methodObtain',
8625
+ values: ['office'],
8626
+ },
8657
8627
  },
8658
8628
  ],
8659
8629
  },
8660
8630
  ];
8661
-
8662
8631
  const stepsSectionsMap$1 = [
8663
8632
  CREDIT_CARD_CONTENT,
8664
- ...COMMON_RETAIL_CONTENT,
8633
+ PERSONAL_INFO_CONTENT$1,
8634
+ EMPLOYMENT_CONTENT$1,
8635
+ FAMILY_STATUS_AND_INCOME_CONTENT$1,
8636
+ ADDITIONAL_CONTENT,
8665
8637
  DELIVERY_CREDIT_CARD_CONTENT,
8666
8638
  ];
8667
8639
 
@@ -8843,38 +8815,33 @@
8843
8815
  };
8844
8816
  };
8845
8817
 
8846
- const getCreditFormTaskData = ({ participantId, taskId, profileId, formData, step = 0, isTaskWithReferalCode, }) => {
8847
- const navigator = locationNavigator();
8848
- const taskSource = isTaskWithReferalCode ? 'ReferalSF' : navigator.origin;
8849
- return {
8850
- sendToBank: true,
8851
- taskKind: 'UNITED',
8852
- task: {
8853
- taskSource,
8854
- id: taskId,
8855
- authorizedAgentId: formData?.bankEmployeeCode,
8856
- participants: [
8857
- {
8858
- id: participantId,
8859
- profile: {
8860
- id: profileId,
8861
- },
8862
- roleCd: {
8863
- key: 'BORROWER',
8864
- value: 'Заемщик',
8865
- },
8866
- ...getCurrentStepData(step, formData),
8818
+ const getCreditFormTaskData = ({ participantId, taskId, profileId, formData, step = 0, }) => ({
8819
+ sendToBank: true,
8820
+ taskKind: 'UNITED',
8821
+ task: {
8822
+ id: taskId,
8823
+ authorizedAgentId: formData?.bankEmployeeCode,
8824
+ participants: [
8825
+ {
8826
+ id: participantId,
8827
+ profile: {
8828
+ id: profileId,
8867
8829
  },
8868
- ],
8869
- ...getCalcData(formData),
8870
- ...getDeliveryCreditData(formData),
8871
- esiaAccountTypeCd: {
8872
- key: formData?.esiaAccountTypeCd?.key,
8830
+ roleCd: {
8831
+ key: 'BORROWER',
8832
+ value: 'Заемщик',
8833
+ },
8834
+ ...getCurrentStepData(step, formData),
8873
8835
  },
8874
- files: formData?.files,
8836
+ ],
8837
+ ...getCalcData(formData),
8838
+ ...getDeliveryCreditData(formData),
8839
+ esiaAccountTypeCd: {
8840
+ key: formData?.esiaAccountTypeCd?.key,
8875
8841
  },
8876
- };
8877
- };
8842
+ files: formData?.files,
8843
+ },
8844
+ });
8878
8845
  const getCurrentStepData = (step, formData) => {
8879
8846
  switch (step) {
8880
8847
  case 0:
@@ -8885,8 +8852,6 @@
8885
8852
  return getEmploymentData(formData);
8886
8853
  case 3:
8887
8854
  return getFamilyStatusAndIncomeData(formData);
8888
- case 4:
8889
- return getAdditionalInfoData(formData);
8890
8855
  default:
8891
8856
  return {};
8892
8857
  }
@@ -8906,7 +8871,7 @@
8906
8871
  isStateEmployee: false,
8907
8872
  },
8908
8873
  },
8909
- ...mainFormStateMap,
8874
+ ...getMainFormStateMap(true),
8910
8875
  {
8911
8876
  regionRetail: { key: '', text: '' },
8912
8877
  addressRetail: undefined,
@@ -8916,7 +8881,7 @@
8916
8881
 
8917
8882
  const useCreditFormAPI = ({ step, onNextStep, onFinish, }) => {
8918
8883
  const [isSending, { setTrue: startSending, setFalse: endSending }] = useBool(false);
8919
- const isFinalStep = step === 5;
8884
+ const isFinalStep = step === 4;
8920
8885
  const retailFormStore = useRetailFormStore();
8921
8886
  const initialState = useMemo(() => getInitialFormState(step, retailFormStore.leadForm, formStateMap), [step, retailFormStore.leadForm]);
8922
8887
  const resetForm = useCallback((response) => {
@@ -8939,7 +8904,6 @@
8939
8904
  const handleSubmit = useCallback(async (formData) => {
8940
8905
  startSending();
8941
8906
  retailFormStore.leadForm = formData;
8942
- const referalData = retailFormStore.referalData;
8943
8907
  try {
8944
8908
  const { taskId, profileId, participantId } = retailFormStore;
8945
8909
  if (taskId && profileId && participantId) {
@@ -8949,7 +8913,6 @@
8949
8913
  profileId,
8950
8914
  step,
8951
8915
  formData: formData,
8952
- isTaskWithReferalCode: referalData?.isTaskWithReferalCode,
8953
8916
  }));
8954
8917
  resetForm(response);
8955
8918
  }
@@ -8988,19 +8951,207 @@
8988
8951
  return (jsxs("form", { onSubmit: handleSubmit, className: "space-y-m", children: [renderStep({ sections, field, step, params: { calcData } }), jsx(StepsNavigationButtons, { step: step, isSending: isSending, onPrevStep: onPrevStep })] }));
8989
8952
  });
8990
8953
 
8954
+ /* eslint-disable max-lines */
8955
+ const PERSONAL_INFO_CONTENT = [
8956
+ ...PERSONAL_DATA,
8957
+ {
8958
+ title: 'Адрес регистрации по месту жительства',
8959
+ columns: 1,
8960
+ inputs: [],
8961
+ },
8962
+ {
8963
+ inputs: [
8964
+ {
8965
+ name: 'addressRegistration',
8966
+ required: true,
8967
+ dadata: true,
8968
+ filledByEsia: true,
8969
+ },
8970
+ { name: 'addressMatch' },
8971
+ ],
8972
+ },
8973
+ {
8974
+ title: 'Адрес фактического проживания (место пребывания РФ)',
8975
+ inputs: [],
8976
+ },
8977
+ {
8978
+ inputs: [{ name: 'addressFact', required: true, dadata: true }],
8979
+ },
8980
+ ];
8981
+ const EMPLOYMENT_CONTENT = [
8982
+ {
8983
+ title: 'Данные о трудоустройстве',
8984
+ inputs: [],
8985
+ },
8986
+ {
8987
+ inputs: [
8988
+ {
8989
+ name: 'infoCard',
8990
+ label: 'Клиент на момент оформления заявки на кредит должен быть: официально трудоустроен более 6 месяцев, ' +
8991
+ 'если Клиент получает з/п на счет РСХБ, то трудоустроен более 3 месяцев, не должен находиться в декретном отпуске',
8992
+ },
8993
+ ],
8994
+ },
8995
+ {
8996
+ inputs: [
8997
+ { name: 'employment', required: true },
8998
+ { name: 'organizationName', required: true, dadata: true, filledByEsia: true },
8999
+ ],
9000
+ },
9001
+ {
9002
+ columns: 2,
9003
+ inputs: [
9004
+ { name: 'inn', required: true, dadata: true, filledByEsia: true },
9005
+ { name: 'legalForm', required: true },
9006
+ ],
9007
+ },
9008
+ {
9009
+ inputs: [
9010
+ { name: 'organization', required: true },
9011
+ { name: 'amountWorkers', required: true },
9012
+ ],
9013
+ },
9014
+ {
9015
+ columns: 2,
9016
+ inputs: [
9017
+ { name: 'employerOrganization', required: true },
9018
+ { name: 'jobsNumber', required: true, filledByEsia: true },
9019
+ ],
9020
+ },
9021
+ {
9022
+ inputs: [
9023
+ {
9024
+ name: 'organizationPhone',
9025
+ label: 'Телефон работодателя',
9026
+ required: true,
9027
+ },
9028
+ { name: 'beginDate', required: true, filledByEsia: true },
9029
+ ],
9030
+ },
9031
+ {
9032
+ title: 'Адрес работодателя',
9033
+ inputs: [],
9034
+ },
9035
+ {
9036
+ inputs: [{ name: 'organizationAddress', required: true, dadata: true }],
9037
+ },
9038
+ ];
9039
+ const FAMILY_STATUS_AND_INCOME_CONTENT = [
9040
+ {
9041
+ title: 'Семейное положение',
9042
+ },
9043
+ {
9044
+ columns: 1,
9045
+ inputs: [{ name: 'familyStatus', required: true }],
9046
+ },
9047
+ {
9048
+ columns: 2,
9049
+ inputs: [
9050
+ { name: 'children', required: true },
9051
+ { name: 'dependents', required: true },
9052
+ ],
9053
+ },
9054
+ {
9055
+ title: 'Совокупный доход',
9056
+ },
9057
+ {
9058
+ columns: 1,
9059
+ inputs: [
9060
+ {
9061
+ name: 'confirmationIncome',
9062
+ required: true,
9063
+ filledByEsia: true,
9064
+ },
9065
+ ],
9066
+ },
9067
+ {
9068
+ inputs: [
9069
+ {
9070
+ name: 'infoCard',
9071
+ label: 'Сумма основного и дополнительных доходов после вычета налога',
9072
+ },
9073
+ ],
9074
+ },
9075
+ {
9076
+ columns: 1,
9077
+ inputs: [{ name: 'wages', required: true, filledByEsia: true }],
9078
+ },
9079
+ {
9080
+ columns: 1,
9081
+ inputs: [
9082
+ {
9083
+ name: 'retirementIncome',
9084
+ required: true,
9085
+ condition: { name: 'employment', values: ['RETIREE'] },
9086
+ },
9087
+ ],
9088
+ },
9089
+ {
9090
+ columns: 1,
9091
+ inputs: [{ name: 'mandatoryPayments', required: true }],
9092
+ },
9093
+ {
9094
+ columns: 1,
9095
+ inputs: [{ name: 'snils', required: true }],
9096
+ },
9097
+ {
9098
+ columns: 1,
9099
+ inputs: [{ name: 'initiateBankruptcyFlg' }],
9100
+ },
9101
+ ];
9102
+ const DELIVERY_CREDIT_CONTENT = [
9103
+ {
9104
+ title: 'Отделение Банка',
9105
+ columns: 1,
9106
+ inputs: [],
9107
+ },
9108
+ {
9109
+ inputs: [{ name: 'regionRetail', required: true }],
9110
+ },
9111
+ {
9112
+ inputs: [{ name: 'addressRetail', required: true }],
9113
+ },
9114
+ {
9115
+ title: 'Код представителя Банка',
9116
+ columns: 1,
9117
+ inputs: [],
9118
+ },
9119
+ {
9120
+ inputs: [
9121
+ {
9122
+ name: 'infoCard',
9123
+ label: 'Если представитель Банка помогал Вам в заведении заявки, введите здесь его код',
9124
+ },
9125
+ ],
9126
+ },
9127
+ {
9128
+ inputs: [{ name: 'bankEmployeeCode' }],
9129
+ },
9130
+ ];
9131
+ const CALCULATOR_CONTENT = [
9132
+ {
9133
+ columns: 1,
9134
+ inputs: [
9135
+ {
9136
+ name: 'calculator',
9137
+ },
9138
+ ],
9139
+ },
9140
+ ];
8991
9141
  const stepsSectionsMap = [
8992
9142
  CALCULATOR_CONTENT,
8993
- ...COMMON_RETAIL_CONTENT,
9143
+ PERSONAL_INFO_CONTENT,
9144
+ EMPLOYMENT_CONTENT,
9145
+ FAMILY_STATUS_AND_INCOME_CONTENT,
8994
9146
  DELIVERY_CREDIT_CONTENT,
8995
9147
  ];
8996
9148
 
8997
- const STEPS = 5;
9149
+ const STEPS = 4;
8998
9150
  const STEP_TITLES = [
8999
9151
  '',
9000
9152
  'Персональные данные',
9001
9153
  'Данные о трудоустройстве',
9002
9154
  'Семейное положение и доход',
9003
- 'Дополнительные сведения',
9004
9155
  'Отделение Банка',
9005
9156
  ];
9006
9157
  const CreditForm = UniBlock(({ className, programsSource, ...rest }) => {
@@ -10396,7 +10547,7 @@
10396
10547
  slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
10397
10548
  });
10398
10549
 
10399
- const packageVersion = "0.14.865";
10550
+ const packageVersion = "0.14.866";
10400
10551
 
10401
10552
  exports.Blocks = Blocks;
10402
10553
  exports.ContentPage = ContentPage;