main
|
Last change
on this file since 595d2e5 was 595d2e5, checked in by mmilevski <markomilevski3@…>, 4 weeks ago |
|
Various UI bugfixes.
|
-
Property mode
set to
100644
|
|
File size:
641 bytes
|
| Line | |
|---|
| 1 | using System.ComponentModel.DataAnnotations;
|
|---|
| 2 |
|
|---|
| 3 | namespace KernelRecordsMVC.Application.ViewModels;
|
|---|
| 4 |
|
|---|
| 5 | public class CreateTrackViewModel
|
|---|
| 6 | {
|
|---|
| 7 | [Required(ErrorMessage = "Track name is required.")]
|
|---|
| 8 | [Display(Name = "Track Name")]
|
|---|
| 9 | public string SongName { get; set; } = string.Empty;
|
|---|
| 10 |
|
|---|
| 11 |
|
|---|
| 12 | [Required(ErrorMessage = "Track duration is required.")]
|
|---|
| 13 | [RegularExpression(
|
|---|
| 14 | @"^\d{1,2}:[0-5]\d$",
|
|---|
| 15 | ErrorMessage = "Track duration must be in MM:SS format, for example 03:42.")]
|
|---|
| 16 | [Display(Name = "Duration")]
|
|---|
| 17 | public string SongDuration { get; set; } = string.Empty;
|
|---|
| 18 |
|
|---|
| 19 |
|
|---|
| 20 | public List<long> ArtistIds { get; set; } = new();
|
|---|
| 21 | } |
|---|
Note:
See
TracBrowser
for help on using the repository browser.