動くコード図鑑技術記事現場の渡り方キャリア論すべての記事About
C#

InspectionLicense

出典: ASP.NETでViewからControllerへ値を投げる方法!前提条件の確認! / InspectionLicense

InspectionLicense (csharp)#65f916f3dc5a
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Web;
using Microsoft.SqlServer.Server;
 
namespace CarInspection.Models
{
    public class InspectionLicense
    {
        public int Id { get; set; }
    [DisplayName("車検証名")]
    public string Name { get; set; }
 
    [DisplayName("備考")]
    public string Memo { get; set; }
 
    [DisplayName("満了日")]
    [DataType(DataType.Date)]
    public DateTime Expiration { get; set; }
 
    public DateTime Created { get; set; }
    public DateTime Updated { get; set; }
 
    public virtual Car Car { get; set; }
 
    [NotMapped]
    public int CarId { get; set; }
 
}
▸ この snippet は実行結果未収録
▸ 実行結果は未収録です
  • id: #65f916f3dc5a
  • lines: 33
  • extracted: 2026-06-10

Source収録記事

この snippet は記事の「前提条件の確認! / InspectionLicense」セクションに登場する。コードの前後の文脈・ハマりどころの解説は記事本文で。

同じ記事から

6
図鑑トップ