BaseExpress.php 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <?php
  2. namespace ln\services;
  3. use ln\basic\BaseStorage;
  4. /**
  5. * Class BaseExpress
  6. * @package ln\basic
  7. */
  8. abstract class BaseExpress extends BaseStorage
  9. {
  10. /**
  11. * access_token
  12. * @var null
  13. */
  14. protected $accessToken = NULL;
  15. public function __construct(string $name, AccessTokenServeService $accessTokenServeService, string $configFile)
  16. {
  17. parent::__construct($name, [], $configFile);
  18. $this->accessToken = $accessTokenServeService;
  19. }
  20. /**
  21. * 初始化
  22. * @param array $config
  23. * @return mixed|void
  24. */
  25. protected function initialize(array $config = [])
  26. {
  27. // parent::initialize($config);
  28. }
  29. /**
  30. * 开通服务
  31. * @return mixed
  32. */
  33. abstract public function open();
  34. /**物流追踪
  35. * @return mixed
  36. */
  37. abstract public function query(string $num, string $com = '');
  38. /**电子面单
  39. * @return mixed
  40. */
  41. abstract public function dump($merId,$data);
  42. /**快递公司
  43. * @return mixed
  44. */
  45. // abstract public function express($type, $page, $limit);
  46. /**面单模板
  47. * @return mixed
  48. */
  49. abstract public function temp(string $com);
  50. }