@things-factory/accounting 7.0.1-alpha.4 → 7.0.1-alpha.40
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.
- package/client/pages/account/account-importer.ts +7 -18
- package/client/pages/account/account-list-page.ts +6 -5
- package/client/pages/accounting-category/accounting-category-importer.ts +7 -18
- package/client/pages/accounting-category/accounting-category-list-page.ts +5 -5
- package/client/pages/financial-statement/financial-statement-importer.ts +7 -18
- package/client/pages/financial-statement/financial-statement-list-page.ts +6 -5
- package/client/pages/income-statement/income-statement-importer.ts +7 -18
- package/client/pages/income-statement/income-statement-list-page.ts +6 -5
- package/client/pages/ledger/ledger-importer.ts +7 -18
- package/client/pages/ledger/ledger-list-page.ts +6 -5
- package/client/pages/transaction/transaction-importer.ts +7 -18
- package/client/pages/transaction/transaction-list-page.ts +6 -5
- package/dist-client/pages/account/account-importer.d.ts +1 -0
- package/dist-client/pages/account/account-importer.js +4 -11
- package/dist-client/pages/account/account-importer.js.map +1 -1
- package/dist-client/pages/account/account-list-page.js +6 -5
- package/dist-client/pages/account/account-list-page.js.map +1 -1
- package/dist-client/pages/accounting-category/accounting-category-importer.d.ts +1 -0
- package/dist-client/pages/accounting-category/accounting-category-importer.js +4 -11
- package/dist-client/pages/accounting-category/accounting-category-importer.js.map +1 -1
- package/dist-client/pages/accounting-category/accounting-category-list-page.js +5 -5
- package/dist-client/pages/accounting-category/accounting-category-list-page.js.map +1 -1
- package/dist-client/pages/financial-statement/financial-statement-importer.d.ts +1 -0
- package/dist-client/pages/financial-statement/financial-statement-importer.js +4 -11
- package/dist-client/pages/financial-statement/financial-statement-importer.js.map +1 -1
- package/dist-client/pages/financial-statement/financial-statement-list-page.js +6 -5
- package/dist-client/pages/financial-statement/financial-statement-list-page.js.map +1 -1
- package/dist-client/pages/income-statement/income-statement-importer.d.ts +1 -0
- package/dist-client/pages/income-statement/income-statement-importer.js +4 -11
- package/dist-client/pages/income-statement/income-statement-importer.js.map +1 -1
- package/dist-client/pages/income-statement/income-statement-list-page.js +6 -5
- package/dist-client/pages/income-statement/income-statement-list-page.js.map +1 -1
- package/dist-client/pages/ledger/ledger-importer.d.ts +1 -0
- package/dist-client/pages/ledger/ledger-importer.js +4 -11
- package/dist-client/pages/ledger/ledger-importer.js.map +1 -1
- package/dist-client/pages/ledger/ledger-list-page.js +6 -5
- package/dist-client/pages/ledger/ledger-list-page.js.map +1 -1
- package/dist-client/pages/transaction/transaction-importer.d.ts +1 -0
- package/dist-client/pages/transaction/transaction-importer.js +4 -11
- package/dist-client/pages/transaction/transaction-importer.js.map +1 -1
- package/dist-client/pages/transaction/transaction-list-page.js +6 -5
- package/dist-client/pages/transaction/transaction-list-page.js.map +1 -1
- package/dist-client/tsconfig.tsbuildinfo +1 -1
- package/dist-server/tsconfig.tsbuildinfo +1 -1
- package/package.json +5 -5
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import '@material/web/icon/icon.js'
|
|
1
2
|
import '@operato/data-grist'
|
|
2
3
|
|
|
3
4
|
import gql from 'graphql-tag'
|
|
@@ -7,9 +8,11 @@ import { property } from 'lit/decorators.js'
|
|
|
7
8
|
import { client } from '@operato/graphql'
|
|
8
9
|
import { i18next } from '@operato/i18n'
|
|
9
10
|
import { isMobileDevice } from '@operato/utils'
|
|
11
|
+
import { ButtonContainerStyles } from '@operato/styles'
|
|
10
12
|
|
|
11
13
|
export class AccountImporter extends LitElement {
|
|
12
14
|
static styles = [
|
|
15
|
+
ButtonContainerStyles,
|
|
13
16
|
css`
|
|
14
17
|
:host {
|
|
15
18
|
display: flex;
|
|
@@ -21,16 +24,6 @@ export class AccountImporter extends LitElement {
|
|
|
21
24
|
ox-grist {
|
|
22
25
|
flex: 1;
|
|
23
26
|
}
|
|
24
|
-
|
|
25
|
-
.button-container {
|
|
26
|
-
display: flex;
|
|
27
|
-
margin-left: auto;
|
|
28
|
-
padding: var(--padding-default);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
mwc-button {
|
|
32
|
-
margin-left: var(--margin-default);
|
|
33
|
-
}
|
|
34
27
|
`
|
|
35
28
|
]
|
|
36
29
|
|
|
@@ -60,21 +53,18 @@ export class AccountImporter extends LitElement {
|
|
|
60
53
|
]
|
|
61
54
|
}
|
|
62
55
|
|
|
63
|
-
|
|
64
56
|
render() {
|
|
65
57
|
return html`
|
|
66
58
|
<ox-grist
|
|
67
59
|
.mode=${isMobileDevice() ? 'LIST' : 'GRID'}
|
|
68
60
|
.config=${this.columns}
|
|
69
|
-
.data=${
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
}
|
|
73
|
-
}
|
|
61
|
+
.data=${{
|
|
62
|
+
records: this.accounts
|
|
63
|
+
}}
|
|
74
64
|
></ox-grist>
|
|
75
65
|
|
|
76
66
|
<div class="button-container">
|
|
77
|
-
<
|
|
67
|
+
<button @click="${this.save.bind(this)}"><md-icon>save</md-icon>${i18next.t('button.save')}</button>
|
|
78
68
|
</div>
|
|
79
69
|
`
|
|
80
70
|
}
|
|
@@ -94,4 +84,3 @@ export class AccountImporter extends LitElement {
|
|
|
94
84
|
this.dispatchEvent(new CustomEvent('imported'))
|
|
95
85
|
}
|
|
96
86
|
}
|
|
97
|
-
|
|
@@ -96,7 +96,7 @@ export class AccountListPage extends connect(store)(localize(i18next)(ScopedElem
|
|
|
96
96
|
|
|
97
97
|
<div id="sorters">
|
|
98
98
|
Sort
|
|
99
|
-
<
|
|
99
|
+
<md-icon
|
|
100
100
|
@click=${e => {
|
|
101
101
|
const target = e.currentTarget
|
|
102
102
|
this.sortersControl.open({
|
|
@@ -104,7 +104,7 @@ export class AccountListPage extends connect(store)(localize(i18next)(ScopedElem
|
|
|
104
104
|
top: target.offsetTop + target.offsetHeight
|
|
105
105
|
})
|
|
106
106
|
}}
|
|
107
|
-
>expand_more</
|
|
107
|
+
>expand_more</md-icon
|
|
108
108
|
>
|
|
109
109
|
<ox-popup id="sorter-control">
|
|
110
110
|
<ox-sorters-control> </ox-sorters-control>
|
|
@@ -112,9 +112,10 @@ export class AccountListPage extends connect(store)(localize(i18next)(ScopedElem
|
|
|
112
112
|
</div>
|
|
113
113
|
|
|
114
114
|
<div id="modes">
|
|
115
|
-
<
|
|
116
|
-
<
|
|
117
|
-
<
|
|
115
|
+
<md-icon @click=${() => (this.mode = 'GRID')} ?active=${mode == 'GRID'}>grid_on</md-icon>
|
|
116
|
+
<md-icon @click=${() => (this.mode = 'LIST')} ?active=${mode == 'LIST'}>format_list_bulleted</md-icon>
|
|
117
|
+
<md-icon @click=${() => (this.mode = 'CARD')} ?active=${mode == 'CARD'}>apps</md-icon>
|
|
118
|
+
</div>
|
|
118
119
|
</div>
|
|
119
120
|
</div>
|
|
120
121
|
</ox-grist>
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import '@material/web/icon/icon.js'
|
|
1
2
|
import '@operato/data-grist'
|
|
2
3
|
|
|
3
4
|
import gql from 'graphql-tag'
|
|
@@ -7,9 +8,11 @@ import { property } from 'lit/decorators.js'
|
|
|
7
8
|
import { client } from '@operato/graphql'
|
|
8
9
|
import { i18next } from '@operato/i18n'
|
|
9
10
|
import { isMobileDevice } from '@operato/utils'
|
|
11
|
+
import { ButtonContainerStyles } from '@operato/styles'
|
|
10
12
|
|
|
11
13
|
export class AccountingCategoryImporter extends LitElement {
|
|
12
14
|
static styles = [
|
|
15
|
+
ButtonContainerStyles,
|
|
13
16
|
css`
|
|
14
17
|
:host {
|
|
15
18
|
display: flex;
|
|
@@ -21,16 +24,6 @@ export class AccountingCategoryImporter extends LitElement {
|
|
|
21
24
|
ox-grist {
|
|
22
25
|
flex: 1;
|
|
23
26
|
}
|
|
24
|
-
|
|
25
|
-
.button-container {
|
|
26
|
-
display: flex;
|
|
27
|
-
margin-left: auto;
|
|
28
|
-
padding: var(--padding-default);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
mwc-button {
|
|
32
|
-
margin-left: var(--margin-default);
|
|
33
|
-
}
|
|
34
27
|
`
|
|
35
28
|
]
|
|
36
29
|
|
|
@@ -60,21 +53,18 @@ export class AccountingCategoryImporter extends LitElement {
|
|
|
60
53
|
]
|
|
61
54
|
}
|
|
62
55
|
|
|
63
|
-
|
|
64
56
|
render() {
|
|
65
57
|
return html`
|
|
66
58
|
<ox-grist
|
|
67
59
|
.mode=${isMobileDevice() ? 'LIST' : 'GRID'}
|
|
68
60
|
.config=${this.columns}
|
|
69
|
-
.data=${
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
}
|
|
73
|
-
}
|
|
61
|
+
.data=${{
|
|
62
|
+
records: this.accountingCategories
|
|
63
|
+
}}
|
|
74
64
|
></ox-grist>
|
|
75
65
|
|
|
76
66
|
<div class="button-container">
|
|
77
|
-
<
|
|
67
|
+
<button @click="${this.save.bind(this)}"><md-icon>save</md-icon>${i18next.t('button.save')}</button>
|
|
78
68
|
</div>
|
|
79
69
|
`
|
|
80
70
|
}
|
|
@@ -94,4 +84,3 @@ export class AccountingCategoryImporter extends LitElement {
|
|
|
94
84
|
this.dispatchEvent(new CustomEvent('imported'))
|
|
95
85
|
}
|
|
96
86
|
}
|
|
97
|
-
|
|
@@ -101,7 +101,7 @@ export class AccountingCategoryListPage extends connect(store)(localize(i18next)
|
|
|
101
101
|
|
|
102
102
|
<div id="sorters">
|
|
103
103
|
Sort
|
|
104
|
-
<
|
|
104
|
+
<md-icon
|
|
105
105
|
@click=${e => {
|
|
106
106
|
const target = e.currentTarget
|
|
107
107
|
this.sortersControl.open({
|
|
@@ -109,7 +109,7 @@ export class AccountingCategoryListPage extends connect(store)(localize(i18next)
|
|
|
109
109
|
top: target.offsetTop + target.offsetHeight
|
|
110
110
|
})
|
|
111
111
|
}}
|
|
112
|
-
>expand_more</
|
|
112
|
+
>expand_more</md-icon
|
|
113
113
|
>
|
|
114
114
|
<ox-popup id="sorter-control">
|
|
115
115
|
<ox-sorters-control> </ox-sorters-control>
|
|
@@ -117,9 +117,9 @@ export class AccountingCategoryListPage extends connect(store)(localize(i18next)
|
|
|
117
117
|
</div>
|
|
118
118
|
|
|
119
119
|
<div id="modes">
|
|
120
|
-
<
|
|
121
|
-
<
|
|
122
|
-
<
|
|
120
|
+
<md-icon @click=${() => (this.mode = 'GRID')} ?active=${mode == 'GRID'}>grid_on</md-icon>
|
|
121
|
+
<md-icon @click=${() => (this.mode = 'LIST')} ?active=${mode == 'LIST'}>format_list_bulleted</md-icon>
|
|
122
|
+
<md-icon @click=${() => (this.mode = 'CARD')} ?active=${mode == 'CARD'}>apps</md-icon>
|
|
123
123
|
</div>
|
|
124
124
|
</div>
|
|
125
125
|
</ox-grist>
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import '@material/web/icon/icon.js'
|
|
1
2
|
import '@operato/data-grist'
|
|
2
3
|
|
|
3
4
|
import gql from 'graphql-tag'
|
|
@@ -7,9 +8,11 @@ import { property } from 'lit/decorators.js'
|
|
|
7
8
|
import { client } from '@operato/graphql'
|
|
8
9
|
import { i18next } from '@operato/i18n'
|
|
9
10
|
import { isMobileDevice } from '@operato/utils'
|
|
11
|
+
import { ButtonContainerStyles } from '@operato/styles'
|
|
10
12
|
|
|
11
13
|
export class FinancialStatementImporter extends LitElement {
|
|
12
14
|
static styles = [
|
|
15
|
+
ButtonContainerStyles,
|
|
13
16
|
css`
|
|
14
17
|
:host {
|
|
15
18
|
display: flex;
|
|
@@ -21,16 +24,6 @@ export class FinancialStatementImporter extends LitElement {
|
|
|
21
24
|
ox-grist {
|
|
22
25
|
flex: 1;
|
|
23
26
|
}
|
|
24
|
-
|
|
25
|
-
.button-container {
|
|
26
|
-
display: flex;
|
|
27
|
-
margin-left: auto;
|
|
28
|
-
padding: var(--padding-default);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
mwc-button {
|
|
32
|
-
margin-left: var(--margin-default);
|
|
33
|
-
}
|
|
34
27
|
`
|
|
35
28
|
]
|
|
36
29
|
|
|
@@ -60,21 +53,18 @@ export class FinancialStatementImporter extends LitElement {
|
|
|
60
53
|
]
|
|
61
54
|
}
|
|
62
55
|
|
|
63
|
-
|
|
64
56
|
render() {
|
|
65
57
|
return html`
|
|
66
58
|
<ox-grist
|
|
67
59
|
.mode=${isMobileDevice() ? 'LIST' : 'GRID'}
|
|
68
60
|
.config=${this.columns}
|
|
69
|
-
.data=${
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
}
|
|
73
|
-
}
|
|
61
|
+
.data=${{
|
|
62
|
+
records: this.financialStatements
|
|
63
|
+
}}
|
|
74
64
|
></ox-grist>
|
|
75
65
|
|
|
76
66
|
<div class="button-container">
|
|
77
|
-
<
|
|
67
|
+
<button @click="${this.save.bind(this)}"><md-icon>save</md-icon>${i18next.t('button.save')}</button>
|
|
78
68
|
</div>
|
|
79
69
|
`
|
|
80
70
|
}
|
|
@@ -94,4 +84,3 @@ export class FinancialStatementImporter extends LitElement {
|
|
|
94
84
|
this.dispatchEvent(new CustomEvent('imported'))
|
|
95
85
|
}
|
|
96
86
|
}
|
|
97
|
-
|
|
@@ -101,7 +101,7 @@ export class FinancialStatementListPage extends connect(store)(localize(i18next)
|
|
|
101
101
|
|
|
102
102
|
<div id="sorters">
|
|
103
103
|
Sort
|
|
104
|
-
<
|
|
104
|
+
<md-icon
|
|
105
105
|
@click=${e => {
|
|
106
106
|
const target = e.currentTarget
|
|
107
107
|
this.sortersControl.open({
|
|
@@ -109,7 +109,7 @@ export class FinancialStatementListPage extends connect(store)(localize(i18next)
|
|
|
109
109
|
top: target.offsetTop + target.offsetHeight
|
|
110
110
|
})
|
|
111
111
|
}}
|
|
112
|
-
>expand_more</
|
|
112
|
+
>expand_more</md-icon
|
|
113
113
|
>
|
|
114
114
|
<ox-popup id="sorter-control">
|
|
115
115
|
<ox-sorters-control> </ox-sorters-control>
|
|
@@ -117,9 +117,10 @@ export class FinancialStatementListPage extends connect(store)(localize(i18next)
|
|
|
117
117
|
</div>
|
|
118
118
|
|
|
119
119
|
<div id="modes">
|
|
120
|
-
<
|
|
121
|
-
<
|
|
122
|
-
<
|
|
120
|
+
<md-icon @click=${() => (this.mode = 'GRID')} ?active=${mode == 'GRID'}>grid_on</md-icon>
|
|
121
|
+
<md-icon @click=${() => (this.mode = 'LIST')} ?active=${mode == 'LIST'}>format_list_bulleted</md-icon>
|
|
122
|
+
<md-icon @click=${() => (this.mode = 'CARD')} ?active=${mode == 'CARD'}>apps</md-icon>
|
|
123
|
+
</div>
|
|
123
124
|
</div>
|
|
124
125
|
</div>
|
|
125
126
|
</ox-grist>
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import '@material/web/icon/icon.js'
|
|
1
2
|
import '@operato/data-grist'
|
|
2
3
|
|
|
3
4
|
import gql from 'graphql-tag'
|
|
@@ -7,9 +8,11 @@ import { property } from 'lit/decorators.js'
|
|
|
7
8
|
import { client } from '@operato/graphql'
|
|
8
9
|
import { i18next } from '@operato/i18n'
|
|
9
10
|
import { isMobileDevice } from '@operato/utils'
|
|
11
|
+
import { ButtonContainerStyles } from '@operato/styles'
|
|
10
12
|
|
|
11
13
|
export class IncomeStatementImporter extends LitElement {
|
|
12
14
|
static styles = [
|
|
15
|
+
ButtonContainerStyles,
|
|
13
16
|
css`
|
|
14
17
|
:host {
|
|
15
18
|
display: flex;
|
|
@@ -21,16 +24,6 @@ export class IncomeStatementImporter extends LitElement {
|
|
|
21
24
|
ox-grist {
|
|
22
25
|
flex: 1;
|
|
23
26
|
}
|
|
24
|
-
|
|
25
|
-
.button-container {
|
|
26
|
-
display: flex;
|
|
27
|
-
margin-left: auto;
|
|
28
|
-
padding: var(--padding-default);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
mwc-button {
|
|
32
|
-
margin-left: var(--margin-default);
|
|
33
|
-
}
|
|
34
27
|
`
|
|
35
28
|
]
|
|
36
29
|
|
|
@@ -60,21 +53,18 @@ export class IncomeStatementImporter extends LitElement {
|
|
|
60
53
|
]
|
|
61
54
|
}
|
|
62
55
|
|
|
63
|
-
|
|
64
56
|
render() {
|
|
65
57
|
return html`
|
|
66
58
|
<ox-grist
|
|
67
59
|
.mode=${isMobileDevice() ? 'LIST' : 'GRID'}
|
|
68
60
|
.config=${this.columns}
|
|
69
|
-
.data=${
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
}
|
|
73
|
-
}
|
|
61
|
+
.data=${{
|
|
62
|
+
records: this.incomeStatements
|
|
63
|
+
}}
|
|
74
64
|
></ox-grist>
|
|
75
65
|
|
|
76
66
|
<div class="button-container">
|
|
77
|
-
<
|
|
67
|
+
<button @click="${this.save.bind(this)}"><md-icon>save</md-icon>${i18next.t('button.save')}</button>
|
|
78
68
|
</div>
|
|
79
69
|
`
|
|
80
70
|
}
|
|
@@ -94,4 +84,3 @@ export class IncomeStatementImporter extends LitElement {
|
|
|
94
84
|
this.dispatchEvent(new CustomEvent('imported'))
|
|
95
85
|
}
|
|
96
86
|
}
|
|
97
|
-
|
|
@@ -101,7 +101,7 @@ export class IncomeStatementListPage extends connect(store)(localize(i18next)(Sc
|
|
|
101
101
|
|
|
102
102
|
<div id="sorters">
|
|
103
103
|
Sort
|
|
104
|
-
<
|
|
104
|
+
<md-icon
|
|
105
105
|
@click=${e => {
|
|
106
106
|
const target = e.currentTarget
|
|
107
107
|
this.sortersControl.open({
|
|
@@ -109,7 +109,7 @@ export class IncomeStatementListPage extends connect(store)(localize(i18next)(Sc
|
|
|
109
109
|
top: target.offsetTop + target.offsetHeight
|
|
110
110
|
})
|
|
111
111
|
}}
|
|
112
|
-
>expand_more</
|
|
112
|
+
>expand_more</md-icon
|
|
113
113
|
>
|
|
114
114
|
<ox-popup id="sorter-control">
|
|
115
115
|
<ox-sorters-control> </ox-sorters-control>
|
|
@@ -117,9 +117,10 @@ export class IncomeStatementListPage extends connect(store)(localize(i18next)(Sc
|
|
|
117
117
|
</div>
|
|
118
118
|
|
|
119
119
|
<div id="modes">
|
|
120
|
-
<
|
|
121
|
-
<
|
|
122
|
-
<
|
|
120
|
+
<md-icon @click=${() => (this.mode = 'GRID')} ?active=${mode == 'GRID'}>grid_on</md-icon>
|
|
121
|
+
<md-icon @click=${() => (this.mode = 'LIST')} ?active=${mode == 'LIST'}>format_list_bulleted</md-icon>
|
|
122
|
+
<md-icon @click=${() => (this.mode = 'CARD')} ?active=${mode == 'CARD'}>apps</md-icon>
|
|
123
|
+
</div>
|
|
123
124
|
</div>
|
|
124
125
|
</div>
|
|
125
126
|
</ox-grist>
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import '@material/web/icon/icon.js'
|
|
1
2
|
import '@operato/data-grist'
|
|
2
3
|
|
|
3
4
|
import gql from 'graphql-tag'
|
|
@@ -7,9 +8,11 @@ import { property } from 'lit/decorators.js'
|
|
|
7
8
|
import { client } from '@operato/graphql'
|
|
8
9
|
import { i18next } from '@operato/i18n'
|
|
9
10
|
import { isMobileDevice } from '@operato/utils'
|
|
11
|
+
import { ButtonContainerStyles } from '@operato/styles'
|
|
10
12
|
|
|
11
13
|
export class LedgerImporter extends LitElement {
|
|
12
14
|
static styles = [
|
|
15
|
+
ButtonContainerStyles,
|
|
13
16
|
css`
|
|
14
17
|
:host {
|
|
15
18
|
display: flex;
|
|
@@ -21,16 +24,6 @@ export class LedgerImporter extends LitElement {
|
|
|
21
24
|
ox-grist {
|
|
22
25
|
flex: 1;
|
|
23
26
|
}
|
|
24
|
-
|
|
25
|
-
.button-container {
|
|
26
|
-
display: flex;
|
|
27
|
-
margin-left: auto;
|
|
28
|
-
padding: var(--padding-default);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
mwc-button {
|
|
32
|
-
margin-left: var(--margin-default);
|
|
33
|
-
}
|
|
34
27
|
`
|
|
35
28
|
]
|
|
36
29
|
|
|
@@ -60,21 +53,18 @@ export class LedgerImporter extends LitElement {
|
|
|
60
53
|
]
|
|
61
54
|
}
|
|
62
55
|
|
|
63
|
-
|
|
64
56
|
render() {
|
|
65
57
|
return html`
|
|
66
58
|
<ox-grist
|
|
67
59
|
.mode=${isMobileDevice() ? 'LIST' : 'GRID'}
|
|
68
60
|
.config=${this.columns}
|
|
69
|
-
.data=${
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
}
|
|
73
|
-
}
|
|
61
|
+
.data=${{
|
|
62
|
+
records: this.ledgers
|
|
63
|
+
}}
|
|
74
64
|
></ox-grist>
|
|
75
65
|
|
|
76
66
|
<div class="button-container">
|
|
77
|
-
<
|
|
67
|
+
<button @click="${this.save.bind(this)}"><md-icon>save</md-icon>${i18next.t('button.save')}</button>
|
|
78
68
|
</div>
|
|
79
69
|
`
|
|
80
70
|
}
|
|
@@ -94,4 +84,3 @@ export class LedgerImporter extends LitElement {
|
|
|
94
84
|
this.dispatchEvent(new CustomEvent('imported'))
|
|
95
85
|
}
|
|
96
86
|
}
|
|
97
|
-
|
|
@@ -100,7 +100,7 @@ export class LedgerListPage extends connect(store)(localize(i18next)(ScopedEleme
|
|
|
100
100
|
|
|
101
101
|
<div id="sorters">
|
|
102
102
|
Sort
|
|
103
|
-
<
|
|
103
|
+
<md-icon
|
|
104
104
|
@click=${e => {
|
|
105
105
|
const target = e.currentTarget
|
|
106
106
|
this.sortersControl.open({
|
|
@@ -108,7 +108,7 @@ export class LedgerListPage extends connect(store)(localize(i18next)(ScopedEleme
|
|
|
108
108
|
top: target.offsetTop + target.offsetHeight
|
|
109
109
|
})
|
|
110
110
|
}}
|
|
111
|
-
>expand_more</
|
|
111
|
+
>expand_more</md-icon
|
|
112
112
|
>
|
|
113
113
|
<ox-popup id="sorter-control">
|
|
114
114
|
<ox-sorters-control> </ox-sorters-control>
|
|
@@ -116,9 +116,10 @@ export class LedgerListPage extends connect(store)(localize(i18next)(ScopedEleme
|
|
|
116
116
|
</div>
|
|
117
117
|
|
|
118
118
|
<div id="modes">
|
|
119
|
-
<
|
|
120
|
-
<
|
|
121
|
-
<
|
|
119
|
+
<md-icon @click=${() => (this.mode = 'GRID')} ?active=${mode == 'GRID'}>grid_on</md-icon>
|
|
120
|
+
<md-icon @click=${() => (this.mode = 'LIST')} ?active=${mode == 'LIST'}>format_list_bulleted</md-icon>
|
|
121
|
+
<md-icon @click=${() => (this.mode = 'CARD')} ?active=${mode == 'CARD'}>apps</md-icon>
|
|
122
|
+
</div>
|
|
122
123
|
</div>
|
|
123
124
|
</div>
|
|
124
125
|
</ox-grist>
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import '@material/web/icon/icon.js'
|
|
1
2
|
import '@operato/data-grist'
|
|
2
3
|
|
|
3
4
|
import gql from 'graphql-tag'
|
|
@@ -7,9 +8,11 @@ import { property } from 'lit/decorators.js'
|
|
|
7
8
|
import { client } from '@operato/graphql'
|
|
8
9
|
import { i18next } from '@operato/i18n'
|
|
9
10
|
import { isMobileDevice } from '@operato/utils'
|
|
11
|
+
import { ButtonContainerStyles } from '@operato/styles'
|
|
10
12
|
|
|
11
13
|
export class TransactionImporter extends LitElement {
|
|
12
14
|
static styles = [
|
|
15
|
+
ButtonContainerStyles,
|
|
13
16
|
css`
|
|
14
17
|
:host {
|
|
15
18
|
display: flex;
|
|
@@ -21,16 +24,6 @@ export class TransactionImporter extends LitElement {
|
|
|
21
24
|
ox-grist {
|
|
22
25
|
flex: 1;
|
|
23
26
|
}
|
|
24
|
-
|
|
25
|
-
.button-container {
|
|
26
|
-
display: flex;
|
|
27
|
-
margin-left: auto;
|
|
28
|
-
padding: var(--padding-default);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
mwc-button {
|
|
32
|
-
margin-left: var(--margin-default);
|
|
33
|
-
}
|
|
34
27
|
`
|
|
35
28
|
]
|
|
36
29
|
|
|
@@ -60,21 +53,18 @@ export class TransactionImporter extends LitElement {
|
|
|
60
53
|
]
|
|
61
54
|
}
|
|
62
55
|
|
|
63
|
-
|
|
64
56
|
render() {
|
|
65
57
|
return html`
|
|
66
58
|
<ox-grist
|
|
67
59
|
.mode=${isMobileDevice() ? 'LIST' : 'GRID'}
|
|
68
60
|
.config=${this.columns}
|
|
69
|
-
.data=${
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
}
|
|
73
|
-
}
|
|
61
|
+
.data=${{
|
|
62
|
+
records: this.transactions
|
|
63
|
+
}}
|
|
74
64
|
></ox-grist>
|
|
75
65
|
|
|
76
66
|
<div class="button-container">
|
|
77
|
-
<
|
|
67
|
+
<button @click="${this.save.bind(this)}"><md-icon>save</md-icon>${i18next.t('button.save')}</button>
|
|
78
68
|
</div>
|
|
79
69
|
`
|
|
80
70
|
}
|
|
@@ -94,4 +84,3 @@ export class TransactionImporter extends LitElement {
|
|
|
94
84
|
this.dispatchEvent(new CustomEvent('imported'))
|
|
95
85
|
}
|
|
96
86
|
}
|
|
97
|
-
|
|
@@ -101,7 +101,7 @@ export class TransactionListPage extends connect(store)(localize(i18next)(Scoped
|
|
|
101
101
|
|
|
102
102
|
<div id="sorters">
|
|
103
103
|
Sort
|
|
104
|
-
<
|
|
104
|
+
<md-icon
|
|
105
105
|
@click=${e => {
|
|
106
106
|
const target = e.currentTarget
|
|
107
107
|
this.sortersControl.open({
|
|
@@ -109,7 +109,7 @@ export class TransactionListPage extends connect(store)(localize(i18next)(Scoped
|
|
|
109
109
|
top: target.offsetTop + target.offsetHeight
|
|
110
110
|
})
|
|
111
111
|
}}
|
|
112
|
-
>expand_more</
|
|
112
|
+
>expand_more</md-icon
|
|
113
113
|
>
|
|
114
114
|
<ox-popup id="sorter-control">
|
|
115
115
|
<ox-sorters-control> </ox-sorters-control>
|
|
@@ -117,9 +117,10 @@ export class TransactionListPage extends connect(store)(localize(i18next)(Scoped
|
|
|
117
117
|
</div>
|
|
118
118
|
|
|
119
119
|
<div id="modes">
|
|
120
|
-
<
|
|
121
|
-
<
|
|
122
|
-
<
|
|
120
|
+
<md-icon @click=${() => (this.mode = 'GRID')} ?active=${mode == 'GRID'}>grid_on</md-icon>
|
|
121
|
+
<md-icon @click=${() => (this.mode = 'LIST')} ?active=${mode == 'LIST'}>format_list_bulleted</md-icon>
|
|
122
|
+
<md-icon @click=${() => (this.mode = 'CARD')} ?active=${mode == 'CARD'}>apps</md-icon>
|
|
123
|
+
</div>
|
|
123
124
|
</div>
|
|
124
125
|
</div>
|
|
125
126
|
</ox-grist>
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { __decorate, __metadata } from "tslib";
|
|
2
|
+
import '@material/web/icon/icon.js';
|
|
2
3
|
import '@operato/data-grist';
|
|
3
4
|
import gql from 'graphql-tag';
|
|
4
5
|
import { css, html, LitElement } from 'lit';
|
|
@@ -6,6 +7,7 @@ import { property } from 'lit/decorators.js';
|
|
|
6
7
|
import { client } from '@operato/graphql';
|
|
7
8
|
import { i18next } from '@operato/i18n';
|
|
8
9
|
import { isMobileDevice } from '@operato/utils';
|
|
10
|
+
import { ButtonContainerStyles } from '@operato/styles';
|
|
9
11
|
export class AccountImporter extends LitElement {
|
|
10
12
|
constructor() {
|
|
11
13
|
super(...arguments);
|
|
@@ -46,7 +48,7 @@ export class AccountImporter extends LitElement {
|
|
|
46
48
|
></ox-grist>
|
|
47
49
|
|
|
48
50
|
<div class="button-container">
|
|
49
|
-
<
|
|
51
|
+
<button @click="${this.save.bind(this)}"><md-icon>save</md-icon>${i18next.t('button.save')}</button>
|
|
50
52
|
</div>
|
|
51
53
|
`;
|
|
52
54
|
}
|
|
@@ -66,6 +68,7 @@ export class AccountImporter extends LitElement {
|
|
|
66
68
|
}
|
|
67
69
|
}
|
|
68
70
|
AccountImporter.styles = [
|
|
71
|
+
ButtonContainerStyles,
|
|
69
72
|
css `
|
|
70
73
|
:host {
|
|
71
74
|
display: flex;
|
|
@@ -77,16 +80,6 @@ AccountImporter.styles = [
|
|
|
77
80
|
ox-grist {
|
|
78
81
|
flex: 1;
|
|
79
82
|
}
|
|
80
|
-
|
|
81
|
-
.button-container {
|
|
82
|
-
display: flex;
|
|
83
|
-
margin-left: auto;
|
|
84
|
-
padding: var(--padding-default);
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
mwc-button {
|
|
88
|
-
margin-left: var(--margin-default);
|
|
89
|
-
}
|
|
90
83
|
`
|
|
91
84
|
];
|
|
92
85
|
__decorate([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"account-importer.js","sourceRoot":"","sources":["../../../client/pages/account/account-importer.ts"],"names":[],"mappings":";AAAA,OAAO,qBAAqB,CAAA;AAE5B,OAAO,GAAG,MAAM,aAAa,CAAA;AAC7B,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,KAAK,CAAA;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAE5C,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAA;AACzC,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAA;AACvC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;
|
|
1
|
+
{"version":3,"file":"account-importer.js","sourceRoot":"","sources":["../../../client/pages/account/account-importer.ts"],"names":[],"mappings":";AAAA,OAAO,4BAA4B,CAAA;AACnC,OAAO,qBAAqB,CAAA;AAE5B,OAAO,GAAG,MAAM,aAAa,CAAA;AAC7B,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,KAAK,CAAA;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAE5C,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAA;AACzC,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAA;AACvC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AAC/C,OAAO,EAAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAA;AAEvD,MAAM,OAAO,eAAgB,SAAQ,UAAU;IAA/C;;QAiB6B,aAAQ,GAAU,EAAE,CAAA;QACnB,YAAO,GAAG;YACpC,IAAI,EAAE,EAAE,MAAM,EAAE,CAAC,MAAM,EAAE,aAAa,CAAC,EAAE;YACzC,UAAU,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE;YAC9B,OAAO,EAAE;gBACP;oBACE,IAAI,EAAE,QAAQ;oBACd,IAAI,EAAE,MAAM;oBACZ,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,YAAY,CAAC;oBAC/B,KAAK,EAAE,GAAG;iBACX;gBACD;oBACE,IAAI,EAAE,QAAQ;oBACd,IAAI,EAAE,aAAa;oBACnB,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,mBAAmB,CAAC;oBACtC,KAAK,EAAE,GAAG;iBACX;gBACD;oBACE,IAAI,EAAE,UAAU;oBAChB,IAAI,EAAE,QAAQ;oBACd,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,cAAc,CAAC;oBACjC,KAAK,EAAE,EAAE;iBACV;aACF;SACF,CAAA;IAgCH,CAAC;IA9BC,MAAM;QACJ,OAAO,IAAI,CAAA;;gBAEC,cAAc,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM;kBAChC,IAAI,CAAC,OAAO;gBACd;YACN,OAAO,EAAE,IAAI,CAAC,QAAQ;SACvB;;;;0BAIiB,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,4BAA4B,OAAO,CAAC,CAAC,CAAC,aAAa,CAAC;;KAE7F,CAAA;IACH,CAAC;IAED,KAAK,CAAC,IAAI;;QACR,MAAM,QAAQ,GAAG,MAAM,MAAM,CAAC,MAAM,CAAC;YACnC,QAAQ,EAAE,GAAG,CAAA;;;;OAIZ;YACD,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,CAAC,QAAQ,EAAE;SACvC,CAAC,CAAA;QAEF,IAAI,MAAA,QAAQ,CAAC,MAAM,0CAAE,MAAM;YAAE,OAAM;QAEnC,IAAI,CAAC,aAAa,CAAC,IAAI,WAAW,CAAC,UAAU,CAAC,CAAC,CAAA;IACjD,CAAC;;AAvEM,sBAAM,GAAG;IACd,qBAAqB;IACrB,GAAG,CAAA;;;;;;;;;;;KAWF;CACF,CAAA;AAED;IAAC,QAAQ,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC;;iDAAqB;AAC/C;IAAC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;gDAuB1B","sourcesContent":["import '@material/web/icon/icon.js'\nimport '@operato/data-grist'\n\nimport gql from 'graphql-tag'\nimport { css, html, LitElement } from 'lit'\nimport { property } from 'lit/decorators.js'\n\nimport { client } from '@operato/graphql'\nimport { i18next } from '@operato/i18n'\nimport { isMobileDevice } from '@operato/utils'\nimport { ButtonContainerStyles } from '@operato/styles'\n\nexport class AccountImporter extends LitElement {\n static styles = [\n ButtonContainerStyles,\n css`\n :host {\n display: flex;\n flex-direction: column;\n\n background-color: #fff;\n }\n\n ox-grist {\n flex: 1;\n }\n `\n ]\n\n @property({ type: Array }) accounts: any[] = []\n @property({ type: Object }) columns = {\n list: { fields: ['name', 'description'] },\n pagination: { infinite: true },\n columns: [\n {\n type: 'string',\n name: 'name',\n header: i18next.t('field.name'),\n width: 150\n },\n {\n type: 'string',\n name: 'description',\n header: i18next.t('field.description'),\n width: 200\n },\n {\n type: 'checkbox',\n name: 'active',\n header: i18next.t('field.active'),\n width: 60\n }\n ]\n }\n\n render() {\n return html`\n <ox-grist\n .mode=${isMobileDevice() ? 'LIST' : 'GRID'}\n .config=${this.columns}\n .data=${{\n records: this.accounts\n }}\n ></ox-grist>\n\n <div class=\"button-container\">\n <button @click=\"${this.save.bind(this)}\"><md-icon>save</md-icon>${i18next.t('button.save')}</button>\n </div>\n `\n }\n\n async save() {\n const response = await client.mutate({\n mutation: gql`\n mutation importAccounts($accounts: [AccountPatch!]!) {\n importAccounts(accounts: $accounts)\n }\n `,\n variables: { accounts: this.accounts }\n })\n\n if (response.errors?.length) return\n\n this.dispatchEvent(new CustomEvent('imported'))\n }\n}\n"]}
|