mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-18 22:00:31 +00:00
feat: import customers/vendors
This commit is contained in:
@@ -3,6 +3,7 @@ import { Importable } from '@/services/Import/Importable';
|
||||
import { CreateCustomer } from './CRUD/CreateCustomer';
|
||||
import { Knex } from 'knex';
|
||||
import { ICustomer, ICustomerNewDTO } from '@/interfaces';
|
||||
import { CustomersSampleData } from './_SampleData';
|
||||
|
||||
@Service()
|
||||
export class CustomersImportable extends Importable {
|
||||
@@ -23,4 +24,11 @@ export class CustomersImportable extends Importable {
|
||||
): Promise<void> {
|
||||
await this.createCustomerService.createCustomer(tenantId, createDTO, trx);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieves the sample data of customers used to download sample sheet.
|
||||
*/
|
||||
public sampleData(): any[] {
|
||||
return CustomersSampleData;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user