コード例 #1
0
ファイル: DownloadITR.xaml.cs プロジェクト: paraneye/WinApp
        //Qaqcformtemplate Load From File
        public async Task<List<QaqcformtemplateDTO>> LoadToQaqcformtemplate()
        {
            List<QaqcformtemplateDTO> filedto = new List<QaqcformtemplateDTO>();
            try
            {
                WinAppLibrary.Utilities.Helper helper = new WinAppLibrary.Utilities.Helper();
                var stream = await helper.GetFileStream(BaseFolder, Lib.ITRList.DownloadList );
                filedto = await (new WinAppLibrary.Utilities.Helper()).EncryptDeserializeFrom<List<RevealProjectSvc.QaqcformtemplateDTO>>(stream);
            }
            catch (Exception e)
            {
                (new WinAppLibrary.Utilities.Helper()).ExceptionHandler(e, "LoadToQaqcformtemplate");
                throw e;
            }

            return filedto;
        }
コード例 #2
0
ファイル: CrewBrassOut.xaml.cs プロジェクト: paraneye/WinApp
        private async Task<Dictionary<string, List<RevealProjectSvc.DailybrasssignDTO>>> GetSigninList()
        {
            Dictionary<string, List<RevealProjectSvc.DailybrasssignDTO>> retValue = new Dictionary<string, List<RevealProjectSvc.DailybrasssignDTO>>();
            WinAppLibrary.Utilities.Helper helper = new WinAppLibrary.Utilities.Helper();

            try
            {
                //Get Crew BrassSignIn List
                var stream = await helper.GetFileStream(Lib.ContentPath.OffModeUserFolder, Lib.ContentPath.BrassSignIn);
                var list = await (new WinAppLibrary.Utilities.Helper()).EncryptDeserializeFrom<List<RevealProjectSvc.DailybrasssignDTO>>(stream);
                retValue.Add(Lib.HashKey.Key_CrewBrassIn, list);

            }
            catch (Exception e)
            {
                helper.ExceptionHandler(e, "GetGrouping-BrassSignIn");
                throw e;
            }

            return retValue;
        }
コード例 #3
0
ファイル: DownloadITR.xaml.cs プロジェクト: paraneye/WinApp
        //Qaqcformtemplate Save To File
        public async Task<bool> SaveToQaqcformtemplate(List<QaqcformtemplateDTO> dto, Windows.Storage.StorageFolder _path, string _filename)
        {
            bool retValue = false;
            WinAppLibrary.Utilities.Helper helper = new WinAppLibrary.Utilities.Helper();

            try
            {
                var xmlstream = FormSerialize.EncryptHashSerializeTo<List<QaqcformtemplateDTO>>(dto);
                await helper.SaveFileStream(_path, _filename, xmlstream);
                retValue = true;                                                
            }
            catch (Exception e)
            {
                helper.ExceptionHandler(e, "SaveToQaqcformtemplate");
                throw e;
            }

            return retValue;
        }