Beispiel #1
0
        /// <summary>
        /// Save the merchant in the temp table and also if isCompleted is 1 then a new merchant would be created and the status would be inactive.
        /// </summary>
        /// <param name="entity"></param>
        /// <param name="merchantId"></param>
        /// <param name="isCompleted"></param>
        /// <returns></returns>
        public Int64 Save(MerchantTempModel entity, Int64 merchantId, string isCompleted)
        {
            Int64 _merchantId = 0;
            if (merchantId != 0)
            {
                _merchantId = new DataAccess.DataAccess().ExecuteNonQuery("avz_mrc_spUpdateMerchantTemp", new
               {
                   merchantId = merchantId,
                   businessName = entity.businessName,
                   businessStartDate = entity.businessStartDate,
                   legalName = entity.legalName,
                   industryTypeid = entity.industryTypeid,
                   businessTypeId = entity.businessTypeId,
                   rnc = entity.rnc,
                   salesRepId = entity.salesRepId,
                   modifyuserId = entity.userId,
                   isCompleted = isCompleted,
                   isDuplicate = entity.IsDuplicate == true ? "1" : "0",
               }, new { merchantId = 0 });
            }
            else
            {

                _merchantId = new DataAccess.DataAccess().ExecuteNonQuery("avz_mrc_spInsertMerchantTemp", new
              {
                  merchantId = 0,
                  businessName = entity.businessName,
                  businessStartDate = entity.businessStartDate,
                  legalName = entity.legalName,
                  industryTypeid = entity.industryTypeid,
                  businessTypeId = entity.businessTypeId,
                  rnc = entity.rnc,
                  salesRepId = entity.salesRepId,
                  insertDate = DateTime.Now,
                  insertUserId = entity.userId,
                  isCompleted = isCompleted,
              }, new { merchantId = 0 });

            }
            return _merchantId;
        }
Beispiel #2
0
 public Int64 Save(MerchantTempModel merchant, Int64 merchantId, string isCompleted)
 {
     Int64 _merchantId = 0;
     _merchantId = merchantsRepository.Save(merchant, merchantId, isCompleted);
     return _merchantId;
 }
Beispiel #3
0
 public int Complete(MerchantTempModel model, long merchantId)
 {
     throw new NotImplementedException();
 }