protected void Page_Load(object sender, EventArgs e) { var id = 0; if(int.TryParse(Request.QueryString["model"], out id)) { //SelectedModel = _dataService.GetModel(id); SelectedModel = DataService.GetModel(id); modelImage.ImageUrl = string.Format("~/model.img?id={0}&mode=full", SelectedModel.ImageId); } }
public bool ChangeModel(Model item) { if (_modelRepository == null) throw NullProviderError; return _modelRepository.UpdateModel(item); }
public bool NewModel(Model item) { if (_modelRepository == null) throw NullProviderError; return _modelRepository.AddModel(item); }