@@ -420,6 +420,9 @@ public static void getRequest(Project project,YapiApiDTO yapiApiDTO,PsiMethod ps
420
420
if (Strings .isNullOrEmpty (yapiHeaderDTO .getExample ()) && NormalTypes .normalTypes .containsKey (psiParameter .getType ().getPresentableText ())){
421
421
yapiHeaderDTO .setExample (NormalTypes .normalTypes .get (psiParameter .getType ().getPresentableText ()).toString ());
422
422
}
423
+ if (Strings .isNullOrEmpty (yapiHeaderDTO .getName ())){
424
+ yapiHeaderDTO .setName (psiParameter .getName ());
425
+ }
423
426
yapiHeaderDTOList .add (yapiHeaderDTO );
424
427
}else if (yapiPathVariableDTO !=null ){
425
428
if (Strings .isNullOrEmpty (yapiPathVariableDTO .getDesc ())){
@@ -429,6 +432,9 @@ public static void getRequest(Project project,YapiApiDTO yapiApiDTO,PsiMethod ps
429
432
if (Strings .isNullOrEmpty (yapiPathVariableDTO .getExample ()) && NormalTypes .normalTypes .containsKey (psiParameter .getType ().getPresentableText ())){
430
433
yapiPathVariableDTO .setExample (NormalTypes .normalTypes .get (psiParameter .getType ().getPresentableText ()).toString ());
431
434
}
435
+ if (Strings .isNullOrEmpty (yapiPathVariableDTO .getName ())){
436
+ yapiPathVariableDTO .setName (psiParameter .getName ());
437
+ }
432
438
yapiPathVariableDTOList .add (yapiPathVariableDTO );
433
439
}else {
434
440
if (Strings .isNullOrEmpty (yapiQueryDTO .getDesc ())){
@@ -438,6 +444,9 @@ public static void getRequest(Project project,YapiApiDTO yapiApiDTO,PsiMethod ps
438
444
if (Strings .isNullOrEmpty (yapiQueryDTO .getExample ()) && NormalTypes .normalTypes .containsKey (psiParameter .getType ().getPresentableText ()) ){
439
445
yapiQueryDTO .setExample (NormalTypes .normalTypes .get (psiParameter .getType ().getPresentableText ()).toString ());
440
446
}
447
+ if (Strings .isNullOrEmpty (yapiQueryDTO .getName ())){
448
+ yapiQueryDTO .setName (psiParameter .getName ());
449
+ }
441
450
list .add (yapiQueryDTO );
442
451
}
443
452
}else {
0 commit comments