Overview : input 를 TextArea 로 변경시 ViewData 가 나오지 않는 오류
예제
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
<div class="form-group"> <label asp-for="EVI_DETAIL" class="control-label"></label> <input asp-for="EVI_DETAIL" class="form-control text-uppercase" autocomplete="off" value="@ViewData["DESCRIP"]" /> <!-- 원본 input 에서 TextArea로 변경--> <TextArea id="EVI_DETAIL" rows="4" class="form-control text-uppercase" autocomplete="off">@ViewData["DESCRIP"]</TextArea> <!-- DESCRIP 나옴 --> <TextArea rows="4" asp-for="EVI_DETAIL" class="form-control text-uppercase" autocomplete="off" value="@ViewData["DESCRIP"]">@ViewData["DESCRIP"] </TextArea> <!-- DESCRIP 안나옴 --> <TextArea rows="4" asp-for="EVI_DETAIL" class="form-control text-uppercase" autocomplete="off" value="@ViewData["DESCRIP"]" />@ViewData["DESCRIP"] </TextArea> <!-- / 붙여 DESCRIP 나옴 --> <TextArea rows="4" id="EVI_DETAIL" class="form-control text-uppercase" autocomplete="off" value="@ViewData["DESCRIP"]" />@ViewData["DESCRIP"] </TextArea> <!-- id로 변경하여 DESCRIP 나옴 --> <span asp-validation-for="EVI_DETAIL" class="text-danger"></span> </div> |