|  | @@ -4,6 +4,7 @@
 | 
	
		
			
				|  |  |        :headerBg="headerBg"
 | 
	
		
			
				|  |  |        :headerBorder="headerBorder"
 | 
	
		
			
				|  |  |        :userBg="userBg"
 | 
	
		
			
				|  |  | +      :LoginNavIndex="0"
 | 
	
		
			
				|  |  |      />
 | 
	
		
			
				|  |  |      <div class="navBar" v-if="info">
 | 
	
		
			
				|  |  |          <div class="navBar-left">
 | 
	
	
		
			
				|  | @@ -166,17 +167,17 @@
 | 
	
		
			
				|  |  |                              </el-tooltip>
 | 
	
		
			
				|  |  |                          </div>
 | 
	
		
			
				|  |  |                      </div>
 | 
	
		
			
				|  |  | -                    <div class="info-item order-item">
 | 
	
		
			
				|  |  | +                    <div class="info-item order-item" v-if="settlement">
 | 
	
		
			
				|  |  |                          <label>结算价格</label>
 | 
	
		
			
				|  |  |                          <div class="order-content">
 | 
	
		
			
				|  |  | -                            <span class="OPPOSans">¥{{info.price_reservation|cutMoneyFiter}}</span>
 | 
	
		
			
				|  |  | -                            <span class="old-price" v-if="info.price&&info.price_reservation!==info.price">¥{{info.price|cutMoneyFiter}}</span>
 | 
	
		
			
				|  |  | +                            <span class="OPPOSans">¥{{settlement.price_settlement|cutMoneyFiter}}</span>
 | 
	
		
			
				|  |  | +                            <span class="old-price" v-if="settlement.price&&settlement.price_settlement!==settlement.price">¥{{settlement.price|cutMoneyFiter}}</span>
 | 
	
		
			
				|  |  |                          </div>
 | 
	
		
			
				|  |  |                      </div>
 | 
	
		
			
				|  |  |                  </div>
 | 
	
		
			
				|  |  |                  <div class="btn-box">
 | 
	
		
			
				|  |  | -                    <a class="el-button" @click="handleChangeWay('wei')">立即购买</a>
 | 
	
		
			
				|  |  | -                    <a class="upgrade" @click="handleChangeWay('dui')">使用兑换码</a>
 | 
	
		
			
				|  |  | +                    <el-button class="el-button" @click="handleChangeWay('wei')" :loading="createOrderLoading">立即购买</el-button>
 | 
	
		
			
				|  |  | +                    <el-button class="upgrade" @click="handleChangeWay('dui')">使用兑换码</el-button>
 | 
	
		
			
				|  |  |                  </div>
 | 
	
		
			
				|  |  |              </div>
 | 
	
		
			
				|  |  |          </div>
 | 
	
	
		
			
				|  | @@ -438,7 +439,9 @@ export default {
 | 
	
		
			
				|  |  |                  study_phase: 23,
 | 
	
		
			
				|  |  |                  study_phase_name: '初三版'
 | 
	
		
			
				|  |  |              },
 | 
	
		
			
				|  |  | -        ]
 | 
	
		
			
				|  |  | +        ],
 | 
	
		
			
				|  |  | +        settlement: null, // 结算价格
 | 
	
		
			
				|  |  | +        createOrderLoading: false
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |    },
 | 
	
		
			
				|  |  |    //计算属性 类似于data概念
 | 
	
	
		
			
				|  | @@ -473,18 +476,6 @@ export default {
 | 
	
		
			
				|  |  |      getInfo(){
 | 
	
		
			
				|  |  |          this.loading = true
 | 
	
		
			
				|  |  |          let MethodName = "/ShopServer/Client/ReservationQuery/GetReservationInfo_Issue";
 | 
	
		
			
				|  |  | -        // let customStr = 'false'
 | 
	
		
			
				|  |  | -        // if(this.orderTotalNumber===-1){
 | 
	
		
			
				|  |  | -        //     if(this.customOrderNumberList.length>0){
 | 
	
		
			
				|  |  | -        //         customStr = ''
 | 
	
		
			
				|  |  | -        //         this.customOrderNumberList.forEach(item => {
 | 
	
		
			
				|  |  | -        //             customStr += item.issue_no + ','
 | 
	
		
			
				|  |  | -        //         });
 | 
	
		
			
				|  |  | -        //         customStr = customStr.substring(0,customStr.length-1)
 | 
	
		
			
				|  |  | -        //     }else{
 | 
	
		
			
				|  |  | -        //         // return
 | 
	
		
			
				|  |  | -        //     }
 | 
	
		
			
				|  |  | -        // }
 | 
	
		
			
				|  |  |          let data = {
 | 
	
		
			
				|  |  |              study_phase: this.studyType,
 | 
	
		
			
				|  |  |              period_count: this.orderTotalNumber!==-1?this.orderTotalNumber:this.customOrderNumberList.length,
 | 
	
	
		
			
				|  | @@ -529,6 +520,28 @@ export default {
 | 
	
		
			
				|  |  |          .catch(() => {
 | 
	
		
			
				|  |  |              this.loading = false
 | 
	
		
			
				|  |  |          }); 
 | 
	
		
			
				|  |  | +        this.handleOrderPrice()
 | 
	
		
			
				|  |  | +    },
 | 
	
		
			
				|  |  | +    // 计算结算价格
 | 
	
		
			
				|  |  | +    handleOrderPrice(){
 | 
	
		
			
				|  |  | +        this.loading = true
 | 
	
		
			
				|  |  | +        let MethodName = '/ShopServer/Client/ReservationQuery/ComputeReservationSettlementPrice_Issue'
 | 
	
		
			
				|  |  | +        let data = {
 | 
	
		
			
				|  |  | +            goods_study_phase: this.studyType,
 | 
	
		
			
				|  |  | +            period_count: this.orderTotalNumber!==-1?this.orderTotalNumber:this.customOrderNumberList.length,
 | 
	
		
			
				|  |  | +            is_custom_select_issue_no: this.orderTotalNumber!==-1?'false':'true',
 | 
	
		
			
				|  |  | +            issue_no_list:this.customOrderNumberList
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +        getLogin(MethodName, data)
 | 
	
		
			
				|  |  | +        .then((res) => {
 | 
	
		
			
				|  |  | +            this.loading = false
 | 
	
		
			
				|  |  | +            if(res.status===1){
 | 
	
		
			
				|  |  | +                this.settlement = res
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  | +        })
 | 
	
		
			
				|  |  | +        .catch(() => {
 | 
	
		
			
				|  |  | +            this.loading = false
 | 
	
		
			
				|  |  | +        }); 
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  |      changeCustomOrder(item){
 | 
	
		
			
				|  |  |          if(this.customOrderNumberList.indexOf(item.issue_no)>-1){
 | 
	
	
		
			
				|  | @@ -538,7 +551,7 @@ export default {
 | 
	
		
			
				|  |  |              this.customOrderNumberList.push(item.issue_no)
 | 
	
		
			
				|  |  |              this.orderTable.push(item)
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  | -        // this.getInfo()
 | 
	
		
			
				|  |  | +        this.handleOrderPrice()
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  |      changeStudy(item){
 | 
	
		
			
				|  |  |          this.studyType = item.study_phase
 | 
	
	
		
			
				|  | @@ -580,6 +593,7 @@ export default {
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  |      // 生成订单
 | 
	
		
			
				|  |  |      handleOrder(){
 | 
	
		
			
				|  |  | +        this.createOrderLoading = true
 | 
	
		
			
				|  |  |          let MethodName = "/ShopServer/Client/OrderManager/CreateOrder";
 | 
	
		
			
				|  |  |          let data = {
 | 
	
		
			
				|  |  |              goods_type: this.bookType==='LB'?0:this.bookType==='baozhi'?2:null,
 | 
	
	
		
			
				|  | @@ -588,12 +602,15 @@ export default {
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |          getLogin(MethodName, data)
 | 
	
		
			
				|  |  |          .then((res) => {
 | 
	
		
			
				|  |  | +            this.createOrderLoading = false
 | 
	
		
			
				|  |  |              if(res.status === 1){
 | 
	
		
			
				|  |  |                  this.orderId = res.id
 | 
	
		
			
				|  |  |                  this.qr_code_url = res.qr_code_url
 | 
	
		
			
				|  |  |                  this.paymentShow = true;
 | 
	
		
			
				|  |  |                  this.order_amount = res.order_amount
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  | +        }).catch(()=>{
 | 
	
		
			
				|  |  | +            this.createOrderLoading = false
 | 
	
		
			
				|  |  |          })
 | 
	
		
			
				|  |  |          // this.paymentShow = true;
 | 
	
		
			
				|  |  |      },
 | 
	
	
		
			
				|  | @@ -867,6 +884,7 @@ export default {
 | 
	
		
			
				|  |  |                      font-size: 16px;
 | 
	
		
			
				|  |  |                      line-height: 40px;
 | 
	
		
			
				|  |  |                      text-align: center;
 | 
	
		
			
				|  |  | +                    width: 128px;
 | 
	
		
			
				|  |  |                  }
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  |          }
 |