示例#1
0
        public Boolean SendReportSftp(DateOfOrder date)
        {
            try
            {
                String    report      = CreateReport(date);
                String [] reportParts = report.Split('\\');
                SftpService.UploadFile(report, @"\pub\" + reportParts[1]);
                SmptServerService.SendEMailNotification(report, "report");

                return(true);
            }
            catch (Exception e) { return(false); }
        }
        public Boolean SendPrescriptionSftp(EPrescription prescription)
        {
            String prescriptionFile = CreatePrescription(prescription);

            String[] prescriptionParts = prescriptionFile.Split("\\");

            try {
                SftpService.UploadFile(prescriptionFile, @"\pub\" + prescriptionParts[1]);
                SmptServerService.SendEMailNotification(prescriptionFile, "prescription");
                return(true);
            }
            catch (Exception e) { return(false); }
        }