public JsonResult IsChecker(int StoreId, int StorageId) { var isChecking = _storeContract.IsInCheckingStat(StoreId); int count = isChecking ? 1 : 0; return(Json(count)); }
/// <summary> /// 加载退货视图 /// </summary> /// <param name="Id"></param> /// <returns></returns> public ActionResult Return(string retailNumber) { if (string.IsNullOrEmpty(retailNumber)) { return(Json(new OperationResult(OperationResultType.Error, "参数错误"))); } var retailEntity = _retailContract.Retails.Where(r => !r.IsDeleted && r.IsEnabled && r.RetailNumber == retailNumber).FirstOrDefault(); if (retailEntity == null) { return(Json(new OperationResult(OperationResultType.Error, "订单不存在"))); } var isChecking = _storeContract.IsInCheckingStat(retailEntity.StoreId.Value); if (isChecking) { return(Json(new OperationResult(OperationResultType.Error, "店铺正在盘点,无法进行退货操作!"))); } //获取订单下可退的商品 ViewBag.RetailNumber = retailNumber; return(PartialView()); }