Table of Contents

Class SupplierAccountsController

Namespace
KadicErp.WebApi.Controllers.Payables
Assembly
KadicErp.WebApi.dll
[ApiController]
[Route("api/payables/supplier-accounts")]
public class SupplierAccountsController : ControllerBase
Inheritance
object
ControllerBase
SupplierAccountsController

Constructors

SupplierAccountsController(IMediator)

public SupplierAccountsController(IMediator mediator)

Parameters

mediator IMediator

Methods

Create(CreateSupplierAccountCommand)

[HttpPost]
[Authorize(Policy = "PAYABLES_SUPPLIER_ACCOUNTS_CREATE")]
public Task<IActionResult> Create(CreateSupplierAccountCommand command)

Parameters

command CreateSupplierAccountCommand

Returns

Task<IActionResult>

GetAll(Guid)

[HttpGet]
[Authorize(Policy = "PAYABLES_SUPPLIER_ACCOUNTS_VIEW")]
public Task<IActionResult> GetAll(Guid branchId)

Parameters

branchId Guid

Returns

Task<IActionResult>

GetById(Guid)

[HttpGet("{id:guid}")]
[Authorize(Policy = "PAYABLES_SUPPLIER_ACCOUNTS_VIEW")]
public Task<IActionResult> GetById(Guid id)

Parameters

id Guid

Returns

Task<IActionResult>

Update(Guid, UpdateSupplierAccountCommand)

[HttpPut("{id:guid}")]
[Authorize(Policy = "PAYABLES_SUPPLIER_ACCOUNTS_UPDATE")]
public Task<IActionResult> Update(Guid id, UpdateSupplierAccountCommand command)

Parameters

id Guid
command UpdateSupplierAccountCommand

Returns

Task<IActionResult>