- merged with master;
- fixed registartion form - added hub id; - fixed bando view for beneficiario after switching company;
This commit is contained in:
@@ -18,7 +18,6 @@ const Datepicker = ({
|
||||
disabled = false,
|
||||
timeOnly = false
|
||||
}) => {
|
||||
console.log('defaultValue', defaultValue)
|
||||
return (
|
||||
<>
|
||||
<label htmlFor={fieldName} className={classNames({ 'p-error': errors[fieldName] })}>
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
import React from 'react';
|
||||
import { classNames } from 'primereact/utils';
|
||||
import { Controller } from 'react-hook-form';
|
||||
import { InputNumber } from 'primereact/inputnumber';
|
||||
import { is } from 'ramda';
|
||||
|
||||
import { InputNumber } from 'primereact/inputnumber';
|
||||
|
||||
const NumberInput = ({
|
||||
fieldName,
|
||||
@@ -25,7 +26,7 @@ const NumberInput = ({
|
||||
const input = <Controller
|
||||
name={fieldName}
|
||||
control={control}
|
||||
defaultValue={defaultValue}
|
||||
defaultValue={is(Number, defaultValue) ? defaultValue : 0}
|
||||
rules={config}
|
||||
render={({ field, fieldState }) => (
|
||||
<InputNumber inputId={field.name}
|
||||
@@ -36,8 +37,8 @@ const NumberInput = ({
|
||||
max={max}
|
||||
locale={locale}
|
||||
useGrouping={useGrouping}
|
||||
maxFractionDigits={maxFractionDigits}
|
||||
minFractionDigits={minFractionDigits}
|
||||
maxFractionDigits={!isNaN(parseInt(maxFractionDigits)) ? parseInt(maxFractionDigits) : 0}
|
||||
minFractionDigits={!isNaN(parseInt(minFractionDigits)) ? parseInt(minFractionDigits) : 0}
|
||||
className={classNames({ 'p-invalid': fieldState.invalid })}/>
|
||||
)}/>
|
||||
return (
|
||||
|
||||
@@ -86,7 +86,7 @@ const TopBarProfileMenu = ({ menuLeftRef }) => {
|
||||
const switchCompany = (id) => {
|
||||
if (chosenCompanyId !== id) {
|
||||
storeSet.main.chosenCompanyId(id);
|
||||
console.log('set company 2', id)
|
||||
|
||||
if (toast.current) {
|
||||
toast.current.show({
|
||||
severity: 'success',
|
||||
|
||||
Reference in New Issue
Block a user