实现分类页
修改json文件并且引入搜索框
{
"usingComponents": {
"search-input":"../../components/SearchInput/SearchInput"
},
"navigationBarTitleText": "分类"
}
界面编写
主要用到了scroll-view
<view class="cates">
<!-- 首页搜索框 -->
<search-input></search-input>
<view class="cates_container">
<!-- 左侧 -->
<scroll-view scroll-y class="left_menu">
<view class="menu_item {
{index == curr ? 'active':''}}" wx:for="{
{leftcategoryList}}" wx:key="*this" bindtap="getgoods" data-index="{
{index}}">
{
{item}}
</view>
</scroll-view>
<!-- 右侧 -->
<scroll-view scroll-y class="right_menu">
<