@newpeak/barista-cli 0.1.491 → 0.1.495
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/dist/commands/liberica/files/index.d.ts +3 -0
- package/dist/commands/liberica/files/index.d.ts.map +1 -0
- package/dist/commands/liberica/files/index.js +9 -0
- package/dist/commands/liberica/files/index.js.map +1 -0
- package/dist/commands/liberica/files/upload.d.ts +3 -0
- package/dist/commands/liberica/files/upload.d.ts.map +1 -0
- package/dist/commands/liberica/files/upload.js +88 -0
- package/dist/commands/liberica/files/upload.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/capitalise.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/capitalise.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/capitalise.js +44 -0
- package/dist/commands/liberica/finance/fixed-asset/capitalise.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/category/create.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/category/create.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/category/create.js +70 -0
- package/dist/commands/liberica/finance/fixed-asset/category/create.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/category/index.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/category/index.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/category/index.js +11 -0
- package/dist/commands/liberica/finance/fixed-asset/category/index.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/category/list.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/category/list.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/category/list.js +59 -0
- package/dist/commands/liberica/finance/fixed-asset/category/list.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/create.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/create.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/create.js +89 -0
- package/dist/commands/liberica/finance/fixed-asset/create.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/depreciate.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/depreciate.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/depreciate.js +51 -0
- package/dist/commands/liberica/finance/fixed-asset/depreciate.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/depreciation-schedule.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/depreciation-schedule.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/depreciation-schedule.js +61 -0
- package/dist/commands/liberica/finance/fixed-asset/depreciation-schedule.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/dispose.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/dispose.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/dispose.js +61 -0
- package/dist/commands/liberica/finance/fixed-asset/dispose.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/get.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/get.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/get.js +73 -0
- package/dist/commands/liberica/finance/fixed-asset/get.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/impairment.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/impairment.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/impairment.js +93 -0
- package/dist/commands/liberica/finance/fixed-asset/impairment.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/index.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/index.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/index.js +27 -0
- package/dist/commands/liberica/finance/fixed-asset/index.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/list.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/list.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/list.js +84 -0
- package/dist/commands/liberica/finance/fixed-asset/list.js.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/update.d.ts +3 -0
- package/dist/commands/liberica/finance/fixed-asset/update.d.ts.map +1 -0
- package/dist/commands/liberica/finance/fixed-asset/update.js +54 -0
- package/dist/commands/liberica/finance/fixed-asset/update.js.map +1 -0
- package/dist/commands/liberica/finance/index.d.ts.map +1 -1
- package/dist/commands/liberica/finance/index.js +3 -1
- package/dist/commands/liberica/finance/index.js.map +1 -1
- package/dist/commands/liberica/finance/voucher/audit-trail.d.ts +3 -0
- package/dist/commands/liberica/finance/voucher/audit-trail.d.ts.map +1 -0
- package/dist/commands/liberica/finance/voucher/audit-trail.js +68 -0
- package/dist/commands/liberica/finance/voucher/audit-trail.js.map +1 -0
- package/dist/commands/liberica/finance/voucher/gaps.d.ts +3 -0
- package/dist/commands/liberica/finance/voucher/gaps.d.ts.map +1 -0
- package/dist/commands/liberica/finance/voucher/gaps.js +64 -0
- package/dist/commands/liberica/finance/voucher/gaps.js.map +1 -0
- package/dist/commands/liberica/finance/voucher/index.d.ts.map +1 -1
- package/dist/commands/liberica/finance/voucher/index.js +5 -1
- package/dist/commands/liberica/finance/voucher/index.js.map +1 -1
- package/dist/commands/liberica/index.d.ts.map +1 -1
- package/dist/commands/liberica/index.js +2 -0
- package/dist/commands/liberica/index.js.map +1 -1
- package/dist/commands/liberica/sales-orders/create.d.ts.map +1 -1
- package/dist/commands/liberica/sales-orders/create.js +11 -0
- package/dist/commands/liberica/sales-orders/create.js.map +1 -1
- package/dist/core/api/client.d.ts +15 -0
- package/dist/core/api/client.d.ts.map +1 -1
- package/dist/core/api/client.js +242 -0
- package/dist/core/api/client.js.map +1 -1
- package/dist/types/file.d.ts +15 -0
- package/dist/types/file.d.ts.map +1 -0
- package/dist/types/file.js +2 -0
- package/dist/types/file.js.map +1 -0
- package/dist/types/finance.d.ts +130 -0
- package/dist/types/finance.d.ts.map +1 -1
- package/package.json +1 -1
- package/skills/barista-cli/data/commands.json +79 -2
- package/skills/barista-cli/data/commands.yaml +56 -2
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import chalk from 'chalk';
|
|
3
|
+
import Table from 'cli-table3';
|
|
4
|
+
import { configManager } from '../../../../core/config/manager.js';
|
|
5
|
+
import { apiClient } from '../../../../core/api/client.js';
|
|
6
|
+
export function createFinanceFixedAssetDepreciationScheduleCommand() {
|
|
7
|
+
const cmd = new Command('depreciation-schedule');
|
|
8
|
+
cmd.description('Get depreciation schedule projection');
|
|
9
|
+
cmd
|
|
10
|
+
.requiredOption('--asset-id <string>', 'Asset ID')
|
|
11
|
+
.option('--json', 'Output as JSON')
|
|
12
|
+
.action(async (options) => {
|
|
13
|
+
const context = configManager.getCurrentContext();
|
|
14
|
+
const environment = options.env || context.environment;
|
|
15
|
+
const tenant = options.tenant || context.tenant;
|
|
16
|
+
const assetId = options.assetId;
|
|
17
|
+
const response = await apiClient.getFixedAssetDepreciationSchedule(environment, tenant, assetId);
|
|
18
|
+
if (!response.success) {
|
|
19
|
+
if (options.json) {
|
|
20
|
+
console.log(JSON.stringify({ success: false, error: response.error || { code: 'API_ERROR', message: 'Unknown error' } }, null, 2));
|
|
21
|
+
}
|
|
22
|
+
else {
|
|
23
|
+
console.error(chalk.red(`\n✗ Failed to get depreciation schedule: ${response.error?.message || 'Unknown error'}`));
|
|
24
|
+
if (response.error?.code)
|
|
25
|
+
console.error(chalk.gray(` Error code: ${response.error.code}`));
|
|
26
|
+
}
|
|
27
|
+
console.error();
|
|
28
|
+
process.exit(1);
|
|
29
|
+
return;
|
|
30
|
+
}
|
|
31
|
+
const data = response.data;
|
|
32
|
+
if (options.json) {
|
|
33
|
+
console.log(JSON.stringify({ success: true, data }, null, 2));
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
if (!data || data.length === 0) {
|
|
37
|
+
console.log(chalk.bold('\n📋 Depreciation Schedule\n'));
|
|
38
|
+
console.log(chalk.gray(' No schedule found\n'));
|
|
39
|
+
return;
|
|
40
|
+
}
|
|
41
|
+
console.log(chalk.bold('\n📋 Depreciation Schedule\n'));
|
|
42
|
+
const table = new Table({
|
|
43
|
+
head: [chalk.bold('Period'), chalk.bold('Date'), chalk.bold('Depreciation'), chalk.bold('Accumulated'), chalk.bold('NBV')],
|
|
44
|
+
colWidths: [10, 15, 18, 18, 18],
|
|
45
|
+
style: { head: [], border: [] },
|
|
46
|
+
});
|
|
47
|
+
for (const row of data) {
|
|
48
|
+
table.push([
|
|
49
|
+
row.periodNumber != null ? String(row.periodNumber) : '-',
|
|
50
|
+
row.periodDate || '-',
|
|
51
|
+
row.depreciationAmount != null ? String(row.depreciationAmount) : '-',
|
|
52
|
+
row.accumulatedDepreciation != null ? String(row.accumulatedDepreciation) : '-',
|
|
53
|
+
row.netBookValue != null ? String(row.netBookValue) : '-',
|
|
54
|
+
]);
|
|
55
|
+
}
|
|
56
|
+
console.log(table.toString());
|
|
57
|
+
console.log();
|
|
58
|
+
});
|
|
59
|
+
return cmd;
|
|
60
|
+
}
|
|
61
|
+
//# sourceMappingURL=depreciation-schedule.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"depreciation-schedule.js","sourceRoot":"","sources":["../../../../../src/commands/liberica/finance/fixed-asset/depreciation-schedule.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,MAAM,YAAY,CAAC;AAC/B,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAI3D,MAAM,UAAU,kDAAkD;IAChE,MAAM,GAAG,GAAG,IAAI,OAAO,CAAC,uBAAuB,CAAC,CAAC;IACjD,GAAG,CAAC,WAAW,CAAC,sCAAsC,CAAC,CAAC;IAExD,GAAG;SACA,cAAc,CAAC,qBAAqB,EAAE,UAAU,CAAC;SACjD,MAA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AG;gBACrB,GAAG,CAAC,kBAAkB,IAAI,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,kBAAkB,CAAC,CAAC,CAAC,CAAC,GAAG;gBACrE,GAAG,CAAC,uBAAuB,IAAI,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,uBAAuB,CAAC,CAAC,CAAC,CAAC,GAAG;gBAC/E,GAAG,CAAC,YAAY,IAAI,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,GAAG;aAC1D,CAAC,CAAC;QACL,CAAC;QAED,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC;QAC9B,OAAO,CAAC,GAAG,EAAE,CAAC;IAChB,CAAC,CAAC,CAAC;IAEL,OAAO,GAAG,CAAC;AACb,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dispose.d.ts","sourceRoot":"","sources":["../../../../../src/commands/liberica/finance/fixed-asset/dispose.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAOpC,wBAAgB,qCAAqC,IAAI,OAAO,CA0D/D"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import chalk from 'chalk';
|
|
3
|
+
import { configManager } from '../../../../core/config/manager.js';
|
|
4
|
+
import { apiClient } from '../../../../core/api/client.js';
|
|
5
|
+
export function createFinanceFixedAssetDisposeCommand() {
|
|
6
|
+
const cmd = new Command('dispose');
|
|
7
|
+
cmd.description('Dispose fixed asset');
|
|
8
|
+
cmd
|
|
9
|
+
.requiredOption('--asset-id <string>', 'Asset ID')
|
|
10
|
+
.requiredOption('--disposal-date <number>', 'Disposal date (epoch ms)')
|
|
11
|
+
.requiredOption('--disposal-type <string>', 'Disposal type (SALE|SCRAP|DONATE|TRANSFER_OUT)')
|
|
12
|
+
.requiredOption('--proceeds <number>', 'Disposal proceeds (cents)')
|
|
13
|
+
.option('--disposal-cost <number>', 'Disposal cost (cents, triggers partial disposal if < originalCost)')
|
|
14
|
+
.option('--description <string>', 'Disposal description')
|
|
15
|
+
.option('--force', 'Skip confirmation prompt')
|
|
16
|
+
.option('--json', 'Output as JSON')
|
|
17
|
+
.action(async (options) => {
|
|
18
|
+
const context = configManager.getCurrentContext();
|
|
19
|
+
const environment = options.env || context.environment;
|
|
20
|
+
const tenant = options.tenant || context.tenant;
|
|
21
|
+
const id = options.assetId;
|
|
22
|
+
const data = {
|
|
23
|
+
disposalDate: parseInt(options.disposalDate, 10),
|
|
24
|
+
disposalType: options.disposalType,
|
|
25
|
+
disposalProceeds: parseInt(options.proceeds, 10),
|
|
26
|
+
};
|
|
27
|
+
if (options.disposalCost)
|
|
28
|
+
data.disposalCost = parseInt(options.disposalCost, 10);
|
|
29
|
+
if (options.description)
|
|
30
|
+
data.description = options.description;
|
|
31
|
+
const response = await apiClient.disposeFixedAsset(environment, tenant, id, data);
|
|
32
|
+
if (!response.success) {
|
|
33
|
+
if (options.json) {
|
|
34
|
+
console.log(JSON.stringify({ success: false, error: response.error || { code: 'API_ERROR', message: 'Unknown error' } }, null, 2));
|
|
35
|
+
}
|
|
36
|
+
else {
|
|
37
|
+
console.error(chalk.red(`\n✗ Failed to dispose fixed asset: ${response.error?.message || 'Unknown error'}`));
|
|
38
|
+
if (response.error?.code)
|
|
39
|
+
console.error(chalk.gray(` Error code: ${response.error.code}`));
|
|
40
|
+
}
|
|
41
|
+
console.error();
|
|
42
|
+
process.exit(1);
|
|
43
|
+
return;
|
|
44
|
+
}
|
|
45
|
+
const result = response.data;
|
|
46
|
+
if (options.json) {
|
|
47
|
+
console.log(JSON.stringify({ success: true, data: result }, null, 2));
|
|
48
|
+
return;
|
|
49
|
+
}
|
|
50
|
+
console.log(chalk.green(`\n✓ Fixed asset disposed successfully`));
|
|
51
|
+
if (result) {
|
|
52
|
+
console.log(chalk.gray(` Disposal ID: ${result.disposalId}`));
|
|
53
|
+
console.log(chalk.gray(` Gain/Loss: ${result.gainLossAmount}`));
|
|
54
|
+
if (result.voucherId)
|
|
55
|
+
console.log(chalk.gray(` Voucher ID: ${result.voucherId}`));
|
|
56
|
+
}
|
|
57
|
+
console.log();
|
|
58
|
+
});
|
|
59
|
+
return cmd;
|
|
60
|
+
}
|
|
61
|
+
//# sourceMappingURL=dispose.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dispose.js","sourceRoot":"","sources":["../../../../../src/commands/liberica/finance/fixed-asset/dispose.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAI3D,MAAM,UAAU,qCAAqC;IACnD,MAAM,GAAG,GAAG,IAAI,OAAO,CAAC,SAAS,CAAC,CAAC;IACnC,GAAG,CAAC,WAAW,CAAC,qBAAqB,CAAC,CAAC;IAEvC,GAAG;SACA,cAAc,CAAC,qBAAqB,EAAE,UAAU,CAAC;SACjD,cAAc,CAAC,0BAA0B,EAAE,0BAA0B,CAAC;SACtE,cAAc,CAAC,0BAA0B,EAAE,gDAAgD,CAAC;SAC5F,cAAc,CAAC,qBAAqB,EAAE,2BAA2B,CAAC;SAClE,MAAM,CAAC,0BAA0B,EAAE,oEAAoE,CAAC;SACxG,MAAM,CAAC,wBAAwB,EAAE,sBAAsB,CAAC;SACxD,MAAM,CAAC,SAAS,EAAE,0BAA0B,CAAC;SAC7C,MAAM,CAAC,QAAQ,EAAE,gBAAgB,CAAC;SAClC,MAAM,CAAC,KAAK,EAAE,OAAO,EAAE,EAAE;QACxB,MAAM,OAAO,GAAG,aAAa,CAAC,iBAAiB,EAAE,CAAC;QAClD,MAAM,WAAW,GAAI,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CAAiC,IAAI,OAAO,CA0E3D"}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import chalk from 'chalk';
|
|
3
|
+
import Table from 'cli-table3';
|
|
4
|
+
import { configManager } from '../../../../core/config/manager.js';
|
|
5
|
+
import { apiClient } from '../../../../core/api/client.js';
|
|
6
|
+
export function createFinanceFixedAssetGetCommand() {
|
|
7
|
+
const getCommand = new Command('get');
|
|
8
|
+
getCommand.description('Get fixed asset detail');
|
|
9
|
+
getCommand
|
|
10
|
+
.requiredOption('--id <string>', 'Asset ID')
|
|
11
|
+
.option('--json', 'Output as JSON')
|
|
12
|
+
.action(async (options) => {
|
|
13
|
+
const context = configManager.getCurrentContext();
|
|
14
|
+
const environment = options.env || context.environment;
|
|
15
|
+
const tenant = options.tenant || context.tenant;
|
|
16
|
+
const id = options.id;
|
|
17
|
+
const response = await apiClient.getFixedAsset(environment, tenant, id);
|
|
18
|
+
if (!response.success) {
|
|
19
|
+
if (options.json) {
|
|
20
|
+
console.log(JSON.stringify({ success: false, error: response.error || { code: 'API_ERROR', message: 'Unknown error' } }, null, 2));
|
|
21
|
+
}
|
|
22
|
+
else {
|
|
23
|
+
console.error(chalk.red(`\n✗ Failed to get fixed asset: ${response.error?.message || 'Unknown error'}`));
|
|
24
|
+
if (response.error?.code)
|
|
25
|
+
console.error(chalk.gray(` Error code: ${response.error.code}`));
|
|
26
|
+
}
|
|
27
|
+
console.error();
|
|
28
|
+
process.exit(1);
|
|
29
|
+
return;
|
|
30
|
+
}
|
|
31
|
+
const data = response.data;
|
|
32
|
+
if (!data) {
|
|
33
|
+
if (options.json) {
|
|
34
|
+
console.log(JSON.stringify({ success: true, data: null }, null, 2));
|
|
35
|
+
}
|
|
36
|
+
else {
|
|
37
|
+
console.log(chalk.bold('\n📋 Fixed Asset Detail\n'));
|
|
38
|
+
console.log(chalk.gray(` No asset found for ID: ${id}\n`));
|
|
39
|
+
}
|
|
40
|
+
return;
|
|
41
|
+
}
|
|
42
|
+
if (options.json) {
|
|
43
|
+
console.log(JSON.stringify({ success: true, data }, null, 2));
|
|
44
|
+
return;
|
|
45
|
+
}
|
|
46
|
+
console.log(chalk.bold('\n📋 Fixed Asset Detail\n'));
|
|
47
|
+
const table = new Table({
|
|
48
|
+
head: [chalk.bold('Field'), chalk.bold('Value')],
|
|
49
|
+
colWidths: [25, 55],
|
|
50
|
+
style: { head: [], border: [] },
|
|
51
|
+
});
|
|
52
|
+
table.push(['ID', data.assetId || '-']);
|
|
53
|
+
table.push(['Code', data.assetCode || '-']);
|
|
54
|
+
table.push(['Name', data.assetName || '-']);
|
|
55
|
+
table.push(['Category', data.categoryName || '-']);
|
|
56
|
+
table.push(['Status', data.assetStatus || '-']);
|
|
57
|
+
table.push(['Acquisition Type', data.acquisitionType || '-']);
|
|
58
|
+
table.push(['Acquisition Date', data.acquisitionDate || '-']);
|
|
59
|
+
table.push(['Original Cost', data.originalCost != null ? String(data.originalCost) : '-']);
|
|
60
|
+
table.push(['Salvage Value', data.salvageValue != null ? String(data.salvageValue) : '-']);
|
|
61
|
+
table.push(['Useful Life (months)', data.usefulLifeMonths != null ? String(data.usefulLifeMonths) : '-']);
|
|
62
|
+
table.push(['Depreciation Method', data.depreciationMethod || '-']);
|
|
63
|
+
table.push(['Accumulated Depreciation', data.accumulatedDepreciation != null ? String(data.accumulatedDepreciation) : '-']);
|
|
64
|
+
table.push(['Impairment Amount', data.impairmentAmount != null ? String(data.impairmentAmount) : '-']);
|
|
65
|
+
table.push(['Net Book Value', data.netBookValue != null ? String(data.netBookValue) : '-']);
|
|
66
|
+
table.push(['Location', data.location || '-']);
|
|
67
|
+
table.push(['Responsible Person', data.responsiblePerson || '-']);
|
|
68
|
+
console.log(table.toString());
|
|
69
|
+
console.log();
|
|
70
|
+
});
|
|
71
|
+
return getCommand;
|
|
72
|
+
}
|
|
73
|
+
//# sourceMappingURL=get.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file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AAE,CAAC;IAChB,CAAC,CAAC,CAAC;IAEL,OAAO,UAAU,CAAC;AACpB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"impairment.d.ts","sourceRoot":"","sources":["../../../../../src/commands/liberica/finance/fixed-asset/impairment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAOpC,wBAAgB,wCAAwC,IAAI,OAAO,CAkGlE"}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import chalk from 'chalk';
|
|
3
|
+
import { configManager } from '../../../../core/config/manager.js';
|
|
4
|
+
import { apiClient } from '../../../../core/api/client.js';
|
|
5
|
+
export function createFinanceFixedAssetImpairmentCommand() {
|
|
6
|
+
const cmd = new Command('impairment');
|
|
7
|
+
cmd.description('Record or reverse fixed asset impairment');
|
|
8
|
+
const impairmentCmd = new Command('impairment');
|
|
9
|
+
impairmentCmd.description('Record fixed asset impairment');
|
|
10
|
+
impairmentCmd
|
|
11
|
+
.requiredOption('--asset-id <string>', 'Asset ID')
|
|
12
|
+
.requiredOption('--amount <number>', 'Impairment amount (cents, <= net book value)')
|
|
13
|
+
.option('--reason <string>', 'Reason for impairment')
|
|
14
|
+
.option('--json', 'Output as JSON')
|
|
15
|
+
.action(async (options) => {
|
|
16
|
+
const context = configManager.getCurrentContext();
|
|
17
|
+
const environment = options.env || context.environment;
|
|
18
|
+
const tenant = options.tenant || context.tenant;
|
|
19
|
+
const id = options.assetId;
|
|
20
|
+
const data = {
|
|
21
|
+
impairmentAmount: parseInt(options.amount, 10),
|
|
22
|
+
};
|
|
23
|
+
if (options.reason)
|
|
24
|
+
data.reason = options.reason;
|
|
25
|
+
const response = await apiClient.recordFixedAssetImpairment(environment, tenant, id, data);
|
|
26
|
+
if (!response.success) {
|
|
27
|
+
if (options.json) {
|
|
28
|
+
console.log(JSON.stringify({ success: false, error: response.error || { code: 'API_ERROR', message: 'Unknown error' } }, null, 2));
|
|
29
|
+
}
|
|
30
|
+
else {
|
|
31
|
+
console.error(chalk.red(`\n✗ Failed to record impairment: ${response.error?.message || 'Unknown error'}`));
|
|
32
|
+
if (response.error?.code)
|
|
33
|
+
console.error(chalk.gray(` Error code: ${response.error.code}`));
|
|
34
|
+
}
|
|
35
|
+
console.error();
|
|
36
|
+
process.exit(1);
|
|
37
|
+
return;
|
|
38
|
+
}
|
|
39
|
+
const result = response.data;
|
|
40
|
+
if (options.json) {
|
|
41
|
+
console.log(JSON.stringify({ success: true, data: result }, null, 2));
|
|
42
|
+
return;
|
|
43
|
+
}
|
|
44
|
+
console.log(chalk.green(`\n✓ Impairment recorded successfully`));
|
|
45
|
+
if (result) {
|
|
46
|
+
console.log(chalk.gray(` Asset ID: ${result.assetId}`));
|
|
47
|
+
console.log(chalk.gray(` Impairment Amount: ${result.impairmentAmount}`));
|
|
48
|
+
console.log(chalk.gray(` Status: ${result.assetStatus}`));
|
|
49
|
+
}
|
|
50
|
+
console.log();
|
|
51
|
+
});
|
|
52
|
+
const reverseCmd = new Command('reverse-impairment');
|
|
53
|
+
reverseCmd.description('Reverse fixed asset impairment');
|
|
54
|
+
reverseCmd
|
|
55
|
+
.requiredOption('--asset-id <string>', 'Asset ID')
|
|
56
|
+
.option('--reversal-amount <number>', 'Reversal amount (<= accumulated impairment)')
|
|
57
|
+
.option('--json', 'Output as JSON')
|
|
58
|
+
.action(async (options) => {
|
|
59
|
+
const context = configManager.getCurrentContext();
|
|
60
|
+
const environment = options.env || context.environment;
|
|
61
|
+
const tenant = options.tenant || context.tenant;
|
|
62
|
+
const id = options.assetId;
|
|
63
|
+
const response = await apiClient.reverseFixedAssetImpairment(environment, tenant, id, options.reversalAmount);
|
|
64
|
+
if (!response.success) {
|
|
65
|
+
if (options.json) {
|
|
66
|
+
console.log(JSON.stringify({ success: false, error: response.error || { code: 'API_ERROR', message: 'Unknown error' } }, null, 2));
|
|
67
|
+
}
|
|
68
|
+
else {
|
|
69
|
+
console.error(chalk.red(`\n✗ Failed to reverse impairment: ${response.error?.message || 'Unknown error'}`));
|
|
70
|
+
if (response.error?.code)
|
|
71
|
+
console.error(chalk.gray(` Error code: ${response.error.code}`));
|
|
72
|
+
}
|
|
73
|
+
console.error();
|
|
74
|
+
process.exit(1);
|
|
75
|
+
return;
|
|
76
|
+
}
|
|
77
|
+
const result = response.data;
|
|
78
|
+
if (options.json) {
|
|
79
|
+
console.log(JSON.stringify({ success: true, data: result }, null, 2));
|
|
80
|
+
return;
|
|
81
|
+
}
|
|
82
|
+
console.log(chalk.green(`\n✓ Impairment reversed successfully`));
|
|
83
|
+
if (result) {
|
|
84
|
+
console.log(chalk.gray(` Asset ID: ${result.assetId}`));
|
|
85
|
+
console.log(chalk.gray(` Status: ${result.assetStatus}`));
|
|
86
|
+
}
|
|
87
|
+
console.log();
|
|
88
|
+
});
|
|
89
|
+
cmd.addCommand(impairmentCmd);
|
|
90
|
+
cmd.addCommand(reverseCmd);
|
|
91
|
+
return cmd;
|
|
92
|
+
}
|
|
93
|
+
//# sourceMappingURL=impairment.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"impairment.js","sourceRoot":"","sources":["../../../../../src/commands/liberica/finance/fixed-asset/impairment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAI3D,MAAM,UAAU,wCAAwC;IACtD,MAAM,GAAG,GAAG,IAAI,OAAO,CAAC,YAAY,CAAC,CAAC;IACtC,GAAG,CAAC,WAAW,CAAC,0CAA0C,CAAC,CAAC;IAE5D,MAAM,aAAa,GAAG,IAAI,OAAO,CAAC,YAAY,CAAC,CAAC;IAChD,aAAa,CAAC,WAAW,CAAC,+BAA+B,CAAC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ChB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;YAChB,OAAO;QACT,CAAC;QAED,MAAM,MAAM,GAAG,QAAQ,CAAC,IAAiC,CAAC;QAE1D,IAAI,OAAO,CAAC,IAAI,EAAE,CAAC;YACjB,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,SAAS,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;YACtE,OAAO;QACT,CAAC;QAED,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,KAAK,CAAC,sCAAsC,CAAC,CAAC,CAAC;QACjE,IAAI,MAAM,EAAE,CAAC;YACX,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI,CAAC,eAAe,MAAM,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC;YACzD,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI,CAAC,aAAa,MAAM,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC;QAC7D,CAAC;QACD,OAAO,CAAC,GAAG,EAAE,CAAC;IAChB,CAAC,CAAC,CAAC;IAEL,GAAG,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC;IAC9B,GAAG,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC;IAE3B,OAAO,GAAG,CAAC;AACb,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/commands/liberica/finance/fixed-asset/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAYpC,wBAAgB,8BAA8B,IAAI,OAAO,CAgBxD"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import { createFinanceFixedAssetCreateCommand } from './create.js';
|
|
3
|
+
import { createFinanceFixedAssetGetCommand } from './get.js';
|
|
4
|
+
import { createFinanceFixedAssetUpdateCommand } from './update.js';
|
|
5
|
+
import { createFinanceFixedAssetListCommand } from './list.js';
|
|
6
|
+
import { createFinanceFixedAssetCapitaliseCommand } from './capitalise.js';
|
|
7
|
+
import { createFinanceFixedAssetDepreciateCommand } from './depreciate.js';
|
|
8
|
+
import { createFinanceFixedAssetDepreciationScheduleCommand } from './depreciation-schedule.js';
|
|
9
|
+
import { createFinanceFixedAssetImpairmentCommand } from './impairment.js';
|
|
10
|
+
import { createFinanceFixedAssetDisposeCommand } from './dispose.js';
|
|
11
|
+
import { createFinanceFixedAssetCategoryCommand } from './category/index.js';
|
|
12
|
+
export function createFinanceFixedAssetCommand() {
|
|
13
|
+
const fixedAssetCommand = new Command('fixed-asset');
|
|
14
|
+
fixedAssetCommand.description('Manage fixed assets (create/get/list/update/capitalise/depreciate/schedule/impairment/dispose/category)');
|
|
15
|
+
fixedAssetCommand.addCommand(createFinanceFixedAssetCreateCommand());
|
|
16
|
+
fixedAssetCommand.addCommand(createFinanceFixedAssetGetCommand());
|
|
17
|
+
fixedAssetCommand.addCommand(createFinanceFixedAssetListCommand());
|
|
18
|
+
fixedAssetCommand.addCommand(createFinanceFixedAssetUpdateCommand());
|
|
19
|
+
fixedAssetCommand.addCommand(createFinanceFixedAssetCapitaliseCommand());
|
|
20
|
+
fixedAssetCommand.addCommand(createFinanceFixedAssetDepreciateCommand());
|
|
21
|
+
fixedAssetCommand.addCommand(createFinanceFixedAssetDepreciationScheduleCommand());
|
|
22
|
+
fixedAssetCommand.addCommand(createFinanceFixedAssetImpairmentCommand());
|
|
23
|
+
fixedAssetCommand.addCommand(createFinanceFixedAssetDisposeCommand());
|
|
24
|
+
fixedAssetCommand.addCommand(createFinanceFixedAssetCategoryCommand());
|
|
25
|
+
return fixedAssetCommand;
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/commands/liberica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AiB,CAAC,UAAU,CAAC,qCAAqC,EAAE,CAAC,CAAC;IACtE,iBAAiB,CAAC,UAAU,CAAC,sCAAsC,EAAE,CAAC,CAAC;IAEvE,OAAO,iBAAiB,CAAC;AAC3B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list.d.ts","sourceRoot":"","sources":["../../../../../src/commands/liberica/finance/fixed-asset/list.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAOpC,wBAAgB,kCAAkC,IAAI,OAAO,CAgF5D"}
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import chalk from 'chalk';
|
|
3
|
+
import Table from 'cli-table3';
|
|
4
|
+
import { configManager } from '../../../../core/config/manager.js';
|
|
5
|
+
import { apiClient } from '../../../../core/api/client.js';
|
|
6
|
+
export function createFinanceFixedAssetListCommand() {
|
|
7
|
+
const listCommand = new Command('list');
|
|
8
|
+
listCommand.description('List fixed assets');
|
|
9
|
+
listCommand
|
|
10
|
+
.option('--status <string>', 'Filter by status (PENDING|ACTIVE|DEPRECIATING|IMPAIRED|DISPOSED)')
|
|
11
|
+
.option('--category-id <string>', 'Filter by category ID')
|
|
12
|
+
.option('--code <string>', 'Filter by asset code')
|
|
13
|
+
.option('--name <string>', 'Filter by asset name')
|
|
14
|
+
.option('--start-date <number>', 'Start date filter (epoch ms)')
|
|
15
|
+
.option('--end-date <number>', 'End date filter (epoch ms)')
|
|
16
|
+
.option('--page <number>', 'Page number', '1')
|
|
17
|
+
.option('--size <number>', 'Page size', '20')
|
|
18
|
+
.option('--json', 'Output as JSON')
|
|
19
|
+
.action(async (options) => {
|
|
20
|
+
const context = configManager.getCurrentContext();
|
|
21
|
+
const environment = options.env || context.environment;
|
|
22
|
+
const tenant = options.tenant || context.tenant;
|
|
23
|
+
const params = {
|
|
24
|
+
pageNo: parseInt(options.page, 10),
|
|
25
|
+
pageSize: parseInt(options.size, 10),
|
|
26
|
+
};
|
|
27
|
+
if (options.status)
|
|
28
|
+
params.assetStatus = options.status;
|
|
29
|
+
if (options.categoryId)
|
|
30
|
+
params.categoryId = options.categoryId;
|
|
31
|
+
if (options.code)
|
|
32
|
+
params.assetCode = options.code;
|
|
33
|
+
if (options.name)
|
|
34
|
+
params.assetName = options.name;
|
|
35
|
+
if (options.startDate)
|
|
36
|
+
params.beginDate = parseInt(options.startDate, 10);
|
|
37
|
+
if (options.endDate)
|
|
38
|
+
params.endDate = parseInt(options.endDate, 10);
|
|
39
|
+
const response = await apiClient.listFixedAssets(environment, tenant, params);
|
|
40
|
+
if (!response.success) {
|
|
41
|
+
if (options.json) {
|
|
42
|
+
console.log(JSON.stringify({ success: false, error: response.error || { code: 'API_ERROR', message: 'Unknown error' } }, null, 2));
|
|
43
|
+
}
|
|
44
|
+
else {
|
|
45
|
+
console.error(chalk.red(`\n✗ Failed to list fixed assets: ${response.error?.message || 'Unknown error'}`));
|
|
46
|
+
if (response.error?.code)
|
|
47
|
+
console.error(chalk.gray(` Error code: ${response.error.code}`));
|
|
48
|
+
}
|
|
49
|
+
console.error();
|
|
50
|
+
process.exit(1);
|
|
51
|
+
return;
|
|
52
|
+
}
|
|
53
|
+
if (options.json) {
|
|
54
|
+
console.log(JSON.stringify({ success: true, data: response.data }, null, 2));
|
|
55
|
+
return;
|
|
56
|
+
}
|
|
57
|
+
const rows = response.data?.rows || [];
|
|
58
|
+
if (rows.length === 0) {
|
|
59
|
+
console.log(chalk.bold('\n📋 Fixed Assets\n'));
|
|
60
|
+
console.log(chalk.gray(' No fixed assets found\n'));
|
|
61
|
+
return;
|
|
62
|
+
}
|
|
63
|
+
console.log(chalk.bold('\n📋 Fixed Assets\n'));
|
|
64
|
+
const table = new Table({
|
|
65
|
+
head: [chalk.bold('Code'), chalk.bold('Name'), chalk.bold('Category'), chalk.bold('Status'), chalk.bold('Cost'), chalk.bold('NBV')],
|
|
66
|
+
colWidths: [15, 25, 15, 15, 15, 15],
|
|
67
|
+
style: { head: [], border: [] },
|
|
68
|
+
});
|
|
69
|
+
for (const row of rows) {
|
|
70
|
+
table.push([
|
|
71
|
+
row.assetCode || '-',
|
|
72
|
+
row.assetName || '-',
|
|
73
|
+
row.categoryName || '-',
|
|
74
|
+
row.assetStatus || '-',
|
|
75
|
+
row.originalCost != null ? String(row.originalCost) : '-',
|
|
76
|
+
row.netBookValue != null ? String(row.netBookValue) : '-',
|
|
77
|
+
]);
|
|
78
|
+
}
|
|
79
|
+
console.log(table.toString());
|
|
80
|
+
console.log();
|
|
81
|
+
});
|
|
82
|
+
return listCommand;
|
|
83
|
+
}
|
|
84
|
+
//# sourceMappingURL=list.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list.js","sourceRoot":"","sources":["../../../../../src/commands/liberica/finance/fixed-asset/list.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,MAAM,YAAY,CAAC;AAC/B,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAG3D,MAAM,UAAU,kCAAkC;IAChD,MAAM,WAAW,GAAG,IAAI,OAAO,CAAC,MAAM,CAAC,CAAC;IACxC,WAAW,CAAC,WAAW,CAAC,mBAAmB,CAAC,CAAC;IAE7C,WAAW;SACR,MAAM,CAAC,mBAAmB,EAAE,kEAAkE,CAAC;SAC/F,MAAM,CAAC,wBAAwB,EAAE,uBAAuB,CAAC;SACzD,MAAM,CAAC,iBAAiB,EAAE,sBAAsB,CAAC;SACjD,MAAM,CAAC,iBAAiB,EAAE,sBAAsB,CAAC;SACjD,MAAM,CAAC,uBAAuB,EAAE,8BAA8B,CAAC;SAC/D,MAAM,CAAC,qBAAqB,EAAE,4BAA4B,CAAC;SAC3D,MAAM,CAAC,iB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EAAE,CAAC;IAChB,CAAC,CAAC,CAAC;IAEL,OAAO,WAAW,CAAC;AACrB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"update.d.ts","sourceRoot":"","sources":["../../../../../src/commands/liberica/finance/fixed-asset/update.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAOpC,wBAAgB,oCAAoC,IAAI,OAAO,CAmD9D"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import chalk from 'chalk';
|
|
3
|
+
import { configManager } from '../../../../core/config/manager.js';
|
|
4
|
+
import { apiClient } from '../../../../core/api/client.js';
|
|
5
|
+
export function createFinanceFixedAssetUpdateCommand() {
|
|
6
|
+
const updateCommand = new Command('update');
|
|
7
|
+
updateCommand.description('Update fixed asset (name/location/person — only when PENDING)');
|
|
8
|
+
updateCommand
|
|
9
|
+
.requiredOption('--id <string>', 'Asset ID')
|
|
10
|
+
.option('--name <string>', 'New asset name')
|
|
11
|
+
.option('--location <string>', 'New location')
|
|
12
|
+
.option('--responsible-person <string>', 'New responsible person')
|
|
13
|
+
.option('--json', 'Output as JSON')
|
|
14
|
+
.action(async (options) => {
|
|
15
|
+
const context = configManager.getCurrentContext();
|
|
16
|
+
const environment = options.env || context.environment;
|
|
17
|
+
const tenant = options.tenant || context.tenant;
|
|
18
|
+
const id = options.id;
|
|
19
|
+
const data = {};
|
|
20
|
+
if (options.name)
|
|
21
|
+
data.assetName = options.name;
|
|
22
|
+
if (options.location)
|
|
23
|
+
data.location = options.location;
|
|
24
|
+
if (options.responsiblePerson)
|
|
25
|
+
data.responsiblePerson = options.responsiblePerson;
|
|
26
|
+
const response = await apiClient.updateFixedAsset(environment, tenant, id, data);
|
|
27
|
+
if (!response.success) {
|
|
28
|
+
if (options.json) {
|
|
29
|
+
console.log(JSON.stringify({ success: false, error: response.error || { code: 'API_ERROR', message: 'Unknown error' } }, null, 2));
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
console.error(chalk.red(`\n✗ Failed to update fixed asset: ${response.error?.message || 'Unknown error'}`));
|
|
33
|
+
if (response.error?.code)
|
|
34
|
+
console.error(chalk.gray(` Error code: ${response.error.code}`));
|
|
35
|
+
}
|
|
36
|
+
console.error();
|
|
37
|
+
process.exit(1);
|
|
38
|
+
return;
|
|
39
|
+
}
|
|
40
|
+
const result = response.data;
|
|
41
|
+
if (options.json) {
|
|
42
|
+
console.log(JSON.stringify({ success: true, data: result }, null, 2));
|
|
43
|
+
return;
|
|
44
|
+
}
|
|
45
|
+
console.log(chalk.green(`\n✓ Fixed asset updated successfully`));
|
|
46
|
+
if (result) {
|
|
47
|
+
console.log(chalk.gray(` ID: ${result.assetId}`));
|
|
48
|
+
console.log(chalk.gray(` Name: ${result.assetName}`));
|
|
49
|
+
}
|
|
50
|
+
console.log();
|
|
51
|
+
});
|
|
52
|
+
return updateCommand;
|
|
53
|
+
}
|
|
54
|
+
//# sourceMappingURL=update.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"update.js","sourceRoot":"","sources":["../../../../../src/commands/liberica/finance/fixed-asset/update.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAI3D,MAAM,UAAU,oCAAoC;IAClD,MAAM,aAAa,GAAG,IAAI,OAAO,CAAC,QAAQ,CAAC,CAAC;IAC5C,aAAa,CAAC,WAAW,CAAC,+DAA+D,CAAC,CAAC;IAE3F,aAAa;SACV,cAAc,CAAC,eAAe,EAAE,UAAU,CAAC;SAC3C,MAAM,CAAC,iBAAiB,EAAE,gBAAgB,CAAC;SAC3C,MAAM,CAAC,qBAAqB,EAAE,cAA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,KAAK,EAAE,OAAO,IAAI,eAAe,EAAE,CAAC,CAAC,CAAC;gBAC5G,IAAI,QAAQ,CAAC,KAAK,EAAE,IAAI;oBAAE,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,iBAAiB,QAAQ,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;YAC9F,CAAC;YACD,OAAO,CAAC,KAAK,EAAE,CAAC;YAChB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;YAChB,OAAO;QACT,CAAC;QAED,MAAM,MAAM,GAAG,QAAQ,CAAC,IAAiC,CAAC;QAE1D,IAAI,OAAO,CAAC,IAAI,EAAE,CAAC;YACjB,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,SAAS,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;YACtE,OAAO;QACT,CAAC;QAED,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,KAAK,CAAC,sCAAsC,CAAC,CAAC,CAAC;QACjE,IAAI,MAAM,EAAE,CAAC;YACX,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI,CAAC,SAAS,MAAM,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC;YACnD,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI,CAAC,WAAW,MAAM,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC;QACzD,CAAC;QACD,OAAO,CAAC,GAAG,EAAE,CAAC;IAChB,CAAC,CAAC,CAAC;IAEL,OAAO,aAAa,CAAC;AACvB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/commands/liberica/finance/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/commands/liberica/finance/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAmBpC,wBAAgB,oBAAoB,IAAI,OAAO,CAuB9C"}
|
|
@@ -15,9 +15,10 @@ import { createFinanceAutoVoucherCommand } from './auto-voucher/index.js';
|
|
|
15
15
|
import { createFinanceBankReconciliationCommand } from './bank-reconciliation/index.js';
|
|
16
16
|
import { createFinanceAmortizationCommand } from './amortization/index.js';
|
|
17
17
|
import { createFinanceAdjustmentChecklistCommand } from './adjustment-checklist/index.js';
|
|
18
|
+
import { createFinanceFixedAssetCommand } from './fixed-asset/index.js';
|
|
18
19
|
export function createFinanceCommand() {
|
|
19
20
|
const financeCommand = new Command('finance');
|
|
20
|
-
financeCommand.description('Manage finance (invoices, proceeds, costs, management-fee, production-cost, config, coa, voucher, period, reports, tax, exchange-rate, auto-voucher, bank-reconciliation, amortization, adjustment-checklist)');
|
|
21
|
+
financeCommand.description('Manage finance (invoices, proceeds, costs, management-fee, production-cost, config, coa, voucher, period, reports, tax, exchange-rate, auto-voucher, bank-reconciliation, amortization, adjustment-checklist, fixed-asset)');
|
|
21
22
|
financeCommand.addCommand(createFinanceInvoicesCommand());
|
|
22
23
|
financeCommand.addCommand(createFinanceProceedsCommand());
|
|
23
24
|
financeCommand.addCommand(createFinanceCostCommand());
|
|
@@ -34,6 +35,7 @@ export function createFinanceCommand() {
|
|
|
34
35
|
financeCommand.addCommand(createFinanceBankReconciliationCommand());
|
|
35
36
|
financeCommand.addCommand(createFinanceAmortizationCommand());
|
|
36
37
|
financeCommand.addCommand(createFinanceAdjustmentChecklistCommand());
|
|
38
|
+
financeCommand.addCommand(createFinanceFixedAssetCommand());
|
|
37
39
|
return financeCommand;
|
|
38
40
|
}
|
|
39
41
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/commands/liberica/finance/index.ts"],"names":[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