1 [HttpPost] 2 public JsonResult ProgresBar03() 3 { 4 var bars = new List<MoBar>(); { 7 bars = _cache.Get<List<MoBar>>(cacheKey03); 8 } 9 catch (Exception ex) 10 { 11 } 12 return Json(bars); 13 }
ÕâÀïÔÙ¸ø³öÉÏ´«½ø¶ÈµÄʵÌåÀࣺ
MoData 2 { 0£ºÊ§°Ü 1£ºÉÏ´«ÖÐ 2:³É¹¦ Status { get; set; } Msg { get; set; } 9 } MoBar : MoData 12 { ÎļþÃû×Ö FileName { get; set; } µ±Ç°ÉÏ´«´óС CurrBar { get; set; } ×Ü´óС TotalBar { get; set; } ½ø¶È°Ù·Ö±È PercentBar 32 { { ; 36 } 37 } 38 }
View Codeµ½´ËtaskÈÎÎñ´¦ÀíÉÏ´«ÎļþµÄ·½Ê½¾ÍÍê³ÉÁË£¬Õ¦ÃÇÀ´¿´Í¼¿´Ð§¹û°É£º
Äܹ»Í¨¹ýʾÀý3ºÍ4µÄЧ¹ûͼ¶Ô±È³ö£¬Ã»Ê¹ÓÃTaskºÍʹÓõÄЧ¹ûÇø±ð£¬ÕâÑùЧ¹ûÄúÖµµÃÓµÓУ¬ÄÍÐĶÁÍê±¾ÎÄÄÚÈݵÄÅóÓÑ£¬Ã»ÈÃÄãʧÍû°É£¬Èç¹û¿ÉÒÔ²»·Áµã¸ö"ÔÞ"»òɨ¸öÂëÖ§³ÖÏÂ×÷Õߣ¬Ð»Ð»£»ÄÚÈÝ×îºó¸½ÉϾßÌå²âÊÔÓÃÀý´úÂ룺.NetCoreÉÏ´«¶àÎļþµÄ¼¸ÖÖʾÀý
¡¡