コード例 #1
0
        public dynamic Query(string NO, string NAME, string IDNO, int index = 1, int PageSize = 0)
        {
            int     count = 0;
            dynamic model = new ExpandoObject();

            var tempmodel = InvestmentTrustDA.getInstance().GetInvestmentTrust(NO, NAME, IDNO, (index - 1) * PageSize, PageSize);

            count = tempmodel.Count() > 0 ? tempmodel.FirstOrDefault().TOTALCNT : 0;

            model.TRUST     = new StaticPagedList <dynamic>(tempmodel, index, PageSize, count);
            model.TRUSTHEAD = tempmodel.Count() > 0 ? (tempmodel.FirstOrDefault() as IDictionary <string, object>).Keys.ToList() : new List <string>();
            return(model);
        }
コード例 #2
0
        public (bool MsgCode, string MsgName) DeleteInvestmentTrust(string NO)
        {
            var result = InvestmentTrustDA.getInstance().DeleteInvestmentTrust(NO);

            return(result ? (result, "成功") : (result, "失敗"));
        }
コード例 #3
0
        public (bool MsgCode, string MsgName) InsertInvestmentTrust(string NO, string NAME, string IDNO)
        {
            var result = InvestmentTrustDA.getInstance().InsertInvestmentTrust(NO, NAME, IDNO);

            return(result);
        }
コード例 #4
0
        public (bool MsgCode, string MsgName) UpdateInvestmentTrust(string NO, string NAME, string IDNO)
        {
            var result = InvestmentTrustDA.getInstance().UpdateInvestmentTrust(NO, NAME, IDNO);

            return(result ? (result, "成功") : (result, "失敗"));
        }