public ResultInfo SavePackageImage(int packageId) { var path = Const.PackageImageDirectory; if (packageId > 0) { var busi = new PackageBusi(); var item = busi.GetItem(packageId); if (item == null) return new ResultInfo(0, ""); path += "/" + item.CreateOn.ToString("yyyyMM") + "/" + packageId; } var hashTable = SaveFile(path); if ((string) hashTable["state"] == "SUCCESS") return new ResultInfo(1, "", new {url = hashTable["url"]}); return new ResultInfo(0); }
public ActionResult Item(int id) { var busi = new PackageBusi(); return View(busi.GetItem(id)); }