调整友邻集市服务

master
yin5th 2022-10-18 16:36:17 +08:00
parent 0e645d47d8
commit 58e549aa3b
5 changed files with 21 additions and 21 deletions

View File

@ -35,6 +35,9 @@ class Category extends Base
//新闻碎片 //新闻碎片
public const CATEGORY_SERVE_BLOCK = 16; public const CATEGORY_SERVE_BLOCK = 16;
//集市服务
public const CATEGORY_SERVE_LIST = 42;
// 案例模版 // 案例模版
public const TEMPLATE_NEWS = 'news_list'; public const TEMPLATE_NEWS = 'news_list';

View File

@ -11,7 +11,7 @@
</div> </div>
</div> </div>
{if in_array($category['id'], [9,10,23,24,25,40])} {if in_array($category['id'], [9,10,23,24,25,40,42])}
<div class="layui-form-itemBox3 between"> <div class="layui-form-itemBox3 between">
<div class="layui-form-item"> <div class="layui-form-item">
<label class="layui-form-label">英文标题</label> <label class="layui-form-label">英文标题</label>
@ -61,7 +61,7 @@
</div> </div>
{/if} {/if}
{if !(in_array($category['id'],[5]))} {if !(in_array($category['id'],[5,42]))}
<div class="layui-form-item"> <div class="layui-form-item">
<label class="layui-form-label">手机封面图</label> <label class="layui-form-label">手机封面图</label>
<div class="layui-input-block"> <div class="layui-input-block">
@ -154,7 +154,7 @@
--> -->
{if !isset($allowSummary) || $allowSummary} {if !isset($allowSummary) || $allowSummary}
{if !(in_array($category['id'],[4,5,9,10,6,35,36]))} {if !(in_array($category['id'],[4,5,9,10,6,35,36,42]))}
<div class="layui-form-itemBox2 between"> <div class="layui-form-itemBox2 between">
<div class="layui-form-item"> <div class="layui-form-item">
{if $category['id'] == 37} {if $category['id'] == 37}

View File

@ -13,7 +13,7 @@
</div> </div>
</div> </div>
{if in_array($category['id'], [9,10,23,24,25,40])} {if in_array($category['id'], [9,10,23,24,25,40,42])}
<div class="layui-form-itemBox3 between"> <div class="layui-form-itemBox3 between">
<div class="layui-form-item"> <div class="layui-form-item">
<label class="layui-form-label">英文标题</label> <label class="layui-form-label">英文标题</label>
@ -72,7 +72,7 @@
</div> </div>
{/if} {/if}
{if !(in_array($category['id'],[5]))} {if !(in_array($category['id'],[5,42]))}
<div class="layui-form-item"> <div class="layui-form-item">
<label class="layui-form-label">手机封面图</label> <label class="layui-form-label">手机封面图</label>
<div class="layui-input-block"> <div class="layui-input-block">
@ -165,7 +165,7 @@
--> -->
{if !isset($allowSummary) || $allowSummary} {if !isset($allowSummary) || $allowSummary}
{if !(in_array($category['id'],[4,5,9,10,6,35,36]))} {if !(in_array($category['id'],[4,5,9,10,6,35,36,42]))}
<div class="layui-form-itemBox2 between"> <div class="layui-form-itemBox2 between">
<div class="layui-form-item"> <div class="layui-form-item">
{if $category['id'] == 37} {if $category['id'] == 37}

View File

@ -59,7 +59,9 @@ use app\model\Category as VCategory;
{if $category.id!=5} {if $category.id!=5}
<col width="75px"> <col width="75px">
{/if} {/if}
{if $category.id!=42}
<col width="75px"> <col width="75px">
{/if}
<col > <col >
<!-- <col width="75px">--> <!-- <col width="75px">-->
<col width="145px"> <col width="145px">
@ -69,7 +71,6 @@ use app\model\Category as VCategory;
{/if} {/if}
<col width="75px"> <col width="75px">
<col width="75px"> <col width="75px">
<col width="75px">
<col width=""> <col width="">
</colgroup> </colgroup>
<thead> <thead>
@ -77,7 +78,9 @@ use app\model\Category as VCategory;
{if $category.id!=5} {if $category.id!=5}
<td>封面</td> <td>封面</td>
{/if} {/if}
{if $category.id!=42}
<td>手机封面</td> <td>手机封面</td>
{/if}
<td>标题</td> <td>标题</td>
<!-- <td>点击量</td>--> <!-- <td>点击量</td>-->
<td>创建日期</td> <td>创建日期</td>
@ -89,9 +92,6 @@ use app\model\Category as VCategory;
{if $category.id == 39} {if $category.id == 39}
<td>活动预告</td> <td>活动预告</td>
{/if} {/if}
{if $category.id == 40}
<td>推荐</td>
{/if}
<td>操作</td> <td>操作</td>
</thead> </thead>
{foreach name="list" item="item"} {foreach name="list" item="item"}
@ -104,11 +104,13 @@ use app\model\Category as VCategory;
{/if} {/if}
</td> </td>
{/if} {/if}
{if $category.id!=42}
<td class="layer-photos"> <td class="layer-photos">
{if !empty($item['src_mobile']) && file_exists('.' . $item['src_mobile'])} {if !empty($item['src_mobile']) && file_exists('.' . $item['src_mobile'])}
<img src="{:CImage::getThumb($item.src_mobile, 50, 50)}" layer-src="{$item.src_mobile}" width="50" /> <img src="{:CImage::getThumb($item.src_mobile, 50, 50)}" layer-src="{$item.src_mobile}" width="50" />
{/if} {/if}
</td> </td>
{/if}
<td><a class="layui-btn layui-btn-title" data-state="edit" data-href="{:url('manager.article/edit',['id' => $item['id']])}" title="编辑">{$item.title}</a></td> <td><a class="layui-btn layui-btn-title" data-state="edit" data-href="{:url('manager.article/edit',['id' => $item['id']])}" title="编辑">{$item.title}</a></td>
<!-- <td>{$item.views}</td>--> <!-- <td>{$item.views}</td>-->
<td>{$item.create_time|date='Y-m-d'}</td> <td>{$item.create_time|date='Y-m-d'}</td>
@ -122,9 +124,6 @@ use app\model\Category as VCategory;
{if $category.id == 39} {if $category.id == 39}
<td>{$item.is_prev == 1 ? '是' : '否'}</td> <td>{$item.is_prev == 1 ? '是' : '否'}</td>
{/if} {/if}
{if $category.id == 40}
<td>{$item.recommend == 1 ? '是' : '否'}</td>
{/if}
<td> <td>
<div style="width: 340px;"> <div style="width: 340px;">
{if !empty($attributeList)} {if !empty($attributeList)}

View File

@ -3,7 +3,8 @@
use app\model\Article; use app\model\Article;
use app\model\Category; use app\model\Category;
$childrenMenu = Category::getChildrenByParentId($topCategoryId); $childrenMenu = Category::getChildrenByParentId($topCategoryId);
$items = Article::getList(Category::CATEGORY_MARKET_SERVICE, $category['number'] ?? 30, null ,['recommend']); $items = Article::getList(Category::CATEGORY_MARKET_SERVICE, $category['number'] ?? 30);
$serviceList = Article::getList(Category::CATEGORY_SERVE_LIST, 500);
{/php} {/php}
{include file="public/about_second" /} {include file="public/about_second" /}
@ -39,16 +40,13 @@ $items = Article::getList(Category::CATEGORY_MARKET_SERVICE, $category['number']
</div> </div>
<!-- 列表 --> <!-- 列表 -->
<div class="market-list flex"> <div class="market-list flex">
{if isset($blocks['market_service_list']['value']) && !empty($blocks['market_service_list']['value'])} {foreach $serviceList as $k => $service}
{php}$serviceImages = json_decode($blocks['market_service_list']['value'], true);{/php} <a href="/market/{$service.id}.html" class="market-item bg-col-f5">
{foreach $serviceImages as $k => $service} <span><img src="{$service.src}" alt="{$service.title ?? ''}"></span>
<a href="{$service.link ?: 'javascript:;'}" class="market-item bg-col-f5">
<span><img src="{$service.src}" alt="{$service.alt ?? ''}"></span>
<h2>{$service.title ?? ''}</h2> <h2>{$service.title ?? ''}</h2>
<p class="capitalize color-66 pc-show">{$service.desc ?? ''}</p> <p class="capitalize color-66 pc-show">{$service.title_en ?? ''}</p>
</a> </a>
{/foreach} {/foreach}
{/if}
</div> </div>
</div> </div>