mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-19 14:20:31 +00:00
fix: General.
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
export default [
|
export default [
|
||||||
{ label: 'US Dollar', code: 'USD' },
|
{ name: 'US Dollar', code: 'USD' },
|
||||||
{ label: 'Euro', code: 'EUR' },
|
{ name: 'Euro', code: 'EUR' },
|
||||||
{ label: 'Libyan Dinar ', code: 'LYD' },
|
{ name: 'Libyan Dinar ', code: 'LYD' },
|
||||||
]
|
]
|
||||||
@@ -88,7 +88,7 @@ export default function PreferencesGeneralForm({}) {
|
|||||||
</FastField>
|
</FastField>
|
||||||
|
|
||||||
<FastField name={'location'}>
|
<FastField name={'location'}>
|
||||||
{({ field: { value }, meta: { error, touched } }) => (
|
{({ form, field: { value }, meta: { error, touched } }) => (
|
||||||
<FormGroup
|
<FormGroup
|
||||||
label={<T id={'business_location'} />}
|
label={<T id={'business_location'} />}
|
||||||
className={classNames(
|
className={classNames(
|
||||||
@@ -101,7 +101,9 @@ export default function PreferencesGeneralForm({}) {
|
|||||||
>
|
>
|
||||||
<ListSelect
|
<ListSelect
|
||||||
items={countriesOptions}
|
items={countriesOptions}
|
||||||
onItemSelect={(item) => {}}
|
onItemSelect={({ value }) => {
|
||||||
|
form.setFieldValue('location', value);
|
||||||
|
}}
|
||||||
selectedItem={value}
|
selectedItem={value}
|
||||||
selectedItemProp={'value'}
|
selectedItemProp={'value'}
|
||||||
defaultText={<T id={'select_business_location'} />}
|
defaultText={<T id={'select_business_location'} />}
|
||||||
@@ -130,7 +132,8 @@ export default function PreferencesGeneralForm({}) {
|
|||||||
selectedItem={value}
|
selectedItem={value}
|
||||||
selectedItemProp={'code'}
|
selectedItemProp={'code'}
|
||||||
defaultText={<T id={'select_base_currency'} />}
|
defaultText={<T id={'select_base_currency'} />}
|
||||||
textProp={'label'}
|
textProp={'name'}
|
||||||
|
labelProp={'code'}
|
||||||
popoverProps={{ minimal: true }}
|
popoverProps={{ minimal: true }}
|
||||||
/>
|
/>
|
||||||
</FormGroup>
|
</FormGroup>
|
||||||
@@ -149,11 +152,13 @@ export default function PreferencesGeneralForm({}) {
|
|||||||
>
|
>
|
||||||
<ListSelect
|
<ListSelect
|
||||||
items={fiscalYearOptions}
|
items={fiscalYearOptions}
|
||||||
selectedItemProp={'value'}
|
onItemSelect={({ value }) =>
|
||||||
textProp={'name'}
|
form.setFieldValue('fiscal_year', value)
|
||||||
defaultText={<T id={'select_fiscal_year'} />}
|
}
|
||||||
selectedItem={value}
|
selectedItem={value}
|
||||||
onItemSelect={(item) => {}}
|
selectedItemProp={'value'}
|
||||||
|
defaultText={<T id={'select_fiscal_year'} />}
|
||||||
|
textProp={'name'}
|
||||||
popoverProps={{ minimal: true }}
|
popoverProps={{ minimal: true }}
|
||||||
/>
|
/>
|
||||||
</FormGroup>
|
</FormGroup>
|
||||||
@@ -176,7 +181,9 @@ export default function PreferencesGeneralForm({}) {
|
|||||||
textProp={'name'}
|
textProp={'name'}
|
||||||
defaultText={<T id={'select_language'} />}
|
defaultText={<T id={'select_language'} />}
|
||||||
selectedItem={value}
|
selectedItem={value}
|
||||||
onItemSelect={(item) => {}}
|
onItemSelect={(item) =>
|
||||||
|
form.setFieldValue('language', item.value)
|
||||||
|
}
|
||||||
popoverProps={{ minimal: true }}
|
popoverProps={{ minimal: true }}
|
||||||
/>
|
/>
|
||||||
</FormGroup>
|
</FormGroup>
|
||||||
@@ -222,12 +229,13 @@ export default function PreferencesGeneralForm({}) {
|
|||||||
<ListSelect
|
<ListSelect
|
||||||
items={dateFormatsOptions}
|
items={dateFormatsOptions}
|
||||||
onItemSelect={(dateFormat) => {
|
onItemSelect={(dateFormat) => {
|
||||||
form.setFieldValue('date_format', dateFormat);
|
form.setFieldValue('date_format', dateFormat.value);
|
||||||
}}
|
}}
|
||||||
selectedItem={value}
|
selectedItem={value}
|
||||||
selectedItemProp={'value'}
|
selectedItemProp={'value'}
|
||||||
defaultText={<T id={'select_date_format'} />}
|
defaultText={<T id={'select_date_format'} />}
|
||||||
textProp={'name'}
|
textProp={'name'}
|
||||||
|
labelProp={'label'}
|
||||||
popoverProps={{ minimal: true }}
|
popoverProps={{ minimal: true }}
|
||||||
/>
|
/>
|
||||||
</FormGroup>
|
</FormGroup>
|
||||||
@@ -235,10 +243,7 @@ export default function PreferencesGeneralForm({}) {
|
|||||||
</FastField>
|
</FastField>
|
||||||
|
|
||||||
<div className={'card__footer'}>
|
<div className={'card__footer'}>
|
||||||
<Button
|
<Button intent={Intent.PRIMARY} type="submit">
|
||||||
intent={Intent.PRIMARY}
|
|
||||||
type="submit"
|
|
||||||
>
|
|
||||||
<T id={'save'} />
|
<T id={'save'} />
|
||||||
</Button>
|
</Button>
|
||||||
<Button onClick={handleCloseClick}>
|
<Button onClick={handleCloseClick}>
|
||||||
|
|||||||
Reference in New Issue
Block a user