public void SubmitForm(ProfileOperationsVehicleTypeEntity vehicleEntity, string keyValue) { if (!string.IsNullOrEmpty(keyValue)) { vehicleEntity.Modify(keyValue); service.Update(vehicleEntity); try { //添加日志 LogMess.addLog(DbLogType.Update.ToString(), "修改成功", "修改作业车辆【" + vehicleEntity.VehicleTypeName + "】成功!"); } catch { } } else { vehicleEntity.Create(); service.Insert(vehicleEntity); try { //添加日志 LogMess.addLog(DbLogType.Update.ToString(), "修改成功", "新建作业车辆【" + vehicleEntity.VehicleTypeName + "】成功!"); } catch { } } }
public ActionResult SubmitForm(ProfileOperationsVehicleTypeEntity userEntity, string keyValue) { VehicleApp.SubmitForm(userEntity, keyValue); return(Success("操作成功。")); }