Should swagger Ui documentation show documentation for resposene model? Like in this
i have documented them to code like this
{$REGION 'Documentation'}
/// <value>
/// receiptid
/// </value>
{$ENDREGION}
Fid: Integer;
{$REGION 'Documentation'}
/// <value>
/// date and time of receipt.
/// </value>
{$ENDREGION}
FTimeStamp: TDateTime;
{$REGION 'Documentation'}
/// <value>
/// accounting date, year 1899 means not given.
/// </value>
{$ENDREGION}
servicemethod call documentation is working.
wlandgraf
(Wagner Landgraf)
December 20, 2021, 11:53am
2
No, it doesn't show it. It looks like it's a limitation of Swagger-UI, though.
I have seen implementations which have documentation also in model like
for example go to ledgerreceipts (post)
don't know it it's their own patch of swagger ui.
Actually did some testing / etc and learned that one must simply use summary
I Simply wrote the information in documentexplorer to wrong place. this is working example.
private
{$REGION 'Documentation'}
/// <summary>
/// summary from TRecipe class private fiels
/// </summary>
{$ENDREGION}
[ Column( 'tuote', [ ], 18 ) ]
FProduct: nullable< string >;
And one must put documentation to fields - NOT to properties.
wlandgraf
(Wagner Landgraf)
December 22, 2021, 3:35pm
5
Hi Mika,
I'm sorry about the confusion. I remember I had an issue with Swagger UI and documentation of some DTOs, and I thought it was the same case. Thank you for the follow up.
Hi Wagner,
no problem. It was actually quite intresting to find out whats going on. And now I know it exactly where to write it.
And this is really nice feature..