Exemplo n.º 1
0
        public void save(Trackable obj, string export_dir, SaveOptions options = null)
        {
            var saved_model    = new SavedModel();
            var meta_graph_def = new MetaGraphDef();

            saved_model.MetaGraphs.Add(meta_graph_def);
            _build_meta_graph(obj, export_dir, options, meta_graph_def);
        }
        public ActionResult Index(UserModel modelDTO)
        {
            string fileName = string.Empty;

            if (ModelState.IsValid)
            {
                if (modelDTO.Attachment.Length > 0 && modelDTO.Attachment[0].ContentLength > 0)
                {
                    fileName = string.Format("~/Content/Files/{0}", modelDTO.Attachment[0].FileName);
                    modelDTO.Attachment[0].SaveAs(Server.MapPath(fileName));
                }
            }
            SavedModel model = new SavedModel();

            model.UserName = modelDTO.UserName;
            model.FileUrl  = fileName;
            return(View("Complete", model));
        }