Fleaalbum.php 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. <?php
  2. namespace app\home\controller;
  3. use think\facade\View;
  4. use think\facade\Lang;
  5. /**
  6. *
  7. *
  8. * ----------------------------------------------------------------------------
  9. *
  10. * 控制器
  11. */
  12. class FLeaalbum extends BaseFleaMember
  13. {
  14. /**
  15. * 验证是否开启闲置功能
  16. */
  17. public function initialize()
  18. {
  19. parent::initialize(); // TODO: Change the autogenerated stub
  20. Lang::load(base_path() . 'home/lang/' . config('lang.default_lang') . '/memberstorealbum.lang.php');
  21. }
  22. /**
  23. * 闲置图片列表,发布闲置调用
  24. */
  25. public function pic_list()
  26. {
  27. /**
  28. * 实例化相册类
  29. */
  30. $flea_model = model('flea');
  31. /**
  32. * 图片列表
  33. */
  34. $param = array();
  35. $param['store_id'] = session('member_id');
  36. $param['item_id'] = input('goods_id');
  37. $pic_list = $flea_model->getFleauploadList($param, 12);
  38. View::assign('pic_list', $pic_list);
  39. View::assign('show_page', $flea_model->page_info->render());
  40. if (input('item') == 'goods') {
  41. return View::fetch($this->template_dir . 'store_flea_sample');
  42. } elseif (input('item') == 'des') {
  43. return View::fetch($this->template_dir . 'store_flea_sample_des');
  44. }
  45. }
  46. }