Exemplo n.º 1
0
        public ActionResult GetFormJson(string keyValue)
        {
            var         data = noticeBLL.GetEntity(keyValue);
            FileInfoBLL fi   = new FileInfoBLL();
            IList       list = fi.GetFilesByRecId(keyValue);

            return(ToJsonResult(new { formData = data, files = list }));
        }
Exemplo n.º 2
0
        public ActionResult GetFormJson(string keyValue)
        {
            var                  data     = safetydaybll.GetEntity(keyValue);
            FileInfoBLL          fi       = new FileInfoBLL();
            IList                list     = fi.GetFilesByRecId(keyValue);
            var                  json     = JsonConvert.SerializeObject(list);
            List <FileInfoModel> fileList = JsonConvert.DeserializeObject <List <FileInfoModel> >(json);

            fileList.ForEach(x =>
            {
                if (x.FileExtensions.ToLower().Contains("gw"))
                {
                    x.FilePath = x.FilePath.ToLower().Replace(".gw", ".pdf");
                }
            });
            return(ToJsonResult(new { formData = data, files = fileList }));
        }
Exemplo n.º 3
0
        public ActionResult getFile(string keyValue)
        {
            var file = filebll.GetFilesByRecId(keyValue);

            return(Content(file.ToJson()));
        }