Pay.php 592 B

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. * User: qisse
  5. * Date: 2017/6/27
  6. * Time: 20:02
  7. */
  8. namespace app\mobile\logic;
  9. use app\core\service\Pay as Service;
  10. use tool\Common;
  11. class Pay extends Base
  12. {
  13. public function createOrder()
  14. {
  15. $this->app = [
  16. 'money'=>300,
  17. 'orderID'=>12
  18. ];
  19. //Cang::get($this->app['order']);
  20. $service = new Service();
  21. $order = $service->createOrder(300);
  22. if(!$order) {
  23. return Common::rm(-3, '操作失败');
  24. }
  25. return Common::rm(1, '操作成功', $order);
  26. }
  27. }