| 12345678910111213141516171819202122232425262728293031 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Web;
- namespace AppliWebANA.Models {
- public class Article {
- public static readonly Dictionary<Guid, Article> Stock;
- static Article() {
- Stock = new Dictionary<Guid, Article>();
- Article a;
- a = new Article() { Nom = "Chaussures de sécurité basiques", Prix = 156.5m, Quantite = 100 };
- Stock.Add( a.Id, a );
- a = new Article() { Nom = "Chaussures de sécurité renforcées et traitées anti-odeur", Prix = 459.95m, Quantite = 10 };
- Stock.Add( a.Id, a );
- a = new Article() { Nom = "Écan 72'' 16/10 Ultra 4k", Prix = 89574.99m, Quantite = 2 };
- Stock.Add( a.Id, a );
- }
- public Guid Id { get; set; }
- public string Nom { get; set; }
- public decimal Prix { get; set; }
- public int Quantite { get; set; }
- public Article() {
- Id = Guid.NewGuid();
- }
- }
- }
|