исправила и добавила вывод названия симптома и процедуры во вью модель
This commit is contained in:
parent
fa8d5d9d8e
commit
171ca6d819
@ -8,9 +8,19 @@ namespace PolyclinicContracts.ViewModels
|
||||
public int Id { get; set; }
|
||||
public int ProcedureId { get; set; }
|
||||
public int? SymptomId { get; set; }
|
||||
|
||||
[DisplayName("Название медикамента")]
|
||||
public string Name { get; set; } = string.Empty;
|
||||
|
||||
|
||||
[DisplayName("Комментарий")]
|
||||
public string Comment { get; set; } = string.Empty;
|
||||
|
||||
|
||||
[DisplayName("Название симптома")]
|
||||
public string SymptomName { get; set; } = string.Empty;
|
||||
|
||||
[DisplayName("Название процедуры")]
|
||||
public string ProcedureName { get; set; } = string.Empty;
|
||||
}
|
||||
}
|
||||
|
@ -12,6 +12,8 @@ namespace PolyclinicContracts.ViewModels
|
||||
|
||||
[DisplayName("Комментарий")]
|
||||
public string Comment { get; set; } = string.Empty;
|
||||
|
||||
[DisplayName("Номер курса")]
|
||||
public int? CourseId { get; set; }
|
||||
public Dictionary<int, IProcedureModel> RecipeProcedures { get; } = new();
|
||||
}
|
||||
|
@ -48,7 +48,9 @@ namespace PolyclinicDatabaseImplement.Models
|
||||
Name = Name,
|
||||
Comment = Comment,
|
||||
ProcedureId = ProcedureId,
|
||||
SymptomId = Symptom?.Id ?? null
|
||||
SymptomId = Symptom?.Id ?? null,
|
||||
SymptomName = Symptom?.Name ?? string.Empty,
|
||||
ProcedureName = Procedure?.Name ?? string.Empty,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
@ -45,35 +45,32 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<td>
|
||||
1
|
||||
</td>
|
||||
<td>
|
||||
Фенибут
|
||||
</td>
|
||||
<td>
|
||||
Сопли до колен
|
||||
</td>
|
||||
<td>
|
||||
3
|
||||
</td>
|
||||
<td>
|
||||
При особом неврозе употребляйте каждый день и спина не будет болеть
|
||||
</td>
|
||||
<td>
|
||||
<a asp-action="CreateMedicament">
|
||||
<svg class="bi-edit-pen" viewBox="0 0 127 127" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M105.5 26L37 114.5C34.5 117 16.3 121.7 7.5 122.5C79.1 34.1 101 5.5 102 4C104.833 4.5 119.3 14.6 122.5 21C105 44 98.5 55 111.5 58.5" stroke="#008315" stroke-width="6" stroke-linecap="round" />
|
||||
@foreach (var item in Model)
|
||||
{
|
||||
<td>@item.Id</td>
|
||||
<td>@item.Name</td>
|
||||
<td>@item.SymptomId.</td>
|
||||
<td>
|
||||
3
|
||||
</td>
|
||||
<td>
|
||||
При особом неврозе употребляйте каждый день и спина не будет болеть
|
||||
</td>
|
||||
<td>
|
||||
<a asp-action="CreateMedicament">
|
||||
<svg class="bi-edit-pen" viewBox="0 0 127 127" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M105.5 26L37 114.5C34.5 117 16.3 121.7 7.5 122.5C79.1 34.1 101 5.5 102 4C104.833 4.5 119.3 14.6 122.5 21C105 44 98.5 55 111.5 58.5" stroke="#008315" stroke-width="6" stroke-linecap="round" />
|
||||
</svg>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<svg class="bi-cart-delete" viewBox="0 0 154 164" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M44.5 123C4.99995 119.5 -11.8431 56.4293 24 19.5C40.5 2.50001 72.5 -5.5 101.5 27.5L115.5 14.5" stroke="#D10000" stroke-width="8" stroke-linecap="round" />
|
||||
<path d="M65.2123 159.963L56 60.0001C88.0236 76.3307 119.521 77.4194 149 60.0001C141.63 142.346 140.08 160.953 140.226 159.963H65.2123Z" stroke="#D10000" stroke-width="8" />
|
||||
<path d="M121 36L101.582 55L75 31" stroke="#D10000" stroke-width="8" stroke-linecap="round" />
|
||||
</svg>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<svg class="bi-cart-delete" viewBox="0 0 154 164" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M44.5 123C4.99995 119.5 -11.8431 56.4293 24 19.5C40.5 2.50001 72.5 -5.5 101.5 27.5L115.5 14.5" stroke="#D10000" stroke-width="8" stroke-linecap="round" />
|
||||
<path d="M65.2123 159.963L56 60.0001C88.0236 76.3307 119.521 77.4194 149 60.0001C141.63 142.346 140.08 160.953 140.226 159.963H65.2123Z" stroke="#D10000" stroke-width="8" />
|
||||
<path d="M121 36L101.582 55L75 31" stroke="#D10000" stroke-width="8" stroke-linecap="round" />
|
||||
</svg>
|
||||
</td>
|
||||
</td>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
}
|
||||
|
@ -32,8 +32,6 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
|
||||
@foreach (var item in Model)
|
||||
{
|
||||
<tr>
|
||||
|
Loading…
Reference in New Issue
Block a user