View.php 954 B

123456789101112131415161718192021222324252627282930
  1. <?php namespace Psales\Manage\Lib;
  2. use Dever;
  3. class View
  4. {
  5. private $info;
  6. private $user;
  7. # 预览实体店
  8. public function getOffline($info)
  9. {
  10. $info['sales_type'] = 1;
  11. return $this->get($info);
  12. }
  13. public function get($info)
  14. {
  15. $extend = Dever::load(\Manage\Lib\Util::class)->extend();
  16. $result = Dever::load(\Place\Lib\Info::class)->share($extend['data_id'], $info['sales_type'], $info['id'], 0, true);
  17. $content[] = [
  18. 'type' => 'text',
  19. 'name' => '文本',
  20. //'content' => 'H5预览链接:<a href="'.$result['h5'].'" target="_blank">点击查看</a>',
  21. 'content' => 'H5预览链接:' . $result['h5'],
  22. # 样式primary success warning danger info exception
  23. 'style' => 'exception',
  24. ];
  25. return ['title' => '前台界面预览', 'info' => $content, 'tab' => []];
  26. }
  27. }