闫增涛
2024-04-11 0bbc91dbf3a58da857ef098b34f9d2f86361c766
packageBookService/pages/bookServices/detail/components/testResource/testResource.wxml
@@ -14,24 +14,38 @@
            <image
              src="{{ radioItem == 'test' ? '/static/images/bookService/detail/practice-icon.png' : '/static/images/bookService/detail/notest.png'}}"
            ></image>
            <text style="color: {{radioItem == 'test' ? '#fff':''}};"
            <text style="color: {{radioItem == 'test' ? '#fff':'#ff6c00'}};"
              >练习</text
            >
          </view>
        </t-radio>
      </view>
      <!-- 断开 -->
      <view class="card {{radioItem == 'mock' ? 'card--active' : ''}}">
        <t-radio value="mock" icon="none" borderless style="height: 74rpx">
        <t-radio value="mock" icon="none" borderless style="height: 80rpx">
          <view class="radio-content" slot="content">
            <image
              src="{{ radioItem == 'mock' ? '/static/images/bookService/detail/checkpaper.png' : '/static/images/bookService/detail/zujuan.png'}}"
            ></image>
            <text style="color: {{radioItem == 'mock' ? '#fff':''}};"
            <text style="color: {{radioItem == 'mock' ? '#fff':'#ff6c00'}};"
              >组卷</text
            >
          </view>
        </t-radio>
      </view>
      <!-- 断开 -->
      <!-- <view class="card {{radioItem == 'mock' ? 'card--active' : ''}}">
        <t-radio value="mock" icon="none" borderless style="height: 80rpx">
          <view class="radio-content" slot="content">
            <image
              src="{{ radioItem == 'mock' ? '/static/images/bookService/detail/checkpaper.png' : '/static/images/bookService/detail/zujuan.png'}}"
            ></image>
            <text style="color: {{radioItem == 'mock' ? '#fff':'#ff6c00'}};"
              >组卷</text
            >
          </view>
        </t-radio>
      </view> -->
    </t-radio-group>
    <t-button
      class="error-btn"
@@ -41,9 +55,9 @@
      bind:tap="goMycollect"
      data-answerType="errorQuestion"
    >
      <view slot="content">
      <view slot="content" class="btn-content">
        <image src="/static/images/bookService/detail/cuoti.png"></image>
        我的错题
        <text class="primary-color">我的错题</text>
      </view>
    </t-button>
    <t-button
@@ -54,9 +68,9 @@
      bind:tap="goMycollect"
      data-answerType="collectQuestion"
    >
      <view slot="content">
      <view slot="content" class="btn-content">
        <image src="/static/images/bookService/detail/wodeshoucang.png"></image>
        我的收藏
        <text class="primary-color"> 我的收藏</text>
      </view>
    </t-button>
  </view>
@@ -66,22 +80,35 @@
    wx:for="{{list}}"
    wx:key="id"
    wx:if="{{radioItem == 'test'}}"
    bind:tap="goTest"
    data-value="{{item}}"
  >
    <view class="list-title">
      <image src="/static/images/bookService/detail/test-icon.png"></image>
      <text>{{item.name}}</text>
    </view>
    <view class="practice" bind:tap="goTest" data-value="{{item}}">
    <view class="practice">
      <image src="/static/images/bookService/detail/lianxi-icon.png"></image>
    </view>
  </view>
</view>
<view
  wx:if="{{noResources}}"
  class="noData"
  wx:if="{{radioItem == 'test' && !list.length}}"
>
  <t-empty icon="folder-open" description="暂无数据" />
</view>
<!-- 组卷列表 -->
<view class="mock-data" wx:if="{{radioItem == 'mock'}}">
  <view wx:if="{{mockData.mockList.length}}">
    <view class="mack-num">已组卷{{mockData.mockList.length}}次</view>
    <view class="mock-list">
  <view>
    <view class="mack-num" wx:if="{{mockData.mockList.length}}">
      <text>已组卷{{mockData.mockList.length}}次</text>
      <t-button class="buy-mock-btn" bind:tap="buyMock">购买组卷</t-button>
    </view>
    <view class="mock-list" wx:if="{{mockData.mockList.length}}">
      <view
        class="mock-list-box"
        wx:for="{{mockData.mockList}}"
@@ -111,16 +138,20 @@
        </view>
      </view>
    </view>
    <view wx:else class="not-mock">
      <image
        src="/static/images/bookService/examination/zhuangtai-icon.png"
      ></image>
      <view class="not-mock-message note-mock-text"
        >组卷是收费功能,请购买后使用!</view
      >
      <view class="note-mock-price note-mock-text"
        >价格:<text class="mock-price">¥{{mockData.price}}</text> 元/次</view
      >
      <t-button class="buy-mock-btn" bind:tap="buyMock">购买组卷</t-button>
    </view>
  </view>
  <view wx:else class="not-mock">
    <image
      src="/static/images/bookService/examination/zhuangtai-icon.png"
    ></image>
    <view class="not-mock-message note-mock-text"
      >组卷是收费功能,请购买后使用!</view
    >
    <view class="note-mock-price note-mock-text"
      >价格:<text class="mock-price">¥{{mockData.price}}</text> 元/次</view
    >
  <view class="loading-box" wx:if="{{}}">
    <t-loading loading="{{}}" />
  </view>
</view>