Example #1
0
 public BcpReportPlugin()
 {
     PluginInfo = new DataReportPluginInfo()
     {
         Guid            = "8C7B20AF-B0B3-4932-9FCB-185FDC2AA9B7",
         Name            = "BCP",
         ReportExtension = ".zip",
         Description     = "导出为Bcp格式的数据包文件",
         OrderIndex      = 0,
         Platform        = "蛛网",
         PluginType      = PluginType.SpfReport,
         Group           = ""
     };
 }
Example #2
0
 public HtmlReportPlugin()
 {
     PluginInfo = new DataReportPluginInfo()
     {
         Guid            = "DC22CD47-D05D-49D1-8B4E-98039FCB2BB0",
         Name            = "Html报表",
         ReportExtension = ".html",
         Description     = "导出为Html格式的报表",
         OrderIndex      = 0,
         Platform        = "效率源",
         PluginType      = PluginType.SpfReport,
         Group           = ""
     };
 }
Example #3
0
        protected override void Initialize(DataReportPluginArgument arg, IAsyncTaskProgress progress)
        {
            DataReportPluginInfo plugin = (DataReportPluginInfo)PluginInfo;

            if (plugin.Modules.Count == 0)
            {
                throw new Exception("Modules is null");
            }
            _module = plugin.Modules.FirstOrDefault(m => m.Name == arg.ReportModuleName) ?? plugin.Modules[0]; //默认使用第一个模板
            if (!Directory.Exists(arg.ReportPath))
            {
                Directory.CreateDirectory(arg.ReportPath);
            }
            BaseUtility.Helper.FileHelper.CopyDirectory(_module.ZipTempDirectory, arg.ReportPath);      //拷贝模板文件目录
        }