【商旅】修改出差审批单(行程)
名称 | 类型 | 是否必须 | 示例值 | 更多限制 | 描述 |
---|---|---|---|---|---|
rq | OpenApiApplyRq | 必须 | 请求对象 | ||
|
名称 | 类型 | 示例值 | 描述 |
---|---|---|---|
result | HisvResult | result | 结果对象 |
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 | TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret); AlitripBtripCorpopApplyModifyRequest req = new AlitripBtripCorpopApplyModifyRequest(); AlitripBtripCorpopApplyModifyRequest.OpenApiApplyRq obj1 = new AlitripBtripCorpopApplyModifyRequest.OpenApiApplyRq(); obj1.setThirdpartApplyId( "12345" ); obj1.setThirdpartBusinessId( "12345" ); obj1.setCorpId( "corp1" ); obj1.setCorpName( "阿里巴巴" ); obj1.setDepartId( "dept1" ); obj1.setDepartName( "淘宝" ); List<AlitripBtripCorpopApplyModifyRequest.OpenItineraryInfo> list3 = new ArrayList<AlitripBtripCorpopApplyModifyRequest.OpenItineraryInfo>(); AlitripBtripCorpopApplyModifyRequest.OpenItineraryInfo obj4 = new AlitripBtripCorpopApplyModifyRequest.OpenItineraryInfo(); list3.add(obj4); obj4.setArrCity( "北京" ); obj4.setArrCityCode( "BJS" ); obj4.setArrDate(StringUtils.parseDateTime( "2017-01-01 00:00:00" )); obj4.setCostCenterId(123L); obj4.setDepCity( "杭州" ); obj4.setDepCityCode( "HGH" ); obj4.setDepDate(StringUtils.parseDateTime( "2017-01-01 00:00:00" )); obj4.setInvoiceId(1234L); obj4.setItineraryId( "123456" ); obj4.setProjectCode( "xm1" ); obj4.setProjectTitle( "项目1" ); obj4.setThirdpartCostCenterId( "12345" ); obj4.setTrafficType(0L); obj4.setTripWay(0L); obj4.setThirdPartInvoiceId( "1234" ); obj4.setNeedHotel( true ); obj4.setNeedTraffic( true ); obj1.setItineraryList(list3); obj1.setStatus(0L); List<AlitripBtripCorpopApplyModifyRequest.OpenUserInfo> list6 = new ArrayList<AlitripBtripCorpopApplyModifyRequest.OpenUserInfo>(); AlitripBtripCorpopApplyModifyRequest.OpenUserInfo obj7 = new AlitripBtripCorpopApplyModifyRequest.OpenUserInfo(); list6.add(obj7); obj7.setUserId( "user1" ); obj7.setUserName( "张三" ); obj1.setTravelerList(list6); obj1.setTripCause( "北京出差" ); obj1.setTripDay(1L); obj1.setTripTitle( "北京出差" ); obj1.setUserId( "user1" ); obj1.setUserName( "张三" ); obj1.setVersion(2L); List<AlitripBtripCorpopApplyModifyRequest.OpenUserInfo> list9 = new ArrayList<AlitripBtripCorpopApplyModifyRequest.OpenUserInfo>(); AlitripBtripCorpopApplyModifyRequest.OpenUserInfo obj10 = new AlitripBtripCorpopApplyModifyRequest.OpenUserInfo(); list9.add(obj10); obj10.setUserName( "张三" ); obj1.setExternalTravelerList(list9); obj1.setHotelBudget(1000L); obj1.setFlightBudget(1000L); obj1.setTrainBudget(1000L); obj1.setVehicleBudget(1000L); obj1.setBudget(1000L); obj1.setUnionNo( "tste1" ); obj1.setBudgetMerge(1L); obj1.setLimitTraveler(1L); obj1.setTogetherBookRule(1L); AlitripBtripCorpopApplyModifyRequest.HotelShareInfo obj11 = new AlitripBtripCorpopApplyModifyRequest.HotelShareInfo(); obj11.setType( "1" ); obj11.setParam( "70" ); obj1.setHotelShare(obj11); AlitripBtripCorpopApplyModifyRequest.ExternalUserStandard obj12 = new AlitripBtripCorpopApplyModifyRequest.ExternalUserStandard(); obj12.setFlightCabins( "Y" ); obj12.setEconomyDiscount(1L); obj12.setBusinessDiscount(1L); obj12.setFirstDiscount(1L); obj12.setTrainSeats( "1" ); List<AlitripBtripCorpopApplyModifyRequest.HotelCityFee> list14 = new ArrayList<AlitripBtripCorpopApplyModifyRequest.HotelCityFee>(); AlitripBtripCorpopApplyModifyRequest.HotelCityFee obj15 = new AlitripBtripCorpopApplyModifyRequest.HotelCityFee(); list14.add(obj15); obj15.setCityCode( "330100" ); obj15.setCityName( "北京" ); obj15.setFee(10000L); obj12.setHotelCitys(list14); obj12.setReserveType(1L); obj12.setInternationalFlightCabins( "Y" ); obj12.setPremiumEconomyDiscount(1L); obj1.setExternalTravelerStandard(obj12); List<AlitripBtripCorpopApplyModifyRequest.InternalUserStandard> list17 = new ArrayList<AlitripBtripCorpopApplyModifyRequest.InternalUserStandard>(); AlitripBtripCorpopApplyModifyRequest.InternalUserStandard obj18 = new AlitripBtripCorpopApplyModifyRequest.InternalUserStandard(); list17.add(obj18); obj18.setFlightCabins( "Y" ); obj18.setEconomyDiscount(1L); obj18.setBusinessDiscount(1L); obj18.setFirstDiscount(1L); obj18.setTrainSeats( "1" ); List<AlitripBtripCorpopApplyModifyRequest.HotelCityFee> list21 = new ArrayList<AlitripBtripCorpopApplyModifyRequest.HotelCityFee>(); AlitripBtripCorpopApplyModifyRequest.HotelCityFee obj22 = new AlitripBtripCorpopApplyModifyRequest.HotelCityFee(); list21.add(obj22); obj22.setCityCode( "330100" ); obj22.setCityName( "北京" ); obj22.setFee(10000L); list19.setHotelCitys(list21); obj18.setReserveType(1L); obj18.setUserId( "weifeng" ); obj18.setInternationalFlightCabins( "Y" ); obj18.setPremiumEconomyDiscount(1L); obj1.setTravelerStandard(list17); List<AlitripBtripCorpopApplyModifyRequest.OpenItinerarySetInfo> list24 = new ArrayList<AlitripBtripCorpopApplyModifyRequest.OpenItinerarySetInfo>(); AlitripBtripCorpopApplyModifyRequest.OpenItinerarySetInfo obj25 = new AlitripBtripCorpopApplyModifyRequest.OpenItinerarySetInfo(); list24.add(obj25); obj25.setItineraryId( "asdfgh" ); obj25.setTrafficType(0L); obj25.setCitySet( "北京,上海" ); obj25.setCityCodeSet( "BJS,SHA" ); obj25.setDepDate( "2017-01-01 00:00:00" ); obj25.setArrDate( "2017-01-01 00:00:00" ); obj25.setCostCenterId(234567L); obj25.setThirdpartCostCenterId( "第三方成本中心id" ); obj25.setInvoiceId(23456L); obj25.setThirdPartInvoiceId( "第三方发票id" ); obj25.setProjectCode( "项目编号" ); obj25.setProjectTitle( "项目名称" ); obj1.setItinerarySetList(list24); obj1.setItineraryRule(0L); obj1.setExtendField( "{\"cost_center\":\"成本中心\"}" ); req.setRq(obj1); AlitripBtripCorpopApplyModifyResponse rsp = client.execute(req, sessionKey); System.out.println(rsp.getBody()); |
1 2 3 4 5 6 7 8 9 10 11 | < alitrip_btrip_corpop_apply_modify_response > < result > < module > < apply_id >123</ apply_id > < thirdpart_apply_id >12345</ thirdpart_apply_id > </ module > < result_code >0</ result_code > < result_msg >成功</ result_msg > < is_success >true</ is_success > </ result > </ alitrip_btrip_corpop_apply_modify_response > |
1 2 3 4 5 6 | < error_response > < code >50</ code > < msg >Remote service error</ msg > < sub_code >isv.invalid-parameter</ sub_code > < sub_msg >非法参数</ sub_msg > </ error_response > |
错误码 | 错误描述 | 解决方案 |
---|---|---|
-204 | 找不到申请人信息 | 在商旅企业管理后台维护申请人信息,或者通过同步企业人员接口同步申请人 |
9012 | 出行人列表用户ID(user_id)缺失 | 传入traveler_list的user_id字段 |
9002 | 找不到申请人信息 | 在商旅企业管理后台维护申请人信息,或者通过同步企业人员接口同步申请人 |
9016 | 总预算与类目预算不能同时存在 | 酒店预算,机票预算,火车票预算,用车预算不能与申请单总预算同时存在。 hotel_budget,flight_budget,train_budget,vehicle_budget(单类目预算)这一组值,和budget(总预算)这一组,只能存在一组,不能同时存在 |
9017 | union_no和单类目预算不能同时存在 | 传入union_no代表是按照总预算来管控,不可以传单类目预算。 传入union_no的情况,如果需要预算管控,只能通过总预算(budget)来管控 |
9020 | 酒店城市费用列表不能超过50个 | 外部出行人差标中的酒店城市费用列表过长,超过了50个限制。 external_traveler_standard的hotel_citys列表长度,不能超过50个 |
9019 | 酒店城市费用列表(city_code,fee)不能为空 | 出行人差标中(包括内部出行人以及外部出行人)的酒店城市费用列表的城市编码和酒店间夜金额不能为空。 external_traveler_standard/traveler_standard的hotel_citys中city_code和fee需要传值 |
9022 | 同一审批单中的所有出行人只能都限制/都不限制差标" | 如果出行人差标中有出行人不限制差标,那审批单中所有出行人都需要不限制差标。反之,如果出行人差标中有出行人限制差标,那审批单中所有出行人都需要限制差标。 external_traveler_standard/traveler_standard的reserveTypeCount都为0或者都为1 |
9007 | 用户成本中心缺失 | 传入的行程列表中有的没传成本中心。 itinerary_list中的cost_center_id或thirdpart_cost_center_id必传其一 |
9023 | 用户(%s)没有操作成本中心:%s的权限 | 传入的行程列表中的成本中心,申请单提交人没有权限使用。 检查行程列表中的成本中心是否归属于该申请单提交人 |
9008 | 用户发票抬头缺失 | 传入的行程列表中有的没传发票抬头。 itinerary_list中的invoice_id或third_part_invoice_id必传其一 |
9021 | 行程到达城市编码和出发城市编码只能都不限,或者都限制 | 行程的到达城市编码和出发城市编码只能都传0或者都是具体城市 |
9014 | 新增外部出行人失败 | 系统原因,需要重试一次 |
1020 | 原审批单不存在预算,不允许新增预算 | 修改审批单的时候新增了预算,但是原审批单不存在预算,不允许新增。 不能传入预算相关字段 |
1022 | 审批单预算使用规则不允许修改 | 描述:有以下集中情况 1. 原审批单只有budget(总预算),修改审批单不允许新增hotel_budget,flight_budget,train_budget,vehicle_budget(单类目预算)这一组值 2. 原审批单只有hotel_budget,flight_budget,train_budget,vehicle_budget(单类目预算)这一组值,修改审批单不允许新增budget(总预算)这一组值 3. 修改了审批单的budget_merge,budget_merge不允许修改 |