You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

79 lines
2.7 KiB

  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. * User: Steven
  5. * Date: 2016/12/2
  6. * Time: 19:10
  7. */
  8. class updateService extends commonService
  9. {
  10. /**
  11. *修改密码
  12. *修改访问艺龙直连push接口的用户访问密码
  13. */
  14. public function changePassword($param)
  15. {
  16. //TODO:参数验证
  17. $res = utils::xml_encode(array('NewPassword' => '4s5f4s5e'), 'utf-16', 'ChangePasswordRequest');
  18. return $res;
  19. }
  20. /**
  21. * 更新房型状态(对应超售开关)
  22. * 按酒店编码、房型编码、日期范围设置房型开/关状态。酒店编码和房型编码需要在艺龙酒店预订系统中进行配置,将酒店供应商的编码与艺龙内部编码进行映射。
  23. * @param $param
  24. */
  25. public function UpdateRoomTypeStatus($param)
  26. {
  27. $array = array(
  28. 'HotelCode' => 1, //酒店代码
  29. 'RoomTypeList' => array(
  30. 'UpdateRoomTypeStatusChangeItem' => array(
  31. 'RequestID' => 1,
  32. 'RoomTypeCode' => 'CSD',
  33. 'Status' => 'open',
  34. 'BeginDate' => '2016-12-03 00:00:00',
  35. 'EndDate' => '2016-12-04 00:00:00',
  36. 'InventoryUpdateType' => 0
  37. )
  38. )
  39. );
  40. $request = utils::xml_encode($array, $this->LoginToken, 'UpdateRoomTypeStatusRequest');
  41. $res = utils::execute($request);
  42. return $res;
  43. }
  44. /**
  45. * 更新价格有效性
  46. * 按酒店编码、房型编码、房价代码、日期范围、每周的有效日 设置房价开/关状态。酒店编码、房型编码和房价需要在艺龙酒店预订系统中进行配置,将酒店供应商的编码与艺龙内部编码进行映射
  47. * @param $param
  48. * @return string
  49. */
  50. public function UpdateRoomRateStatusReuqest($param)
  51. {
  52. $array = array(
  53. 'HotelCode' => 1,
  54. 'RoomRateList' => array(
  55. 'UpdateRoomRateStatusChangeItem' => array(
  56. 'RoomTypeCode' => 'CSD',
  57. 'Status' => 1, //1:Open;0:Close
  58. 'BeginDate' => '2016-12-03 00:00:00',
  59. 'EndDate' => '2016-12-04 00:00:00',
  60. 'DayOfWeek' => array( //有效日设置
  61. 'Mon' => true, //周一是否有效
  62. 'Tue' => true,
  63. 'Wed' => true,
  64. 'Thu' => true,
  65. 'Fri' => true,
  66. 'Sat' => true,
  67. 'Sun' => true
  68. )
  69. )
  70. )
  71. );
  72. $res = utils::xml_encode($array, $this->LoginToken, 'UpdateRoomRateStatusReuqest');
  73. return $res;
  74. }
  75. }