public JsonResult UpdateReceiveInfo(int logId, string msg)
 {
     PackageReceivingRecordBusiness b = new PackageReceivingRecordBusiness();
     if (b.UpdatePackageReceivingRecordMsg(logId, msg))
         return Json(new { status = 0 });
     else
         return Json(new { status = 101 });
 }
 public JsonResult FinishReceiving(int logId, string error)
 {
     PackageReceivingRecordBusiness b = new PackageReceivingRecordBusiness();
     if (b.FinishReceivingPackage(logId, error))
         return Json(new { status = 0 });
     else
         return Json(new { status = 101 });
 }
 public JsonResult BeginToReceive(string uuid, string hostName)
 {
     PackageReceivingRecordBusiness b = new PackageReceivingRecordBusiness();
     var o = b.AddPackageReceivingRecord(uuid, hostName);
     if (o != null)
         return Json(new { status = 0, result = new { logId = o.RecordId } });
     else
         return Json(new { status = 101 });
 }
 public JsonResult NeedToDownloadDeployedPackage(string hostName, bool verified=true)
 {
     PackageReceivingRecordBusiness b = new PackageReceivingRecordBusiness();
     bool need = !b.HasFinishReceivingNewestPackage(hostName,verified);
     return Json(new { status = 0, needToDownload = need }, JsonRequestBehavior.AllowGet);
 }
 public ActionResult Delete(int recordId)
 {
     PackageReceivingRecordBusiness b = new PackageReceivingRecordBusiness();
     b.Delete(recordId);
     return Json(new { status = 0 });
 }
Exemplo n.º 6
0
 public JsonResult GetPackageReceivingRecordList(int deployId)
 {
     PackageReceivingRecordBusiness b = new PackageReceivingRecordBusiness();
     var list = b.GetPackageReceivingRecordList(deployId);
     return Json(new { status = 0, result = new { list = list } }, JsonRequestBehavior.AllowGet);
 }