feat: nas产品体验页
This commit is contained in:
@@ -54,11 +54,17 @@ if (!function_exists('style')) {
|
|||||||
if (is_array($styles)) {
|
if (is_array($styles)) {
|
||||||
$key = array_keys($styles);
|
$key = array_keys($styles);
|
||||||
foreach ($key as $v) {
|
foreach ($key as $v) {
|
||||||
|
if (empty($styles[$v])){
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$css .= $v . ':' . $styles[$v] . ';';
|
$css .= $v . ':' . $styles[$v] . ';';
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$css = $styles;
|
$css = $styles;
|
||||||
}
|
}
|
||||||
|
if ($css == '') {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
return 'style="' . $css . '"';
|
return 'style="' . $css . '"';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -96,6 +96,34 @@ class TopicNas extends Common
|
|||||||
*/
|
*/
|
||||||
public function product()
|
public function product()
|
||||||
{
|
{
|
||||||
|
$focus_image = [];
|
||||||
|
$step = [];
|
||||||
|
$trial_instructions = [];
|
||||||
|
// 获取banner数据
|
||||||
|
$banners = SysBannerModel::with(['items' => function($query) {
|
||||||
|
$query->withoutField(['sort', 'created_at', 'updated_at', 'deleted_at']);
|
||||||
|
}])
|
||||||
|
->uniqueLabel([
|
||||||
|
'BANNER_68103aaebe4c4',
|
||||||
|
'BANNER_68103acd1a8b9',
|
||||||
|
'BANNER_68103daed6623'
|
||||||
|
])
|
||||||
|
->language($this->lang_id)
|
||||||
|
->enabled(true)
|
||||||
|
->select();
|
||||||
|
if (!$banners->isEmpty()) {
|
||||||
|
$banners_map = [];
|
||||||
|
foreach ($banners as $banner) {
|
||||||
|
$banners_map[$banner->unique_label] = $banner;
|
||||||
|
}
|
||||||
|
$focus_image = data_get($banners_map, 'BANNER_68103aaebe4c4')?->items->first()?->toArray();
|
||||||
|
$step = data_get($banners_map, 'BANNER_68103acd1a8b9')?->items->toArray();
|
||||||
|
$trial_instructions = data_get($banners_map, 'BANNER_68103daed6623')?->items->toArray();
|
||||||
|
}
|
||||||
|
View::assign('focus_image', $focus_image);
|
||||||
|
View::assign('step', $step);
|
||||||
|
View::assign('trial_instructions', $trial_instructions);
|
||||||
|
|
||||||
return View::fetch('product');
|
return View::fetch('product');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
56
app/index/view/topic_nas/product.html
Normal file
56
app/index/view/topic_nas/product.html
Normal file
@@ -0,0 +1,56 @@
|
|||||||
|
{extend name="public/nas_base" /}
|
||||||
|
{block name="style"}
|
||||||
|
<link rel="stylesheet" type="text/css" href="__CSS__/topic_nas_product.css" />
|
||||||
|
{/block}
|
||||||
|
{block name="main"}
|
||||||
|
<div class="orico_Page_index">
|
||||||
|
<!-- 产品体验 -->
|
||||||
|
<div class="narsZTPC">
|
||||||
|
<!-- 软件体验 -->
|
||||||
|
<div class="nZTtopCtMian narssbshow">
|
||||||
|
{notempty name="focus_image"}
|
||||||
|
<a {notempty name="focus_image.link"}href="{$focus_image.link}"{/notempty}>
|
||||||
|
<img src="{$focus_image.image}" class="narsZCimg" />
|
||||||
|
</a>
|
||||||
|
{/notempty}
|
||||||
|
{notempty name="step"}
|
||||||
|
<div class="narsZTicos">
|
||||||
|
{volist name="step" id="st"}
|
||||||
|
<div class="nztit">
|
||||||
|
<img src="{$st.image}" class="narsicimg" />
|
||||||
|
<span class="narsstep">{$st.title}</span>
|
||||||
|
<span class="narszttext">{$st.desc|raw}</span>
|
||||||
|
</div>
|
||||||
|
{/volist}
|
||||||
|
</div>
|
||||||
|
{/notempty}
|
||||||
|
{notempty name="trial_instructions"}
|
||||||
|
<div class="narsZTinfo">
|
||||||
|
<div class="nztif-left">
|
||||||
|
{volist name="trial_instructions" id="trial" offset="0" length="2"}
|
||||||
|
<div class="narsztewmit">
|
||||||
|
<a {notempty name="trial.link"}href="{$trial.link}" target="_blank"{/notempty}>
|
||||||
|
<img src="{$trial.image}" class="nztewmimg" />
|
||||||
|
</a>
|
||||||
|
<p>{$trial.title}</p>
|
||||||
|
<span>{$trial.desc|raw}</span>
|
||||||
|
</div>
|
||||||
|
{/volist}
|
||||||
|
</div>
|
||||||
|
<div class="nztif-right">
|
||||||
|
<span class="sysmtxt">{$trial_instructions.2.title}</span>
|
||||||
|
<div class="sminfo">{$trial_instructions.2.desc|raw}</div>
|
||||||
|
<div class="nztbzyj">
|
||||||
|
{volist name="trial_instructions" id="trial" offset="3"}
|
||||||
|
<a {notempty name="trial.link"}href="{$trial.link}" target="_blank"{/notempty}>
|
||||||
|
<span {:style(["color"=>$trial.title_txt_color])}>{$trial.title}</span>
|
||||||
|
</a>
|
||||||
|
{/volist}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{/notempty}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{/block}
|
||||||
171
public/static/index/css/topic_nas_product.css
Executable file
171
public/static/index/css/topic_nas_product.css
Executable file
@@ -0,0 +1,171 @@
|
|||||||
|
.narsZTPC {
|
||||||
|
width: 100%;
|
||||||
|
height: auto;
|
||||||
|
position: relative;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
overflow-y: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTabs {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
justify-content: center;
|
||||||
|
margin: 2.5rem auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTabs .nZTabIt {
|
||||||
|
color: #001717;
|
||||||
|
font-size: 18px;
|
||||||
|
height: 3.25rem;
|
||||||
|
line-height: 3.25rem;
|
||||||
|
padding: 0 3.125rem;
|
||||||
|
background: #fff;
|
||||||
|
text-align: center;
|
||||||
|
border-radius: 28px;
|
||||||
|
cursor: pointer;
|
||||||
|
border: 1px solid #001717;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTabs .nZTabIt:first-child {
|
||||||
|
margin-right: 6.25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTabs .nZTabIt_active {
|
||||||
|
border: 1px solid #004CFA;
|
||||||
|
color: #fff;
|
||||||
|
background: #004CFA;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTtopCtMian {
|
||||||
|
width: 100%;
|
||||||
|
margin: 0 auto;
|
||||||
|
height: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTtopCtMian .narsZCimg {
|
||||||
|
width: 100%;
|
||||||
|
height: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTtopCtMian .narsZTicos {
|
||||||
|
width: 65%;
|
||||||
|
margin: 0 auto;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
justify-content: space-between;
|
||||||
|
padding: 100px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTtopCtMian .narsZTicos .nztit {
|
||||||
|
width: 25%;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTtopCtMian .narsZTicos .nztit .narsicimg {
|
||||||
|
width: 57px;
|
||||||
|
height: 57px;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTtopCtMian .narsZTicos .nztit .narsstep {
|
||||||
|
color: #685557;
|
||||||
|
padding: 0.625rem 0;
|
||||||
|
font-size: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narsZTPC .nZTtopCtMian .narsZTicos .nztit .narszttext {
|
||||||
|
color: #2D2C2C;
|
||||||
|
font-size: 18px;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.narswljshow {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nZTtopCtMian .narsZTinfo {
|
||||||
|
width: 65%;
|
||||||
|
background: #F5F5F7;
|
||||||
|
border-radius: 8px;
|
||||||
|
padding: 75px 90px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: flex-start;
|
||||||
|
margin: 0 auto;
|
||||||
|
margin-bottom: 100px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nZTtopCtMian .narsZTinfo .nztif-left {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nZTtopCtMian .narsZTinfo .nztif-left .narsztewmit {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: center;
|
||||||
|
text-align: center;
|
||||||
|
margin-right: 50px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nZTtopCtMian .narsZTinfo .nztif-left .narsztewmit .nztewmimg {
|
||||||
|
width: 150px;
|
||||||
|
height: 150px;
|
||||||
|
margin-bottom: 1.25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nZTtopCtMian .narsZTinfo .nztif-left .narsztewmit p {
|
||||||
|
font-weight: bold;
|
||||||
|
font-size: 18px;
|
||||||
|
color: F5F5F7;
|
||||||
|
padding-bottom: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nZTtopCtMian .narsZTinfo .nztif-left .narsztewmit span {
|
||||||
|
font-size: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nZTtopCtMian .narsZTinfo .nztif-right {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nZTtopCtMian .narsZTinfo .nztif-right .sysmtxt {
|
||||||
|
font-size: 18px;
|
||||||
|
color: #001717;
|
||||||
|
padding-bottom: 1.25rem;
|
||||||
|
font-weight: 700;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nZTtopCtMian .narsZTinfo .nztif-right .sminfo {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
font-size: 18px;
|
||||||
|
color: #001717;
|
||||||
|
padding-bottom: 40px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nZTtopCtMian .narsZTinfo .nztif-right .sminfo span {
|
||||||
|
padding-bottom: 0.9rem;
|
||||||
|
font-size: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nztbzyj {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nztbzyj a {
|
||||||
|
font-size: 1rem;
|
||||||
|
color: #2D2C2C;
|
||||||
|
padding-bottom: 2px;
|
||||||
|
border-bottom: 1px solid #CBCBCD;
|
||||||
|
margin-right: 4.5rem;
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user