| xqd
@@ -32,21 +32,21 @@ class DynamicController extends AdminController
|
|
|
}
|
|
|
|
|
|
});
|
|
|
- $grid->column('img_url','图片内容')->display(function ($v){
|
|
|
-
|
|
|
- if(isset($v)){
|
|
|
- $v = json_decode($v,true);
|
|
|
- $str = '';
|
|
|
- if(count($v)>0){
|
|
|
- foreach ($v as $item){
|
|
|
- $str.='<img data-action="preview-img" src="'.$item.'" style="max-width:50px;max-height:200px;cursor:pointer" class="img img-thumbnail">';
|
|
|
- }
|
|
|
- }
|
|
|
- return $str;
|
|
|
- }else{
|
|
|
- return "";
|
|
|
- }
|
|
|
- });
|
|
|
+// $grid->column('img_url','图片内容')->display(function ($v){
|
|
|
+//
|
|
|
+// if(isset($v)){
|
|
|
+// $v = json_decode($v,true);
|
|
|
+// $str = '';
|
|
|
+// if(count($v)>0){
|
|
|
+// foreach ($v as $item){
|
|
|
+// $str.='<img data-action="preview-img" src="'.$item.'" style="max-width:50px;max-height:200px;cursor:pointer" class="img img-thumbnail">';
|
|
|
+// }
|
|
|
+// }
|
|
|
+// return $str;
|
|
|
+// }else{
|
|
|
+// return "";
|
|
|
+// }
|
|
|
+// });
|
|
|
$grid->tableCollapse(false);
|
|
|
$grid->column('content','动态内容')->limit(30);
|
|
|
$grid->column('zan_num');
|