File tree Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -10,6 +10,10 @@ public interface ICatalogService : IFiscalApiService<CatalogDto>
1010 Task < ApiResponse < List < string > > > GetListAsync ( ) ;
1111
1212
13+ // /api/v4/catalogs/<catalogName>/key/<id>
14+ Task < ApiResponse < CatalogDto > > GetRecordByIdAsync ( string catalogName , string id ) ;
15+
16+
1317 //GET /api/v4/catalogs/{catalogName}/{searchText}
1418 Task < ApiResponse < PagedList < CatalogDto > > > SearchCatalogAsync ( string catalogName , string searchText ,
1519 int pageNumber = 1 ,
Original file line number Diff line number Diff line change @@ -69,6 +69,21 @@ public Task<ApiResponse<List<string>>> GetListAsync()
6969 return HttpClient . GetAsync < List < string > > ( BuildEndpoint ( ) ) ;
7070 }
7171
72+
73+ /// <summary>
74+ /// Recupera un registro de un catálogo por catalogName y id.
75+ /// </summary>
76+ /// <param name="catalogName">Nombre del catálogo</param>
77+ /// <param name="id">Id del registro en el catalogName</param>
78+ /// <returns>CatalogDto</returns>
79+ public Task < ApiResponse < CatalogDto > > GetRecordByIdAsync ( string catalogName , string id )
80+ {
81+ var path = $ "{ catalogName } /key/{ id } ";
82+ var endpoint = BuildEndpoint ( path ) ;
83+ ///api/v4/catalogs/<catalogName>/key/<id>
84+ return HttpClient . GetAsync < CatalogDto > ( endpoint ) ;
85+ }
86+
7287 /// <summary>
7388 /// Busca en un catálogo.
7489 /// </summary>
You can’t perform that action at this time.
0 commit comments