Beispiel #1
0
        // filter GL Account for scheme
        public ActionResult GetGLFeeID(GLFeeRepo GLFee)
        {
            var misdepartmentrepo = new GLFeeRepo();
            var mydata            = misdepartmentrepo.GetFeesList2(GLFee);

            List <object> data = new List <object>();

            foreach (var ddd in mydata)
            {
                string id   = ddd.Fund_Manager_Id;
                string name = ddd.Fund_Manager;

                data.Add(new { GLFeeId = id, GLFeeName = name });
            }
            return(this.Store(data));
        }
Beispiel #2
0
        public ActionResult GetGLFeeApply(GLFeeRepo GLFee)
        {
            try
            {
                if (string.IsNullOrEmpty(GLFee.Scheme_Fund_Id))
                {
                    X.Msg.Show(new MessageBoxConfig
                    {
                        Title   = "Error",
                        Message = "Please select scheme account.",
                        Buttons = MessageBox.Button.OK,
                        Icon    = MessageBox.Icon.INFO,
                        Width   = 350
                    });

                    return(this.Direct());
                }

                if (string.IsNullOrEmpty(GLFee.Fee_Id))
                {
                    X.Msg.Show(new MessageBoxConfig
                    {
                        Title   = "Error",
                        Message = "Please select fee.",
                        Buttons = MessageBox.Button.OK,
                        Icon    = MessageBox.Icon.INFO,
                        Width   = 350
                    });

                    return(this.Direct());
                }

                // GlobalValue.Get_Scheme_Today_Date(GLFee.Scheme_Id);

                //APPLY FEES EOD_ACCRUE_SF_FEES

                if (string.IsNullOrEmpty(GLFee.Fund_Manager_Id))
                {
                    GLFee.Fund_Manager_Id = "NA";
                }

                var con         = new AppSettings();
                var paramACCAPP = new DynamicParameters();
                paramACCAPP.Add("P_SCHEME_ID", GLFee.Scheme_Fund_Id, DbType.String, ParameterDirection.Input);
                paramACCAPP.Add("P_FEE_ID", GLFee.Fee_Id, DbType.String, ParameterDirection.Input);
                paramACCAPP.Add("P_FM_ID", GLFee.Fund_Manager_Id, DbType.String, ParameterDirection.Input);
                paramACCAPP.Add("P_VALUE_DATE", GlobalValue.Scheme_Today_Date, DbType.Date, ParameterDirection.Input);
                con.GetConnection().Execute("APPLY_FEES_FORCE", paramACCAPP, commandType: CommandType.StoredProcedure);

                GLFee.GetFeesList2(GLFee);
                this.GetCmp <TextField>("GLFeeCreate_FeeID").SetValue("");
                this.GetCmp <TextField>("GLFee_Apply_Bal").SetValue("");
                this.GetCmp <DateField>("GLFee_Last_Apply_Date").SetValue("");
                this.GetCmp <DateField>("GLFee_Last_Paid_Date").SetValue("");

                //PREVIEW


                return(this.Direct());
            }
            catch (System.Exception ex)
            {
                throw ex;
            }
        }