public ActionResult Load_Employee_Report_IFrame(string containerId, string ESF_Id, string tree_node_id, GLTBtRepo TBREPO) { if (string.IsNullOrEmpty(ESF_Id)) { X.Msg.Show(new MessageBoxConfig { Title = "Error", Message = "Select an employee account.", Buttons = MessageBox.Button.OK, Icon = MessageBox.Icon.INFO, Width = 350 }); return(this.Direct()); } if (!TBREPO.TB_Date.HasValue) { X.Msg.Show(new MessageBoxConfig { Title = "Error", Message = "Select Date.", Buttons = MessageBox.Button.OK, Icon = MessageBox.Icon.INFO, Width = 350 }); return(this.Direct()); } GlobalValue.Report_Param_1 = ESF_Id; GlobalValue.Report_Param_2 = TBREPO.TB_Date; GlobalValue.Report_Index_Id = tree_node_id; GlobalValue.Report_Param_2_string = GlobalValue.User_ID; this.GetCmp <Panel>(containerId).LoadContent(new ComponentLoader { Url = Url.Action("Load_Employee_Report"), DisableCaching = true, Mode = LoadMode.Frame }); return(this.Direct()); }
public ActionResult Load_Employer_Report_IFrame(string containerId, string Scheme_Fund_Id, string tree_node_id, GLTBtRepo TBREPO) { if (string.IsNullOrEmpty(Scheme_Fund_Id)) { X.Msg.Show(new MessageBoxConfig { Title = "Error", Message = "Select Scheme Account.", Buttons = MessageBox.Button.OK, Icon = MessageBox.Icon.INFO, Width = 350 }); X.Mask.Hide(); return(this.Direct()); } if (!TBREPO.TB_Date.HasValue) { X.Msg.Show(new MessageBoxConfig { Title = "Error", Message = "Select Date.", Buttons = MessageBox.Button.OK, Icon = MessageBox.Icon.INFO, Width = 350 }); X.Mask.Hide(); return(this.Direct()); } GlobalValue.Report_Param_1 = Scheme_Fund_Id; GlobalValue.Report_Param_2 = TBREPO.TB_Date; GlobalValue.Report_Param_2_string = GlobalValue.User_ID; GlobalValue.Report_Index_Id = tree_node_id; if (GlobalValue.Report_Index_Id == "employer_report1") { //load report table var con = new AppSettings(); var param = new DynamicParameters(); param.Add("P_SCHEMEFUNDID", GlobalValue.Report_Param_1, DbType.String, ParameterDirection.Input); param.Add("P_DATE", GlobalValue.Report_Param_2, DbType.DateTime, ParameterDirection.Input); param.Add("P_MAKER_ID", GlobalValue.User_ID, DbType.String, ParameterDirection.Input); con.GetConnection().Execute("REPORT_INSERT_CINAAFB", param, commandType: CommandType.StoredProcedure); X.Mask.Hide(); } else if (GlobalValue.Report_Index_Id == "employer_report2") { //load report table var con = new AppSettings(); var param = new DynamicParameters(); param.Add("P_SCHEMEFUNDID", GlobalValue.Report_Param_1, DbType.String, ParameterDirection.Input); param.Add("P_DATE", GlobalValue.Report_Param_2, DbType.DateTime, ParameterDirection.Input); param.Add("P_MAKER_ID", GlobalValue.User_ID, DbType.String, ParameterDirection.Input); con.GetConnection().Execute("REPORT_INSERT_NAAFB", param, commandType: CommandType.StoredProcedure); X.Mask.Hide(); } else if (GlobalValue.Report_Index_Id == "employer_report3") { //load report table var con = new AppSettings(); var param = new DynamicParameters(); param.Add("P_SCHEMEFUNDID", GlobalValue.Report_Param_1, DbType.String, ParameterDirection.Input); param.Add("P_DATE", GlobalValue.Report_Param_2, DbType.DateTime, ParameterDirection.Input); param.Add("P_MAKER_ID", GlobalValue.User_ID, DbType.String, ParameterDirection.Input); con.GetConnection().Execute("REPORT_INSERT_TB_MONTHLY", param, commandType: CommandType.StoredProcedure); X.Mask.Hide(); } else if (GlobalValue.Report_Index_Id == "employer_report4") { //load report table var con = new AppSettings(); var param = new DynamicParameters(); param.Add("P_SCHEMEFUNDID", GlobalValue.Report_Param_1, DbType.String, ParameterDirection.Input); param.Add("P_DATE", GlobalValue.Report_Param_2, DbType.DateTime, ParameterDirection.Input); param.Add("P_MAKER_ID", GlobalValue.User_ID, DbType.String, ParameterDirection.Input); con.GetConnection().Execute("REPORT_INSERT_TB", param, commandType: CommandType.StoredProcedure); X.Mask.Hide(); } else if (GlobalValue.Report_Index_Id == "employer_report5") { //load report table var con = new AppSettings(); var param = new DynamicParameters(); param.Add("P_SCHEMEFUNDID", GlobalValue.Report_Param_1, DbType.String, ParameterDirection.Input); param.Add("P_DATE", GlobalValue.Report_Param_2, DbType.DateTime, ParameterDirection.Input); param.Add("P_MAKER_ID", GlobalValue.User_ID, DbType.String, ParameterDirection.Input); con.GetConnection().Execute("REPORT_INSERT_CASHFLOW", param, commandType: CommandType.StoredProcedure); X.Mask.Hide(); } else { X.Mask.Hide(); return(this.Direct()); } this.GetCmp <Panel>(containerId).LoadContent(new ComponentLoader { Url = Url.Action("Load_Employee_Report"), DisableCaching = true, Mode = LoadMode.Frame }); return(this.Direct()); }
public ActionResult Load_Employer_Report_IFrame(string containerId, string Scheme_Id, string tree_node_id, GLTBtRepo TBREPO) { if (string.IsNullOrEmpty(Scheme_Id)) { X.Msg.Show(new MessageBoxConfig { Title = "Error", Message = "Select Scheme Account.", Buttons = MessageBox.Button.OK, Icon = MessageBox.Icon.INFO, Width = 350 }); X.Mask.Hide(); return(this.Direct()); } if (!TBREPO.TB_Date.HasValue) { X.Msg.Show(new MessageBoxConfig { Title = "Error", Message = "Select Date.", Buttons = MessageBox.Button.OK, Icon = MessageBox.Icon.INFO, Width = 350 }); X.Mask.Hide(); return(this.Direct()); } GlobalValue.Report_Param_1 = Scheme_Id; GlobalValue.Report_Param_2 = TBREPO.TB_Date; GlobalValue.Report_Param_2_string = GlobalValue.User_ID; GlobalValue.Report_Index_Id = tree_node_id; if (GlobalValue.Report_Index_Id == "employer_report1") { //load report table var con = new AppSettings(); var param = new DynamicParameters(); param.Add("P_SCHEMEFUNDID", GlobalValue.Report_Param_1, DbType.String, ParameterDirection.Input); param.Add("P_DATE", GlobalValue.Report_Param_2, DbType.DateTime, ParameterDirection.Input); param.Add("P_MAKER_ID", GlobalValue.User_ID, DbType.String, ParameterDirection.Input); con.GetConnection().Execute("REPORT_INSERT_CINAAFB_S", param, commandType: CommandType.StoredProcedure); ////load report //string pa = Server.MapPath("~/Penfad_Reports/CINAAFB_S.dll"); //System.Reflection.Assembly assembly_1 = System.Reflection.Assembly.LoadFrom(pa); //StiReport My_Report = StiReport.GetReportFromAssembly(assembly_1); ////////asign constring //My_Report.Dictionary.DataStore.Clear(); ////My_Report.Dictionary.Databases.Add(new StiSqlDatabase("TekSolPenfad", GlobalValue.ConString)); //My_Report.Dictionary.Databases.Add(new StiOracleDatabase("con", GlobalValue.ConString)); //My_Report[":P_SFID"] = GlobalValue.Report_Param_1; //My_Report[":P_ID"] = GlobalValue.Report_Param_2_string; //return StiMvcViewer.GetReportSnapshotResult(My_Report); X.Mask.Hide(); } else if (GlobalValue.Report_Index_Id == "employer_report2") { //load report table var con = new AppSettings(); var param = new DynamicParameters(); param.Add("P_SCHEMEFUNDID", GlobalValue.Report_Param_1, DbType.String, ParameterDirection.Input); param.Add("P_DATE", GlobalValue.Report_Param_2, DbType.DateTime, ParameterDirection.Input); param.Add("P_MAKER_ID", GlobalValue.User_ID, DbType.String, ParameterDirection.Input); con.GetConnection().Execute("REPORT_INSERT_NAAFB_S", param, commandType: CommandType.StoredProcedure); //string pa = Server.MapPath("~/Penfad_Reports/NAAFB_S.dll"); //System.Reflection.Assembly assembly_1 = System.Reflection.Assembly.LoadFrom(pa); //StiReport My_Report = StiReport.GetReportFromAssembly(assembly_1); ////////asign constring //My_Report.Dictionary.DataStore.Clear(); ////My_Report.Dictionary.Databases.Add(new StiSqlDatabase("TekSolPenfad", GlobalValue.ConString)); //My_Report.Dictionary.Databases.Add(new StiOracleDatabase("con", GlobalValue.ConString)); //My_Report[":P_SFID"] = GlobalValue.Report_Param_1; //My_Report[":P_ID"] = GlobalValue.Report_Param_2_string; //return StiMvcViewer.GetReportSnapshotResult(My_Report); X.Mask.Hide(); } else if (GlobalValue.Report_Index_Id == "employer_report3") { //load report table var con = new AppSettings(); var param = new DynamicParameters(); param.Add("P_SCHEMEFUNDID", GlobalValue.Report_Param_1, DbType.String, ParameterDirection.Input); param.Add("P_DATE", GlobalValue.Report_Param_2, DbType.DateTime, ParameterDirection.Input); param.Add("P_MAKER_ID", GlobalValue.User_ID, DbType.String, ParameterDirection.Input); con.GetConnection().Execute("REPORT_INSERT_TB_MONTHLY_S", param, commandType: CommandType.StoredProcedure); //string pa = Server.MapPath("~/Penfad_Reports/MTB_S.dll"); //System.Reflection.Assembly assembly_1 = System.Reflection.Assembly.LoadFrom(pa); //StiReport My_Report = StiReport.GetReportFromAssembly(assembly_1); ////////asign constring //My_Report.Dictionary.DataStore.Clear(); ////My_Report.Dictionary.Databases.Add(new StiSqlDatabase("TekSolPenfad", GlobalValue.ConString)); //My_Report.Dictionary.Databases.Add(new StiOracleDatabase("con", GlobalValue.ConString)); //My_Report[":P_SFID"] = GlobalValue.Report_Param_1; //My_Report[":P_ID"] = GlobalValue.Report_Param_2_string; //return StiMvcViewer.GetReportSnapshotResult(My_Report); X.Mask.Hide(); } else if (GlobalValue.Report_Index_Id == "employer_report4") { //load report table var con = new AppSettings(); var param = new DynamicParameters(); param.Add("P_SCHEMEFUNDID", GlobalValue.Report_Param_1, DbType.String, ParameterDirection.Input); param.Add("P_DATE", GlobalValue.Report_Param_2, DbType.DateTime, ParameterDirection.Input); param.Add("P_MAKER_ID", GlobalValue.User_ID, DbType.String, ParameterDirection.Input); con.GetConnection().Execute("REPORT_INSERT_TB_S", param, commandType: CommandType.StoredProcedure); //string pa = Server.MapPath("~/Penfad_Reports/YTB_S.dll"); //System.Reflection.Assembly assembly_1 = System.Reflection.Assembly.LoadFrom(pa); //StiReport My_Report = StiReport.GetReportFromAssembly(assembly_1); ////////asign constring //My_Report.Dictionary.DataStore.Clear(); ////My_Report.Dictionary.Databases.Add(new StiSqlDatabase("TekSolPenfad", GlobalValue.ConString)); //My_Report.Dictionary.Databases.Add(new StiOracleDatabase("con", GlobalValue.ConString)); //My_Report[":P_SFID"] = GlobalValue.Report_Param_1; //My_Report[":P_ID"] = GlobalValue.Report_Param_2_string; //return StiMvcViewer.GetReportSnapshotResult(My_Report); X.Mask.Hide(); } else if (GlobalValue.Report_Index_Id == "employer_report5") { //load report table var con = new AppSettings(); var param = new DynamicParameters(); param.Add("P_SCHEMEFUNDID", GlobalValue.Report_Param_1, DbType.String, ParameterDirection.Input); param.Add("P_DATE", GlobalValue.Report_Param_2, DbType.DateTime, ParameterDirection.Input); param.Add("P_MAKER_ID", GlobalValue.User_ID, DbType.String, ParameterDirection.Input); con.GetConnection().Execute("REPORT_INSERT_CASHFLOW_S", param, commandType: CommandType.StoredProcedure); //string pa = Server.MapPath("~/Penfad_Reports/CASHFLOW_S.dll"); //System.Reflection.Assembly assembly_1 = System.Reflection.Assembly.LoadFrom(pa); //StiReport My_Report = StiReport.GetReportFromAssembly(assembly_1); ////////asign constring //My_Report.Dictionary.DataStore.Clear(); ////My_Report.Dictionary.Databases.Add(new StiSqlDatabase("TekSolPenfad", GlobalValue.ConString)); //My_Report.Dictionary.Databases.Add(new StiOracleDatabase("con", GlobalValue.ConString)); //My_Report[":P_SFID"] = GlobalValue.Report_Param_1; //My_Report[":P_ID"] = GlobalValue.Report_Param_2_string; //return StiMvcViewer.GetReportSnapshotResult(My_Report); X.Mask.Hide(); } else { X.Mask.Hide(); return(this.Direct()); } this.GetCmp <Panel>(containerId).LoadContent(new ComponentLoader { Url = Url.Action("Load_Employee_Report"), DisableCaching = true, Mode = LoadMode.Frame }); X.Mask.Hide(); return(this.Direct()); }