File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
src/Generators/Web/Codelisk.Controller.Generator/Generators Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -127,23 +127,23 @@ ClassDeclarationSyntax baseController
127127 . AddParameter ( "Guid" , "id" )
128128 . AddAttribute ( $ "[{ Constants . HttpGetAttribute } (\" { ApiUrls . GetFull } \" )]")
129129 . MakeAsync ( )
130- . WithReturnTypeTask ( dto . GetFullModelName ( ) )
130+ . WithReturnTypeTask ( "Microsoft.AspNetCore.Mvc.IActionResult" )
131131 . WithBody ( x =>
132132 {
133133 x . AppendLine (
134- $ "return await (_manager as I{ dto . ManagerNameFromDto ( ) } ).GetFull(id);"
134+ $ "return Ok( await (_manager as I{ dto . ManagerNameFromDto ( ) } ).GetFull(id) );"
135135 ) ;
136136 } ) ;
137137
138138 result
139139 . AddMethod ( $ "GetAllFull", Accessibility . Public )
140140 . MakeAsync ( )
141141 . AddAttribute ( $ "[{ Constants . HttpGetAttribute } (\" { ApiUrls . GetAllFull } \" )]")
142- . WithReturnTypeTaskList ( dto . GetFullModelName ( ) )
142+ . WithReturnTypeTask ( "Microsoft.AspNetCore.Mvc.IActionResult" )
143143 . WithBody ( x =>
144144 {
145145 x . AppendLine (
146- $ "return await (_manager as I{ dto . ManagerNameFromDto ( ) } ).GetAllFull();"
146+ $ "return Ok( await (_manager as I{ dto . ManagerNameFromDto ( ) } ).GetAllFull() );"
147147 ) ;
148148 } ) ;
149149 }
You can’t perform that action at this time.
0 commit comments