public JsonResult AddCompensate(AddCompensateViewModel model) { if (ModelState.IsValid) { OrderClaimCompensationItem item = new OrderClaimCompensationItem() { Compensation = model.Compensation, CompensationHappenedType = model.CompensationHappenedType, CompensationReason = model.CompensationReason, //Currency = model.Currency, ProductItemId = model.ProductItemId }; string errorMessage = AppBusinessManager.Instance.AddOrUpdateOrderCompensationItem( dxContext, item); if (!string.IsNullOrEmpty(errorMessage)) { ModelState.AddModelError(string.Empty, errorMessage); } //FIXED 添加索赔处理业务逻辑 } return(Json(this.GetModelStateErrors(ModelState))); }
/// <summary> /// 对订单添加“港口代理” /// </summary> /// <param name="dbContext"></param> /// <param name="model"></param> /// <param name="harborAgent"></param> /// <param name="userName"></param> /// <returns></returns> //public string AddOrUpdateOrderContractHarborAgent( // ExtendedIdentityDbContext dbContext, OrderContract contract, // HarborAgent harborAgent, string userName) //{ // return m_orderContractImpl.AddOrUpdateOrderContractHarborAgent( // dbContext, contract, harborAgent, userName); //} ///// <summary> ///// 对订单添加“香港物流” ///// </summary> ///// <param name="dbContext"></param> ///// <param name="hklogis"></param> ///// <param name="userName"></param> ///// <returns></returns> //public string AddOrUpdateOrderContractHKLogis( // ExtendedIdentityDbContext dbContext, OrderContract contract, // HKLogis hklogis, string userName) //{ // return m_orderContractImpl.AddOrUpdateOrderContractHKLogis( // dbContext, contract, hklogis, userName); //} ///// <summary> ///// 对订单添加“内地物流” ///// </summary> ///// <param name="dbContext"></param> ///// <param name="hklogis"></param> ///// <param name="userName"></param> ///// <returns></returns> //public string AddOrUpdateOrderContractMLLogis( // ExtendedIdentityDbContext dbContext, OrderContract contract, // MLLogis hklogis, string userName) //{ // return m_orderContractImpl.AddOrUpdateOrderContractMLLogis( // dbContext, contract, hklogis, userName); //} /// <summary> /// 根据一个ProductItem的索赔对象,新增或修改索赔 /// </summary> /// <param name="dbContext"></param> /// <param name="item"></param> /// <returns></returns> public string AddOrUpdateOrderCompensationItem( ExtendedIdentityDbContext dbContext, OrderClaimCompensationItem item) { return(m_orderContractImpl.AddOrUpdateOrderCompensationItem( dbContext, item)); }