riku
2022-08-26 9f78f3f014a3423ea3fcab8f9f1056c57cd47fc8
pages/module_consult/consulthome/consulthome.wxml
@@ -1,57 +1,103 @@
<!--pages/module_consult/consulthome/consulthome.wxml-->
<view class="page">
  <view class="page__hd">
    <view class="search-bar" bindtap="search">
    <view class="search-bar" bindtap="gotoSearch">
      <mp-icon icon="search" size="15" color="black"></mp-icon>
      <text>{{searchTips}}</text>
    </view>
  </view>
  <view class="page__bd">
    <view class="flex-h">
      <view class="card">
        <image src="/res/icons/con_pro_bg.png" class="card-bg" mode="scaleToFill"/>
        <view class="card-title">常见问题</view>
        <view class="card-abstract">常见企业环保问题</view>
      <view class="card" bindtap="goto" data-index="0">
        <image src="/res/icons/con_pro_bg.png" class="card-bg" mode="scaleToFill" />
        <view class="card-title">环保问题</view>
        <view class="card-abstract">常见企业问题</view>
        <image src="/res/icons/con_pro.png" mode="aspectFit" class="icon"></image>
      </view>
      <view class="divider"></view>
      <view class="card middle">
        <image src="/res/icons/con_lib_bg.png" class="card-bg" mode="scaleToFill"/>
      <view class="card middle" bindtap="goto" data-index="1">
        <image src="/res/icons/con_lib_bg.png" class="card-bg" mode="scaleToFill" />
        <view class="card-title">环保知识库</view>
        <view class="card-abstract">环保法律法规</view>
        <view class="card-abstract">生态环境法律法规</view>
        <image src="/res/icons/con_lib.png" mode="aspectFit" class="icon"></image>
      </view>
      <view class="divider"></view>
      <view class="card">
        <image src="/res/icons/con_qa_bg.png" class="card-bg" mode="scaleToFill"/>
      <view class="card" bindtap="goto" data-index="2">
        <image src="/res/icons/con_qa_bg.png" class="card-bg" mode="scaleToFill" />
        <view class="card-title">智能咨询</view>
        <view class="card-abstract">环保专家 在线咨询</view>
        <view class="card-abstract">环保智能助手</view>
        <image src="/res/icons/con_qa.png" mode="aspectFit" class="icon"></image>
      </view>
    </view>
    <view class="fyui-cell fyui-cell_select">
      <view class="fyui-cell__bd">热门</view>
      <view class="fyui-cell__ft">更多</view>
    </view>
    <view wx:for="{{hotTopics}}" wx:key="index">
      <view class="fyui-box  fyui-box__text">
        <view class="fyui-box__hd">
          <text class="" wx:for="{{item.tags}}" wx:key="i" data-index="i" wx:for-item="tag">{{tag}}</text>
          {{item.title}}
        </view>
        <view class="fyui-box__bd">
          <view class="fyui-box__content">{{item.abstract}}</view>
        </view>
        <view class="fyui-box__ft">
          <view>{{item.time}}</view>
          <view>{{item.author}}</view>
    <switch-tab tabList="{{tabList}}" pageList="{{pageList}}">
      <view slot="slot{{i1}}" wx:for="{{pageList}}" wx:for-item="page" wx:key="i1" wx:for-index="i1">
        <block wx:if="{{page.length > 0}}">
          <block wx:if="{{i1 == 0 || i1 == 1}}">
            <view wx:for="{{page}}" wx:key="i2" wx:for-index="i2" data-index="{{i1}},{{i2}}" bindtap="gotoFile">
              <view class="fyui-box  fyui-box__text">
                <view class="fyui-box__hd">
                  {{item.mfName}}
                </view>
                <view class="fyui-box__bd">
                  <view class="fyui-box__content tag">
                    <view>文件类别:{{item.mfFileType}}</view>
                    <view>生效时间:{{item.mfEffectiveDate}}</view>
                    <view>文号:{{item.mfReferenceNumber}}</view>
                    <view>相关行业 -> {{item.mfFileIndustry}}</view>
                  </view>
                  <view class="fyui-box__content des">{{item.mfSummary}}</view>
                </view>
                <view class="fyui-box__ft">
                  <text class="keyword">关键词:</text>
                  <view class="keyword-item">
                    <text wx:for="{{item.mfKeywordLv1}}" wx:for-index="i" wx:for-item="word" wx:key="i">{{word}}</text>
                  </view>
                </view>
              </view>
            </view>
          </block>
          <block wx:else="{{i1 == 2}}">
            <view wx:for="{{page}}" wx:key="i2" wx:for-index="i2" data-index="{{i1}},{{i2}}" bindtap="gotoItem">
              <view class="fyui-box  fyui-box__text">
                <view class="fyui-box__hd">
                  <rich-text nodes="{{item.miItemContent}}" class="fyui-box__content des subtitle"></rich-text>
                </view>
                <view class="fyui-box__bd">
                  <!-- <view class="fyui-box__content tag">相关行业 -> {{item.fileIndustry}}</view> -->
                  <text class="tag2">所属章节:{{item.miChapterName}} {{item.miItemName ? ' ' + item.miItemName : ''}}</text>
                  <text class="tag2">所属文件:《{{item.mfName}}》</text>
                  <text class="tag2" wx:if="{{item.miReferenceNumber}}">所属文号:{{item.miReferenceNumber}}</text>
                </view>
                <view class="fyui-box__ft">
                  <!-- <text class="tag3 {{item.effective? '' : 'tag3_disable'}}">{{item.effective ? '生效中':'已失效' }}</text>
                  <text class="tag3 {{item.relatedItems? '' : 'tag3_disable'}}">{{item.relatedItems ? '关联条目' + item.relatedItems + '个 >':'无关联条目' }}</text>
                  <text class="tag3 {{item.relatedCases? '' : 'tag3_disable'}}">{{item.relatedCases ? '关联案例' + item.relatedCases + '个 >':'无关联案例' }}</text> -->
                  <!-- <text class="keyword">关键词:</text>
                <view class="keyword-item"><text wx:for="{{item.keywords}}" wx:for-index="i" wx:for-item="word" wx:key="i">{{word}}</text></view> -->
                </view>
              </view>
            </view>
          </block>
        </block>
        <view wx:else class="page__ft">
          <mp-loading duration="{{900}}" type="dot-gray" show="{{true}}" animated="{{true}}"></mp-loading>
        </view>
      </view>
    </view>
    </switch-tab>
    <!-- <view class="fyui-cell fyui-cell_select">
      <view class="fyui-cell__bd">热门</view>
      <view class="fyui-cell__ft">更多</view>
    </view> -->
  </view>
  <view class="page__ft">
  </view>
</view>