xjc il y a 9 mois
Parent
commit
8515cdb15f
4 fichiers modifiés avec 11 ajouts et 7 suppressions
  1. 1 1
      pages/apply/apply.wxml
  2. 1 1
      pages/plan/plan.wxml
  3. 8 4
      pages/post/post.js
  4. 1 1
      pages/post/post.wxml

+ 1 - 1
pages/apply/apply.wxml

@@ -57,7 +57,7 @@
 </block>
 <view class="nope" wx:if="{{list.length==0}}">暂无报名信息...</view>
 
-    <navigator url="../onlinePost/onlinePost" class="post">立即报名</navigator>
+    <navigator url="../onlinePost/onlinePost" class="post">立即报名22</navigator>
 </view>
 
 <view class="login" wx:if='{{show}}'>

+ 1 - 1
pages/plan/plan.wxml

@@ -47,7 +47,7 @@
       <view class="list kc" wx:for="{{item.classes}}" wx:for-item="class" wx:key="*this">
           <text class="name" decode="{{true}}">{{class.name}}</text>
           <text decode="{{true}}">计划100人/已报名{{class.signuped_count}}</text>
-          <navigator url="../post/post?class_id={{class.id}}&price={{class.price_new}}_{{class.price_re}}_{{class.price_change}}&&type=3"  class="apply">立即报名</navigator>
+          <navigator url="../post/post?class_id={{class.id}}&price={{class.price_new}}_{{class.price_re}}_{{class.price_change}}&&type=3"  class="apply">立即报名11</navigator>
       </view>
   </view>
 </view>

+ 8 - 4
pages/post/post.js

@@ -31,7 +31,9 @@ Page({
     type:0,
     device_cats:[],
     dev:[],
-    show_dev:false
+    show_dev:false,
+    subject_item0:"",
+    selectClass:false
   },
 
   /**
@@ -39,7 +41,9 @@ Page({
    */
   onLoad: function (options) {
     this.setData({
-      type: options.type
+      type: options.type,
+      subject_item0:options.s_name,
+      selectClass:options.s_name.indexOf("特种")!=-1?false:true
     })
     var sub_list=[],user={}
     //获取用户信息
@@ -347,7 +351,7 @@ Page({
       }
       // console.log(this.data.class_)
       // console.log(this.data.z_type)
-      if (this.data.classList.length > 0 && this.data.class_<0) {
+      if (this.data.classList.length > 0 && this.data.class_<0 && this.selectClass) {
         wx.showToast({
           title: '请选择班级',
           icon: 'none',
@@ -357,7 +361,7 @@ Page({
       }
       formData.subject_item = data.z_type + "|" + data.categoryArray[data.category].name + "|" + data.subjectArray[data.subject].name
       formData.subject_id = data.subjectArray[data.subject].id 
-      if (this.data.classList.length > 0){
+      if (this.data.classList.length > 0 && this.selectClass){
         formData.class_id = data.classList[data.class_].id
       }else{
         formData.class_id = 0

+ 1 - 1
pages/post/post.wxml

@@ -80,7 +80,7 @@
       <image src="../../images/arrow-bottom.png" mode="widthFix"></image>
       <view wx:if="{{train>=0}}" class="intro">{{trainArray[train].intro}}</view>
   </view>
-  <view class="item" wx:if="{{classList.length>0}}">
+  <view class="item" wx:if="{{classList.length>0 && selectClass}}">
       <label>班级</label>
       <picker  data-name='class_'  bindchange="pickerChange" value="{{class_}}" range="{{classList}}" range-key="name">
         <view class="picker">