MONSTER-ygh 11 mēneši atpakaļ
vecāks
revīzija
6eda0bd83a

+ 1 - 2
src/views/team/teamMr/dialog/orderAllBox.vue

@@ -119,8 +119,7 @@
   </template>
   
   <script>
-  import { creditGrantingBoxApi } from "@/api/team/teamMr";
-  import { pageList } from '@/api/order/orderMr';
+  import { pageList } from '@/api/order/groupBuyingMr';
   import detailsDia from "./details";
   export default {
     name: "addAndEdit",

+ 10 - 3
src/views/windowTicketSales/model/increaseViewers.vue

@@ -651,11 +651,11 @@ import {
         submitForm(formName) {
             this.$refs[formName].validate((valid) => {
             if (valid) {
-                if(this.ruleForm.paymentType == 4 && (!this.balance||this.balance<=0)) {
+                if(this.ruleForm.paymentType == 4 && (!this.balance||this.balance<=0||this.balance < this.moneyAll)) {
                     this.$message.error('团队账户余额不足!!!');
                     return
                 }
-                if(this.ruleForm.paymentType == 5 && (!this.grantQuota||this.grantQuota<=0)) {
+                if(this.ruleForm.paymentType == 5 && (!this.grantQuota||this.grantQuota<=0||this.grantQuota < this.moneyAll)) {
                     this.$message.error('团队授信余额不足!!!');
                     return
                 }
@@ -1148,7 +1148,14 @@ import {
                     source: value
                 })
                 this.balance = res.data.balance
-                this.grantQuota = res.data.grantQuota
+                if(res.data.grantQuota && res.data.grantUsed) {
+                    this.grantQuota = res.data.grantQuota - res.data.grantUsed
+                }else if(res.data.grantQuota) {
+                    this.grantQuota = res.data.grantQuota
+                }else {
+                    this.grantQuota = 0
+                }
+                
             } catch (error) {
                 this.balance = null
                 this.grantQuota = null