C# Class Foretagsplatsen.Api.Resources.ChartOfAccountsResource

ファイルを表示 Open project: foretagsplatsen/Foretagsplatsen-DotNet-API

Public Methods

Method Description
ChartOfAccountsResource ( ApiClient client, CompanyInfo company ) : System.Collections.Generic

Instantiates a new KeyFigureDataResource object.

ChartOfAccountsResource ( ApiClient client, string businessIdentityCode ) : System.Collections.Generic

Instantiates a new KeyFigureDataResource object.

Connect ( string fiscalYearId, string chartOfAccountsId ) : void

Connects a chart of account to a fiscal year

Create ( ChartOfAccounts chartOfAccounts ) : void

Creates a chart of account for the company. If the chart of account id already exists, an exception will be thrown.

Create ( string id, string json ) : void

Creates a chart of account for the company. If the chart of account id already exists, an exception will be thrown.

Delete ( string chartOfAccountsId ) : void

Deletes a chart of account from the company. The server will return an error if the chart of account is connect to a year.

Disconnect ( string fiscalYearId ) : void

Disconnects the custom chart of account from a fiscal year and restore the default one.

Get ( string id ) : ChartOfAccounts

Get the chart of account by id

GetByFiscalYearId ( string fiscalYearId ) : ChartOfAccounts

Get the chart of account for a particular fiscal year

GetUrl ( ) : string

Url for the key figure data resource.

GetUrlWithChartOfAccountsId ( string chartOfAccountsId ) : string

Url for the key figure data resource.

GetUrlWithFiscalYearId ( string fiscalYearId ) : string

Url for the key figure data resource.

GetUrlWithFiscalYearIdAndChartOfAccountsId ( string fiscalYearId, string chartOfAccountsId ) : string

Url for the key figure data resource.

List ( ) : List

Lists all chart of accounts for the company

Update ( ChartOfAccounts chartOfAccounts ) : void

Updates a chart of account. If the chart of account doesn't exists it will be created.

Update ( string id, string json ) : void

Updates a chart of account. If the chart of account doesn't exists it will be created.

Method Details

ChartOfAccountsResource() public method

Instantiates a new KeyFigureDataResource object.
public ChartOfAccountsResource ( ApiClient client, CompanyInfo company ) : System.Collections.Generic
client ApiClient REST client
company Foretagsplatsen.Api.Entities.CompanyInfo Company
return System.Collections.Generic

ChartOfAccountsResource() public method

Instantiates a new KeyFigureDataResource object.
public ChartOfAccountsResource ( ApiClient client, string businessIdentityCode ) : System.Collections.Generic
client ApiClient REST client
businessIdentityCode string Business identity code for company.
return System.Collections.Generic

Connect() public method

Connects a chart of account to a fiscal year
public Connect ( string fiscalYearId, string chartOfAccountsId ) : void
fiscalYearId string The id of the fiscal year
chartOfAccountsId string The id of the chart of account
return void

Create() public method

Creates a chart of account for the company. If the chart of account id already exists, an exception will be thrown.
public Create ( ChartOfAccounts chartOfAccounts ) : void
chartOfAccounts Foretagsplatsen.Api.Entities.Accounts.ChartOfAccounts The chart of account to upload
return void

Create() public method

Creates a chart of account for the company. If the chart of account id already exists, an exception will be thrown.
public Create ( string id, string json ) : void
id string The id of the chart of account, must match the id in the json data
json string JSON representation of the chart of account
return void

Delete() public method

Deletes a chart of account from the company. The server will return an error if the chart of account is connect to a year.
public Delete ( string chartOfAccountsId ) : void
chartOfAccountsId string The id of the chart of account to be deleted
return void

Disconnect() public method

Disconnects the custom chart of account from a fiscal year and restore the default one.
public Disconnect ( string fiscalYearId ) : void
fiscalYearId string The id of the fiscal year
return void

Get() public method

Get the chart of account by id
public Get ( string id ) : ChartOfAccounts
id string The id of the chart of account
return Foretagsplatsen.Api.Entities.Accounts.ChartOfAccounts

GetByFiscalYearId() public method

Get the chart of account for a particular fiscal year
public GetByFiscalYearId ( string fiscalYearId ) : ChartOfAccounts
fiscalYearId string The id of the fiscal year
return Foretagsplatsen.Api.Entities.Accounts.ChartOfAccounts

GetUrl() public method

Url for the key figure data resource.
public GetUrl ( ) : string
return string

GetUrlWithChartOfAccountsId() public method

Url for the key figure data resource.
public GetUrlWithChartOfAccountsId ( string chartOfAccountsId ) : string
chartOfAccountsId string
return string

GetUrlWithFiscalYearId() public method

Url for the key figure data resource.
public GetUrlWithFiscalYearId ( string fiscalYearId ) : string
fiscalYearId string
return string

GetUrlWithFiscalYearIdAndChartOfAccountsId() public method

Url for the key figure data resource.
public GetUrlWithFiscalYearIdAndChartOfAccountsId ( string fiscalYearId, string chartOfAccountsId ) : string
fiscalYearId string
chartOfAccountsId string
return string

List() public method

Lists all chart of accounts for the company
public List ( ) : List
return List

Update() public method

Updates a chart of account. If the chart of account doesn't exists it will be created.
public Update ( ChartOfAccounts chartOfAccounts ) : void
chartOfAccounts Foretagsplatsen.Api.Entities.Accounts.ChartOfAccounts The chart of account to upload
return void

Update() public method

Updates a chart of account. If the chart of account doesn't exists it will be created.
public Update ( string id, string json ) : void
id string The id of the chart of account, must match the id in the json data
json string JSON representation of the chart of account
return void