Prechádzať zdrojové kódy

去除 模拟考试

y595705120 4 mesiacov pred
rodič
commit
ccbff1a147

+ 0 - 20
component/iView/avatar/index.js

@@ -1,20 +0,0 @@
-Component({
-    externalClasses: ['i-class'],
-
-    properties: {
-        // circle || square
-        shape: {
-            type: String,
-            value: 'circle'
-        },
-        // small || large || default
-        size: {
-            type: String,
-            value: 'default'
-        },
-        src: {
-            type: String,
-            value: ''
-        }
-    }
-});

+ 0 - 3
component/iView/avatar/index.json

@@ -1,3 +0,0 @@
-{
-  "component": true
-}

+ 0 - 4
component/iView/avatar/index.wxml

@@ -1,4 +0,0 @@
-<view class="i-class i-avatar i-avatar-{{ shape }} i-avatar-{{ size }} {{ src ? 'i-avatar-image' : '' }}">
-    <image src="{{ src }}" wx:if="{{ src !== '' }}"></image>
-    <view class="i-avatar-string" wx:else><slot></slot></view>
-</view>

+ 0 - 56
component/iView/avatar/index.wxss

@@ -1,56 +0,0 @@
-.i-avatar {
-  display: inline-block;
-  text-align: center;
-  background: #ccc;
-  color: #fff;
-  white-space: nowrap;
-  position: relative;
-  overflow: hidden;
-  vertical-align: middle;
-  width: 32px;
-  height: 32px;
-  line-height: 32px;
-  border-radius: 16px;
-  font-size: 18px
-}
-
-.i-avatar .ivu-avatar-string {
-  line-height: 32px
-}
-
-.i-avatar-large {
-  width: 40px;
-  height: 40px;
-  line-height: 40px;
-  border-radius: 20px;
-  font-size: 24px
-}
-
-.i-avatar-large .ivu-avatar-string {
-  line-height: 40px
-}
-
-.i-avatar-small {
-  width: 24px;
-  height: 24px;
-  line-height: 24px;
-  border-radius: 12px;
-  font-size: 14px
-}
-
-.i-avatar-small .ivu-avatar-string {
-  line-height: 24px
-}
-
-.i-avatar-image {
-  background: 0 0
-}
-
-.i-avatar-square {
-  border-radius: 4px
-}
-
-/* .i-avatar>image {
-  width: 100%;
-  height: 100%
-} */

+ 31 - 25
pages/exam/home/index.wxml

@@ -12,42 +12,48 @@
       </swiper-item>
     </swiper>
 </view>
-<navigator class="card-wrapper" wx:for="{{tableData}}" wx:key="index" wx:if="{{item.count>0}}"
-  url="/pages/train/orderTest/answer?groupId={{groupId}}&type={{item.type}}&count={{item.count}}">
-  <view class="i-class i-card i-card-radus p10" >
-    <view class="i-class i-card-header  ">
-      <view class="i-card-header-title" style="font-size:42rpx">
-        {{types[item.type]}} 
-      </view>
-      <view class="i-card-header-extra" style="font-size:36rpx" >
-        共计【{{item.count}}】题
+
+
+<block wx:for="{{tableData}}" wx:key="index">
+  <navigator wx:if="{{item.type<5}}" class="card-wrapper"  
+    url="/pages/train/orderTest/answer?groupId={{groupId}}&type={{item.type}}&count={{item.count}}">
+    <view class="i-class i-card i-card-radus p10" >
+      <view class="i-class i-card-header  ">
+        <view class="i-card-header-title" style="font-size:42rpx">
+          {{types[item.type]}} 
+        </view>
+        <view class="i-card-header-extra" style="font-size:36rpx" >
+          共计【{{item.count}}】题
+        </view>
       </view>
     </view>
-  </view>
-</navigator>
+  </navigator>
 
-<navigator url="/pages/exam/collection/index?groupId={{groupId}}" class="card-wrapper">
-  <view class="i-class i-card i-card-radus" data-id="{{item.id}}" data-out="{{item.isOut}}" >
-    <view class="i-class i-card-header mt10">
-      <view class="i-card-header-title tc" style="font-size:42rpx">
-        我的错题
-      </view>
-      <view class="i-card-header-extra" style="font-size:36rpx" >
-        进入
+  <navigator wx:if="{{item.type ==5}}"  class="card-wrapper"
+    url="/pages/exam/collection/index?groupId={{groupId}}" >
+    <view class="i-class i-card i-card-radus" data-id="{{item.id}}" data-out="{{item.isOut}}" >
+      <view class="i-class i-card-header mt10">
+        <view class="i-card-header-title tc" style="font-size:42rpx">
+          {{item.name}}
+        </view>
+        <view class="i-card-header-extra" style="font-size:36rpx" >
+          进入
+        </view>
       </view>
     </view>
-  </view>
-</navigator>
+  </navigator>
 
-  <navigator url="/pages/newExam/mockExam/index?id={{groupId}}" class="card-wrapper">
+  <navigator wx:if="{{item.type == 6}}"  class="card-wrapper" 
+  url="/pages/newExam/mockExam/index?id={{groupId}}">
     <view class="i-class i-card i-card-radus" data-id="{{item.id}}" data-out="{{item.isOut}}"  >
     <view class="i-class i-card-header mt10">
       <view class="i-card-header-title tc" style="font-size:42rpx">
-        模拟考试
+        {{item.name}}
       </view>
       <view class="i-card-header-extra" style="font-size:36rpx" >
-        开始
+        进入
       </view>
     </view>
   </view>
-  </navigator>
+  </navigator>
+</block>

+ 0 - 1
pages/exam/index/index.json

@@ -5,7 +5,6 @@
     "i-cell": "/component/iView/cell/index",
     "i-message": "/component/iView/message/index",
     "i-spin": "/component/iView/spin/index",
-    "i-avatar": "/component/iView/avatar/index",
     "i-icon": "/component/iView/icon/index"
   },
   "enablePullDownRefresh": true,

+ 3 - 1
pages/newExam/home/index.js

@@ -8,7 +8,9 @@ Page({
       2:'单选题',
       3:'多选题',
       4:'案例题'
-    }
+    },
+    openErr: false,
+    openExam: false
   },
   onLoad: function(options) {
     let groupId = +options.groupId||1;

+ 46 - 44
pages/newExam/home/index.wxml

@@ -1,52 +1,54 @@
-
-  <view class="mb20">
-    <swiper indicator-dots="false" autoplay="true" interval="5000" duration="1000">
-      <swiper-item>
-        <image src="/assets/carousel/1.png" class="slide-image" />
-      </swiper-item>
-      <swiper-item>
-        <image src="/assets/carousel/2.png" class="slide-image" />
-      </swiper-item>
-      <swiper-item>
-        <image src="/assets/carousel/3.png" class="slide-image" />
-      </swiper-item>
-    </swiper>
+<view class="mb20">
+  <swiper indicator-dots="false" autoplay="true" interval="5000" duration="1000">
+    <swiper-item>
+      <image src="/assets/carousel/1.png" class="slide-image" />
+    </swiper-item>
+    <swiper-item>
+      <image src="/assets/carousel/2.png" class="slide-image" />
+    </swiper-item>
+    <swiper-item>
+      <image src="/assets/carousel/3.png" class="slide-image" />
+    </swiper-item>
+  </swiper>
 </view>
-<navigator class="card-wrapper" wx:for="{{tableData}}" wx:key="index" 
-  url="/pages/train/orderTest/index?groupId={{groupId}}&type={{item.type}}&count={{item.count}}">
-  <view class="i-class i-card i-card-radus p10"  >
-    <view class="i-class i-card-header">
-      <view class="i-card-header-title fs42">
-        {{types[item.type]}} 
-      </view>
-      <view class="i-card-header-extra fs36">
-        共计【{{item.count}}】题
+
+<block wx:for="{{tableData}}" wx:key="index">
+  <navigator class="card-wrapper" wx:if="{{item.type < 5}}" url="/pages/train/orderTest/index?groupId={{groupId}}&type={{item.type}}&count={{item.count}}">
+    <view class="i-class i-card i-card-radus p10">
+      <view class="i-class i-card-header">
+        <view class="i-card-header-title fs42">
+          {{item.name}}
+        </view>
+        <view class="i-card-header-extra fs36">
+          共计【{{item.count}}】题
+        </view>
       </view>
     </view>
-  </view>
-</navigator>
-<navigator url="/pages/exam/collection/index?groupId={{groupId}}" class="card-wrapper">
-  <view class="i-class i-card i-card-radus p10">
-    <view class="i-class i-card-header">
-      <view class="i-card-header-title tc fs42">
-        我的错题
-      </view>
-      <view class="i-card-header-extra fs36" >
-        进入
+  </navigator>
+
+  <navigator wx:if="{{item.type==5}}" class="card-wrapper" url="/pages/exam/collection/index?groupId={{groupId}}">
+    <view class="i-class i-card i-card-radus p10">
+      <view class="i-class i-card-header">
+        <view class="i-card-header-title tc fs42">
+          {{item.name}}
+        </view>
+        <view class="i-card-header-extra fs36">
+          进入
+        </view>
       </view>
     </view>
-  </view>
-</navigator>
+  </navigator>
 
-  <navigator url="/pages/newExam/mockExam/index?id={{groupId}}" class="card-wrapper">
-    <view class="i-class i-card i-card-radus p10" >
-    <view class="i-class i-card-header">
-      <view class="i-card-header-title tc fs42">
-        模拟考试
-      </view>
-      <view class="i-card-header-extra fs36" style="font-size:40rpx" >
-        开始
+  <navigator wx:if="{{item.type==5}}" class="card-wrapper" url="/pages/newExam/mockExam/index?id={{groupId}}">
+    <view class="i-class i-card i-card-radus p10">
+      <view class="i-class i-card-header">
+        <view class="i-card-header-title tc fs42">
+          {{item.name}}
+        </view>
+        <view class="i-card-header-extra fs36" style="font-size:40rpx">
+          进入
+        </view>
       </view>
     </view>
-  </view>
-  </navigator>
+  </navigator>
+</block>

+ 1 - 2
pages/train/index/index.json

@@ -5,8 +5,7 @@
     "i-cell": "/component/iView/cell/index",
     "i-message": "/component/iView/message/index",
     "i-spin": "/component/iView/spin/index",
-    "i-icon": "/component/iView/icon/index",
-    "i-card": "/component/iView/card/index"
+    "i-icon": "/component/iView/icon/index"
   },
   "enablePullDownRefresh": true,
   "navigationBarTitleText": "鸿锵在线教育-岗前培训"

+ 45 - 44
pages/train/limitHome/index.wxml

@@ -1,53 +1,54 @@
-
-  <view class="mb20">
-    <swiper indicator-dots="false" autoplay="true" interval="5000" duration="1000">
-      <swiper-item>
-        <image src="/assets/carousel/1.png" class="slide-image" />
-      </swiper-item>
-      <swiper-item>
-        <image src="/assets/carousel/2.png" class="slide-image" />
-      </swiper-item>
-      <swiper-item>
-        <image src="/assets/carousel/3.png" class="slide-image" />
-      </swiper-item>
-    </swiper>
+<view class="mb20">
+  <swiper indicator-dots="false" autoplay="true" interval="5000" duration="1000">
+    <swiper-item>
+      <image src="/assets/carousel/1.png" class="slide-image" />
+    </swiper-item>
+    <swiper-item>
+      <image src="/assets/carousel/2.png" class="slide-image" />
+    </swiper-item>
+    <swiper-item>
+      <image src="/assets/carousel/3.png" class="slide-image" />
+    </swiper-item>
+  </swiper>
 </view>
-<navigator class="card-wrapper" wx:for="{{tableData}}" wx:key="index" wx:if="{{item.count>0}}"
-  url="/pages/train/orderTest/answer?groupId={{groupId}}&type={{item.type}}&count={{item.count}}">
-  <view class="i-class i-card i-card-radus p10" >
-    <view class="i-class i-card-header  ">
-      <view class="i-card-header-title" style="font-size:42rpx">
-        {{types[item.type]}} 
-      </view>
-      <view class="i-card-header-extra" style="font-size:36rpx" >
-        共计【{{item.count}}】题
+
+<block wx:for="{{tableData}}" wx:key="index">
+  <navigator wx:if="{{item.type<5}}" class="card-wrapper" url="/pages/train/orderTest/answer?groupId={{groupId}}&type={{item.type}}&count={{item.count}}">
+    <view class="i-class i-card i-card-radus p10">
+      <view class="i-class i-card-header  ">
+        <view class="i-card-header-title" style="font-size:42rpx">
+          {{types[item.type]}}
+        </view>
+        <view class="i-card-header-extra" style="font-size:36rpx">
+          共计【{{item.count}}】题
+        </view>
       </view>
     </view>
-  </view>
-</navigator>
+  </navigator>
 
-<navigator url="/pages/exam/collection/index?groupId={{groupId}}" class="card-wrapper">
-  <view class="i-class i-card i-card-radus" data-id="{{item.id}}" data-out="{{item.isOut}}"  bindtap="gotoDetail" >
-    <view class="i-class i-card-header mt10">
-      <view class="i-card-header-title tc" style="font-size:42rpx">
-        我的错题
-      </view>
-      <view class="i-card-header-extra" style="font-size:36rpx" >
-        进入
+  <navigator wx:if="{{item.type ==5}}" class="card-wrapper" url="/pages/exam/collection/index?groupId={{groupId}}">
+    <view class="i-class i-card i-card-radus" data-id="{{item.id}}" data-out="{{item.isOut}}">
+      <view class="i-class i-card-header mt10">
+        <view class="i-card-header-title tc" style="font-size:42rpx">
+          {{item.name}}
+        </view>
+        <view class="i-card-header-extra" style="font-size:36rpx">
+          进入
+        </view>
       </view>
     </view>
-  </view>
-</navigator>
+  </navigator>
 
-  <navigator url="/pages/newExam/mockExam/index?id={{groupId}}" class="card-wrapper">
-    <view class="i-class i-card i-card-radus" data-id="{{item.id}}" data-out="{{item.isOut}}"  bindtap="gotoDetail" >
-    <view class="i-class i-card-header mt10">
-      <view class="i-card-header-title tc" style="font-size:42rpx">
-        模拟考试
-      </view>
-      <view class="i-card-header-extra" style="font-size:36rpx" >
-        开始
+  <navigator wx:if="{{item.type == 6}}" class="card-wrapper" url="/pages/newExam/mockExam/index?id={{groupId}}">
+    <view class="i-class i-card i-card-radus" data-id="{{item.id}}" data-out="{{item.isOut}}">
+      <view class="i-class i-card-header mt10">
+        <view class="i-card-header-title tc" style="font-size:42rpx">
+          {{item.name}}
+        </view>
+        <view class="i-card-header-extra" style="font-size:36rpx">
+          进入
+        </view>
       </view>
     </view>
-  </view>
-  </navigator>
+  </navigator>
+</block>