Exemplo n.º 1
0
        /// <summary>
        /// 获取收发票列表
        /// </summary>
        /// <returns></returns>
        public JsonResult ReceiveBill_getList()
        {
            DaReceiveBill dal = new DaReceiveBill();
            IList<ReceiveBill> bills = dal.getList();

            var result = new CustomJsonResult();
            result.dateFormat = "yyyy-MM-dd";
            result.Data = new { total = bills.Count, rows = bills };
            return result;
        }
Exemplo n.º 2
0
        /// <summary>
        /// 获取发票收到情况列表
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public JsonResult ReceiveBillList_getList(string id)
        {
            DaReceiveBill dal = new DaReceiveBill();
            IList<ReceiveBill> list = dal.getList(id);

            var result = new CustomJsonResult();
            result.dateFormat = "yyyy-MM-dd";
            result.Data = new { total = list.Count, rows = list };
            return result;
        }
Exemplo n.º 3
0
        public JsonResult ReceiveBill_add(string orderID, string type, string target, string money, string date)
        {
            ReceiveBill en = new ReceiveBill();
            en.orderID = orderID;
            en.type = Convert.ToInt32(type);
            en.targetID = Convert.ToInt32(target);
            en.money = Convert.ToDouble(money);
            en.date = Convert.ToDateTime(date);

            DaReceiveBill dal = new DaReceiveBill();
            var result = new CustomJsonResult();
            result.Data = dal.add(en);
            return result;
        }