Exemple #1
0
        public IHttpActionResult GetPaymode()
        {
            var paymodeList = _iPaymodeService.FindListByClause(x => x.p_state == 1);
            List <ComboboxModel> selectModels = new List <ComboboxModel>();
            ComboboxModel        selectModel1 = new ComboboxModel
            {
                Id       = 0,
                Text     = "支付类型",
                Selected = true
            };

            selectModels.Add(selectModel1);
            foreach (var paymode in paymodeList)
            {
                ComboboxModel selectModel = new ComboboxModel
                {
                    Id   = paymode.p_id,
                    Text = paymode.p_name
                };
                selectModels.Add(selectModel);
            }
            return(Ok(selectModels));
        }
Exemple #2
0
        public IHttpActionResult GetPayModeList()
        {
            var List = _iPaymodeService.FindListByClause(x => x.p_state == 1);

            return(Ok(List));
        }