public static ProductWrapper CreateEmptyProduct(UserWrapper user)
        {
            var wrapper = new ProductWrapper(new product());

            wrapper.Genre       = new GenreWrapper(new dic_Genre());
            wrapper.Condition   = new ConditionWrapper(new dic_condition());
            wrapper.ProductType = new ProductTypeWrapper(new dic_Product_type());
            wrapper.OwnerId     = user.Id;
            wrapper.UpdateDate  = DateTime.Now;
            wrapper.UpdateWho   = user.Id;

            return(wrapper);
        }
 public static SellOfferWrapper CreateSellOffer(UserWrapper _user)
 {
     return(new SellOfferWrapper(new sell_Offer())
     {
         SellerId = _user.Id,
         UpdateDate = DateTime.Now,
         UpdateWho = _user.Id,
         Product = new ProductWrapper(new product())
         {
             OwnerId = _user.Id,
             UpdateDate = DateTime.Now,
             UpdateWho = _user.Id,
             Genre = new GenreWrapper(new dic_Genre()),
             Condition = new ConditionWrapper(new dic_condition()),
             ProductType = new ProductTypeWrapper(new dic_Product_type())
         },
         StatusId = (int)TransactionState.Created,
     });
 }
 public static BuyOfferWrapper CreateEmptyBuyOffer(UserWrapper _user)
 {
     return(new BuyOfferWrapper(new buy_Offer())
     {
         BuyerId = _user.Id,
         UpdateDate = DateTime.Now,
         UpdateWho = _user.Id,
         Product = new ProductWrapper(new product())
         {
             OwnerId = _user.Id,
             UpdateDate = DateTime.Now,
             UpdateWho = _user.Id,
             Genre = new GenreWrapper(new dic_Genre()),
             Condition = new ConditionWrapper(new dic_condition()),
             ProductType = new ProductTypeWrapper(new dic_Product_type()),
             Stock = 0
         },
         StatusId = (int)TransactionState.Created,
     });
 }