mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-21 15:20:34 +00:00
feat: style the banking service
This commit is contained in:
@@ -20,4 +20,5 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
flex: 1 1 auto;
|
flex: 1 1 auto;
|
||||||
|
background-color: #fff;
|
||||||
}
|
}
|
||||||
@@ -106,6 +106,10 @@ const DashboardConstrantTable = styled(DataTable)`
|
|||||||
.thead {
|
.thead {
|
||||||
.th {
|
.th {
|
||||||
background: #fff;
|
background: #fff;
|
||||||
|
letter-spacing: 1px;
|
||||||
|
text-transform: uppercase;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 13px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -120,6 +120,10 @@ const DashboardConstrantTable = styled(DataTable)`
|
|||||||
.thead {
|
.thead {
|
||||||
.th {
|
.th {
|
||||||
background: #fff;
|
background: #fff;
|
||||||
|
text-transform: uppercase;
|
||||||
|
letter-spacing: 1px;
|
||||||
|
font-size: 13px;i
|
||||||
|
font-weight: 500;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -55,14 +55,17 @@ export function useUncategorizedTransactionsColumns() {
|
|||||||
Header: 'Date',
|
Header: 'Date',
|
||||||
accessor: 'formatted_date',
|
accessor: 'formatted_date',
|
||||||
width: 110,
|
width: 110,
|
||||||
|
textOverview: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
Header: 'Description',
|
Header: 'Description',
|
||||||
accessor: descriptionAccessor,
|
accessor: descriptionAccessor,
|
||||||
|
textOverview: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
Header: 'Payee',
|
Header: 'Payee',
|
||||||
accessor: 'payee',
|
accessor: 'payee',
|
||||||
|
textOverview: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
Header: 'Recognize',
|
Header: 'Recognize',
|
||||||
@@ -72,6 +75,7 @@ export function useUncategorizedTransactionsColumns() {
|
|||||||
{
|
{
|
||||||
Header: 'Rule',
|
Header: 'Rule',
|
||||||
accessor: 'bank_rule_name',
|
accessor: 'bank_rule_name',
|
||||||
|
textOverview: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
Header: 'Deposit',
|
Header: 'Deposit',
|
||||||
|
|||||||
@@ -1,11 +1,10 @@
|
|||||||
// @ts-nocheck
|
// @ts-nocheck
|
||||||
import styled from 'styled-components';
|
import styled from 'styled-components';
|
||||||
import { DrawerBody } from '@/components';
|
|
||||||
import { CategorizeTransactionBoot } from './CategorizeTransactionBoot';
|
import { CategorizeTransactionBoot } from './CategorizeTransactionBoot';
|
||||||
import { CategorizeTransactionForm } from './CategorizeTransactionForm';
|
import { CategorizeTransactionForm } from './CategorizeTransactionForm';
|
||||||
import { useCategorizeTransactionTabsBoot } from '@/containers/CashFlow/CategorizeTransactionAside/CategorizeTransactionTabsBoot';
|
import { useCategorizeTransactionTabsBoot } from '@/containers/CashFlow/CategorizeTransactionAside/CategorizeTransactionTabsBoot';
|
||||||
|
|
||||||
export function CategorizeTransactionContent({}) {
|
export function CategorizeTransactionContent() {
|
||||||
const { uncategorizedTransactionId } = useCategorizeTransactionTabsBoot();
|
const { uncategorizedTransactionId } = useCategorizeTransactionTabsBoot();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@@ -19,7 +18,8 @@ export function CategorizeTransactionContent({}) {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
const CategorizeTransactionDrawerBody = styled(DrawerBody)`
|
const CategorizeTransactionDrawerBody = styled.div`
|
||||||
padding: 20px;
|
display: flex;
|
||||||
background-color: #fff;
|
flex-direction: column;
|
||||||
|
flex: 1 1 auto;
|
||||||
`;
|
`;
|
||||||
|
|||||||
@@ -63,18 +63,16 @@ function CategorizeTransactionFormRoot({
|
|||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<DivRoot>
|
<Formik
|
||||||
<Formik
|
validationSchema={CreateCategorizeTransactionSchema}
|
||||||
validationSchema={CreateCategorizeTransactionSchema}
|
initialValues={initialValues}
|
||||||
initialValues={initialValues}
|
onSubmit={handleFormSubmit}
|
||||||
onSubmit={handleFormSubmit}
|
>
|
||||||
>
|
<FormRoot>
|
||||||
<Form>
|
<CategorizeTransactionFormContent />
|
||||||
<CategorizeTransactionFormContent />
|
<CategorizeTransactionFormFooter />
|
||||||
<CategorizeTransactionFormFooter />
|
</FormRoot>
|
||||||
</Form>
|
</Formik>
|
||||||
</Formik>
|
|
||||||
</DivRoot>
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -82,7 +80,11 @@ export const CategorizeTransactionForm = compose(withBankingActions)(
|
|||||||
CategorizeTransactionFormRoot,
|
CategorizeTransactionFormRoot,
|
||||||
);
|
);
|
||||||
|
|
||||||
const DivRoot = styled.div`
|
const FormRoot = styled(Form)`
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
flex: 1 1 auto;
|
||||||
|
|
||||||
.bp4-form-group .bp4-form-content {
|
.bp4-form-group .bp4-form-content {
|
||||||
flex: 1 0;
|
flex: 1 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
import React from 'react';
|
import React from 'react';
|
||||||
import styled from 'styled-components';
|
import styled from 'styled-components';
|
||||||
import { FormGroup } from '@blueprintjs/core';
|
import { FormGroup } from '@blueprintjs/core';
|
||||||
import { FFormGroup, FSelect, } from '@/components';
|
import { Box, FFormGroup, FSelect } from '@/components';
|
||||||
import { getAddMoneyInOptions, getAddMoneyOutOptions } from '@/constants';
|
import { getAddMoneyInOptions, getAddMoneyOutOptions } from '@/constants';
|
||||||
import { useFormikContext } from 'formik';
|
import { useFormikContext } from 'formik';
|
||||||
import { useCategorizeTransactionTabsBoot } from '@/containers/CashFlow/CategorizeTransactionAside/CategorizeTransactionTabsBoot';
|
import { useCategorizeTransactionTabsBoot } from '@/containers/CashFlow/CategorizeTransactionAside/CategorizeTransactionTabsBoot';
|
||||||
@@ -25,7 +25,7 @@ export function CategorizeTransactionFormContent() {
|
|||||||
: MoneyOutOptions;
|
: MoneyOutOptions;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<Box style={{ flex: 1, margin: 20 }}>
|
||||||
<FormGroup label={'Amount'} inline>
|
<FormGroup label={'Amount'} inline>
|
||||||
<Title>{uncategorizedTransaction.formatted_amount}</Title>
|
<Title>{uncategorizedTransaction.formatted_amount}</Title>
|
||||||
</FormGroup>
|
</FormGroup>
|
||||||
@@ -42,7 +42,7 @@ export function CategorizeTransactionFormContent() {
|
|||||||
</FFormGroup>
|
</FFormGroup>
|
||||||
|
|
||||||
<CategorizeTransactionFormSubContent />
|
<CategorizeTransactionFormSubContent />
|
||||||
</>
|
</Box>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
// @ts-nocheck
|
// @ts-nocheck
|
||||||
import * as R from 'ramda';
|
import * as R from 'ramda';
|
||||||
import { Button, Classes, Intent } from '@blueprintjs/core';
|
import { Button, Intent } from '@blueprintjs/core';
|
||||||
import { useFormikContext } from 'formik';
|
import { useFormikContext } from 'formik';
|
||||||
import styled from 'styled-components';
|
import styled from 'styled-components';
|
||||||
import { Group } from '@/components';
|
import { Group } from '@/components';
|
||||||
@@ -18,26 +18,24 @@ function CategorizeTransactionFormFooterRoot({
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<Root>
|
<Root>
|
||||||
<div className={Classes.DRAWER_FOOTER}>
|
<Group spacing={10}>
|
||||||
<Group spacing={10}>
|
<Button
|
||||||
<Button
|
intent={Intent.PRIMARY}
|
||||||
intent={Intent.PRIMARY}
|
style={{ minWidth: '85px' }}
|
||||||
style={{ minWidth: '75px' }}
|
loading={isSubmitting}
|
||||||
loading={isSubmitting}
|
type="submit"
|
||||||
type="submit"
|
>
|
||||||
>
|
Save
|
||||||
Save
|
</Button>
|
||||||
</Button>
|
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
disabled={isSubmitting}
|
disabled={isSubmitting}
|
||||||
onClick={handleClose}
|
onClick={handleClose}
|
||||||
style={{ minWidth: '75px' }}
|
style={{ minWidth: '75px' }}
|
||||||
>
|
>
|
||||||
Close
|
Close
|
||||||
</Button>
|
</Button>
|
||||||
</Group>
|
</Group>
|
||||||
</div>
|
|
||||||
</Root>
|
</Root>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -47,9 +45,6 @@ export const CategorizeTransactionFormFooter = R.compose(withBankingActions)(
|
|||||||
);
|
);
|
||||||
|
|
||||||
const Root = styled.div`
|
const Root = styled.div`
|
||||||
// position: absolute;
|
border-top: 1px solid #c7d5db;
|
||||||
// bottom: 0;
|
padding: 14px 20px;
|
||||||
// left: 0;
|
|
||||||
// right: 0;
|
|
||||||
// background: #fff;
|
|
||||||
`;
|
`;
|
||||||
|
|||||||
Reference in New Issue
Block a user