示例#1
0
        /// <summary>
        /// 创建订单
        /// </summary>
        /// <param name="subscriptionId"></param>
        /// <param name="textbookId"></param>
        /// <param name="booksellerId"></param>
        /// <param name="declarations"></param>
        /// <param name="planCount"></param>
        /// <param name="spareCount"></param>
        /// <returns></returns>
        public static Subscription CreateSubscription(Guid subscriptionId, Guid textbookId, Guid booksellerId, SchoolYearTerm term, int planCount, int spareCount)
        {
            var sub = new Subscription
            {
                Bookseller_Id    = booksellerId,
                PlanCount        = planCount,
                SpareCount       = spareCount,
                SubscriptionDate = DateTime.Now,
                ID             = subscriptionId,
                Textbook_Id    = textbookId,
                SchoolYearTerm = term
            };

            return(sub);
        }
示例#2
0
 protected Declaration(string term)
 {
     yearTerm = new SchoolYearTerm(term);
 }