From 832a37044afeea095d43535bcec6d2e71c4d2409 Mon Sep 17 00:00:00 2001
From: PC-20250623MANY\Administrator <344137771@qq.com>
Date: Sat, 16 Aug 2025 14:29:20 +0800
Subject: [PATCH] 1

---
 src/views/account/components/Trasferire.vue |  484 ++++++++++++++++++++----------------
 src/views/ipo/ipo.vue                       |   29 ++
 src/main.js                                 |    1 
 src/views/account/account.vue               |  169 +++++++++---
 src/views/home/components/HomeRight.vue     |   39 +-
 src/views/account/components/Withdraw.vue   |   38 ++
 6 files changed, 469 insertions(+), 291 deletions(-)

diff --git a/src/main.js b/src/main.js
index a13e6ac..6aa9fed 100644
--- a/src/main.js
+++ b/src/main.js
@@ -77,6 +77,7 @@
 Vue.prototype.$message = Message;
 Vue.prototype.$msgbox = MessageBox;
 Vue.prototype.$alert = MessageBox.alert;
+Vue.prototype.$prompt = MessageBox.prompt;
 Vue.prototype.$confirm = MessageBox.confirm;
 import "./assets/style/variables.scss";
 
diff --git a/src/views/account/account.vue b/src/views/account/account.vue
index c5b3789..66b2f59 100644
--- a/src/views/account/account.vue
+++ b/src/views/account/account.vue
@@ -11,38 +11,17 @@
       </div>
 
       <div class="flex-between" style="width: 100%">
-        <div class="overview-content">
-          <div class="overview-item">
-            <div class="item-label">{{ $t("hj49") }}</div>
-            <div class="item-value">
-              {{ moneyData.symbol }} {{ moneyData.totalMoney }}
-            </div>
-          </div>
-          <div class="overview-item">
-            <div class="item-label">{{ $t("hj48") }}</div>
-            <div class="item-value">
-              {{ moneyData.symbol }} {{ moneyData.availableBalance }}
-            </div>
-          </div>
-          <div class="overview-item">
-            <div class="item-label">{{ $t("ff1") }}</div>
-            <div class="item-value">
-              {{ moneyData.symbol }} {{ moneyData.freezeMoney }}
-            </div>
-          </div>
-        </div>
-
         <div class="action-buttons">
-			<el-button
-			  type="success"
-			  class="deposit-btn"
-			  @click="trasferireVisible = true"
-			>
-			  <div class="flex-center">
-			    <img src="@/assets/images/account_hz.png" alt="Deposit" />
-			    {{ $t("劃轉") }}
-			  </div>
-			</el-button>
+          <el-button
+            type="success"
+            class="deposit-btn"
+            @click="trasferireVisible = true"
+          >
+            <div class="flex-center">
+              <img src="@/assets/images/account_hz.png" alt="Deposit" />
+              {{ $t("劃轉") }}
+            </div>
+          </el-button>
           <el-button
             type="success"
             class="deposit-btn"
@@ -101,6 +80,29 @@
         <div class="market-header">
           <h3>{{ $t("美国") }}</h3>
         </div>
+
+        <div
+          class="overview-content"
+          v-for="i in moneyData"
+          :key="i.id"
+          v-show="i.accectType == 'US'"
+        >
+          <div class="overview-item">
+            <div class="item-label">{{ $t("hj49") }}</div>
+            <div class="item-value">{{ i.symbol }} {{ i.totalMoney }}</div>
+          </div>
+          <div class="overview-item">
+            <div class="item-label">{{ $t("hj48") }}</div>
+            <div class="item-value">
+              {{ i.symbol }} {{ i.availableBalance }}
+            </div>
+          </div>
+          <div class="overview-item">
+            <div class="item-label">{{ $t("ff1") }}</div>
+            <div class="item-value">{{ i.symbol }} {{ i.freezeMoney }}</div>
+          </div>
+        </div>
+
         <div class="market-content">
           <div class="market-row">
             <div class="market-label">
@@ -149,6 +151,29 @@
         <div class="market-header">
           <h3>{{ $t("hk1") }}</h3>
         </div>
+        
+        <div
+          class="overview-content"
+          v-for="i in moneyData"
+          :key="i.id"
+          v-show="i.accectType == 'HK'"
+        >
+          <div class="overview-item">
+            <div class="item-label">{{ $t("hj49") }}</div>
+            <div class="item-value">{{ i.symbol }} {{ i.totalMoney }}</div>
+          </div>
+          <div class="overview-item">
+            <div class="item-label">{{ $t("hj48") }}</div>
+            <div class="item-value">
+              {{ i.symbol }} {{ i.availableBalance }}
+            </div>
+          </div>
+          <div class="overview-item">
+            <div class="item-label">{{ $t("ff1") }}</div>
+            <div class="item-value">{{ i.symbol }} {{ i.freezeMoney }}</div>
+          </div>
+        </div>
+
         <div class="market-content">
           <div class="market-row">
             <div class="market-label">
@@ -197,11 +222,34 @@
         </div>
       </div>
     </div>
-    <div class="market-data page-w a_card" style="padding-top: 0;">
+    <div class="market-data page-w a_card" style="padding-top: 0">
       <div class="market-section sb_b">
         <div class="market-header">
           <h3>{{ $t("tw") }}</h3>
         </div>
+        
+        <div
+          class="overview-content"
+          v-for="i in moneyData"
+          :key="i.id"
+          v-show="i.accectType == 'TW'"
+        >
+          <div class="overview-item">
+            <div class="item-label">{{ $t("hj49") }}</div>
+            <div class="item-value">{{ i.symbol }} {{ i.totalMoney }}</div>
+          </div>
+          <div class="overview-item">
+            <div class="item-label">{{ $t("hj48") }}</div>
+            <div class="item-value">
+              {{ i.symbol }} {{ i.availableBalance }}
+            </div>
+          </div>
+          <div class="overview-item">
+            <div class="item-label">{{ $t("ff1") }}</div>
+            <div class="item-value">{{ i.symbol }} {{ i.freezeMoney }}</div>
+          </div>
+        </div>
+
         <div class="market-content">
           <div class="market-row">
             <div class="market-label">
@@ -249,11 +297,34 @@
           </div>
         </div>
       </div>
-      
+
       <div class="market-section sb_b">
         <div class="market-header">
           <h3>{{ $t("id1") }}</h3>
         </div>
+        
+        <div
+          class="overview-content"
+          v-for="i in moneyData"
+          :key="i.id"
+          v-show="i.accectType == 'IN'"
+        >
+          <div class="overview-item">
+            <div class="item-label">{{ $t("hj49") }}</div>
+            <div class="item-value">{{ i.symbol }} {{ i.totalMoney }}</div>
+          </div>
+          <div class="overview-item">
+            <div class="item-label">{{ $t("hj48") }}</div>
+            <div class="item-value">
+              {{ i.symbol }} {{ i.availableBalance }}
+            </div>
+          </div>
+          <div class="overview-item">
+            <div class="item-label">{{ $t("ff1") }}</div>
+            <div class="item-value">{{ i.symbol }} {{ i.freezeMoney }}</div>
+          </div>
+        </div>
+
         <div class="market-content">
           <div class="market-row">
             <div class="market-label">
@@ -383,26 +454,26 @@
       </div>
     </div>
 
-	<!-- 划转弹窗 -->
-	<Trasferire
-	  :dialogVisible.sync="trasferireVisible"
-	  v-if="trasferireVisible"
-	  @onClose="getMoney"
-	  :maxNum="Math.floor(moneyData.availableBalance * 100) / 100"
-	></Trasferire>
+    <!-- 划转弹窗 -->
+    <Trasferire
+      :dialogVisible.sync="trasferireVisible"
+      v-if="trasferireVisible"
+      @onClose="getMoney"
+      :moneyData="moneyData"
+    ></Trasferire>
     <!-- 充值弹窗 -->
     <Deposit
       :dialogVisible.sync="depositDialogVisible"
       v-if="depositDialogVisible"
       @onClose="getMoney"
     ></Deposit>
-	
+
     <!-- 提现弹窗 -->
     <Withdraw
       :dialogVisible.sync="withdrawVisible"
       v-if="withdrawVisible"
       @onClose="getMoney"
-      :maxNum="Math.floor(moneyData.availableBalance * 100) / 100"
+      :moneyData="moneyData"
     ></Withdraw>
 
     <!-- 贷款申请弹窗 -->
@@ -464,7 +535,7 @@
     lp,
     bto,
     Deposit,
-	Trasferire,
+    Trasferire,
     Withdraw,
     LoanApplication,
     LoanRecords,
@@ -474,13 +545,13 @@
   data() {
     return {
       nav: 1,
-      moneyData: {}, // 账户金额
+      moneyData: [], // 账户金额
       userInfo: {}, // 用户信息
       positionData: {}, // 账户持仓数据
       depositAmount: "", // 存款金额
       depositMethod: "Bank Transfer", // 存款方式
       depositDialogVisible: false, // 存款弹窗显示状态
-	  trasferireVisible: false, // 存款弹窗显示状态
+      trasferireVisible: false, // 存款弹窗显示状态
       withdrawVisible: false, // 存款弹窗显示状态
       applicationVisible: false, // 申请贷款弹窗显示状态
       recordsVisible: false, // 贷款记录弹窗显示状态
@@ -509,7 +580,7 @@
     async getMoney() {
       let data = await api.getMoney();
       if (data.status === 0) {
-        this.moneyData = data.data[0];
+        this.moneyData = data.data;
       }
     },
     // 获取用户信息
@@ -593,8 +664,8 @@
 .overview-content {
   display: flex;
   justify-content: space-between;
-  margin-bottom: 20px;
-  width: 50%;
+  // margin-bottom: 20px;
+  padding: 15px 20px 0;
 }
 
 .overview-item {
@@ -615,7 +686,7 @@
 
 .action-buttons {
   display: flex;
-  justify-content: flex-end;
+  justify-content: flex-start;
   margin-bottom: 20px;
   width: 50%;
 
diff --git a/src/views/account/components/Trasferire.vue b/src/views/account/components/Trasferire.vue
index 9017d61..cd47911 100644
--- a/src/views/account/components/Trasferire.vue
+++ b/src/views/account/components/Trasferire.vue
@@ -1,229 +1,285 @@
 <template>
-	<el-dialog :title="$t('劃轉')" :visible.sync="dialogVisible" width="720px" :before-close="onClose">
-		<el-form ref="withdrawform" :model="form" label-width="auto" :rules="rules">
-			<el-form-item :label="$t('从')" prop="fromType">
-				<div class="flex-center">
-					<el-select @change="getExchangeRate" v-model="form.fromType" :placeholder="$t('請選擇')">
-						<el-option v-for="item in options" :key="item.value" :label="item.name" :value="item.name">
-						</el-option>
-					</el-select>
-					<el-input v-model.number="form.amt" @input="amtinput" type="number"></el-input>
-					<el-button type="primary" style="margin-left: 10px" @click="form.amt = maxNum"
-						class="submit">{{ $t("最大") }}</el-button>
+  <el-dialog
+    :title="$t('劃轉')"
+    :visible.sync="dialogVisible"
+    width="720px"
+    :before-close="onClose"
+  >
+    <el-form ref="withdrawform" :model="form" label-width="auto" :rules="rules">
+      <el-form-item :label="$t('从')" prop="fromType">
+        <div class="flex-center">
+          <el-select
+            @change="getExchangeRate"
+            v-model="form.fromType"
+            :placeholder="$t('請選擇')"
+          >
+            <el-option
+              v-for="item in options"
+              :key="item.value"
+              :label="item.name"
+              :value="item.name"
+            >
+            </el-option>
+          </el-select>
+          <el-input
+            v-model.number="form.amt"
+            @input="amtinput"
+            type="number"
+          ></el-input>
+          <el-button
+            type="primary"
+            style="margin-left: 10px"
+            @click="form.amt = maxNum"
+            class="submit"
+            >{{ $t("最大") }}</el-button
+          >
+        </div>
+      </el-form-item>
 
-				</div>
-			</el-form-item>
+      <el-form-item :label="$t('到')" prop="toType">
+        <div class="flex-center">
+          <el-select
+            @change="getExchangeRate"
+            v-model="form.toType"
+            :placeholder="$t('請選擇')"
+          >
+            <el-option
+              v-for="item in actions"
+              :key="item.value"
+              :label="item.name"
+              :value="item.name"
+            >
+            </el-option>
+          </el-select>
+          <el-input v-model.number="price" disabled type="number"></el-input>
+        </div>
+      </el-form-item>
 
-			<el-form-item :label="$t('到')" prop="toType">
-				<div class="flex-center">
-					<el-select @change="getExchangeRate" v-model="form.toType" :placeholder="$t('請選擇')">
-						<el-option v-for="item in actions" :key="item.value" :label="item.name" :value="item.name">
-						</el-option>
-					</el-select>
-					<el-input v-model.number="price" disabled type="number"></el-input>
-				</div>
-			</el-form-item>
+      <el-form-item>
+        <div class="ts">
+          {{ $t("可用餘額") }}
+          {{ maxNum }} {{ form.fromType }}
+        </div>
+        <div class="ts">
+          {{ $t("汇率") }}
+          1{{ form.fromType }} ≈ {{ rata }}{{ form.toType }}
+        </div>
+        <div class="ts">
+          {{ $t("hj44") }}
+          {{ handling_fee }}
+        </div>
+      </el-form-item>
 
-			<el-form-item>
-				<div class="ts">
-					{{ $t("可用餘額") }}
-					{{ maxNum }} {{form.fromType}}
-				</div>
-				<div class="ts">
-					{{ $t("汇率") }}
-					1{{ form.fromType }} ≈ {{rata}}{{form.toType}}
-				</div>
-				<div class="ts">
-					{{ $t("hj44") }}
-					{{handling_fee}}
-				</div>
-			</el-form-item>
-
-			<el-form-item>
-				<el-button @click="onClose">{{ $t("qx") }}</el-button>
-				<el-button type="primary" @click="onSubmit" class="submit">
-					{{ $t("hj161") }}
-				</el-button>
-			</el-form-item>
-		</el-form>
-	</el-dialog>
+      <el-form-item>
+        <el-button @click="onClose">{{ $t("qx") }}</el-button>
+        <el-button type="primary" @click="onSubmit" class="submit">
+          {{ $t("hj161") }}
+        </el-button>
+      </el-form-item>
+    </el-form>
+  </el-dialog>
 </template>
 
 <script>
-	import * as api from "@/axios/api";
-	export default {
-		data() {
-			return {
-				form: {
-					fromType: "US", //账户
-					toType: "HK", //指定账户
-					amt: "", //划转金额
-				},
-				handling_fee: "", //手续费
-				rata: "", //汇率
-				price: "", //划转后金额
-				allMoney: "",
-				moneylist:[],  //全部账户信息
-				rules: {
-					fromType: [{
-						required: true,
-						message: this.$t("請選擇"),
-						trigger: "change"
-					}, ],
-					toType: [{
-						required: true,
-						message: this.$t("請選擇"),
-						trigger: "change"
-					}],
-					bankId: [{
-						required: true,
-						message: this.$t("請選擇"),
-						trigger: "change"
-					}, ],
-					amt: [{
-						required: true,
-						message: this.$t("请输入")
-					}],
-				},
-				options: [{
-					name: "US",
-					value: "USD"
-				}, {
-					name: "HK",
-					value: "HKD"
-				}, {
-					name: "IN",
-					value: "INR"
-				}, {
-					name: "TW",
-					value: "TWD"
-				}],
-				actions: [{
-					name: "US",
-					value: "USD"
-				}, {
-					name: "HK",
-					value: "HKD"
-				}, {
-					name: "IN",
-					value: "INR"
-				}, {
-					name: "TW",
-					value: "TWD"
-				}],
-				yhkactions: [],
-			};
-		},
-		props: {
-			dialogVisible: {
-				type: Boolean,
-				default: false,
-			},
-			//可用余额
-			maxNum: {
-				type: Number,
-				default: 0,
-			},
-		},
-		created() {
-			this.getExchangeRate()
-			this.getfee()
-			this.getMoney()
-		},
-		methods: {
-			
-			async getMoney() {
-				let data = await api.getMoney();
-				if (data.status === 0) {
-					this.moneylist = data.data
-				}
-			},
-			amtinput(e) {
-				this.price = e * this.rata
-			},
-			async getfee() {
-				let data = await api.getfee();
-				if (data.status == 0) {
-					this.handling_fee = data.data.cValue
-				}
-			},
-			async getExchangeRate() {
-				// this.getMoney()
-				// this.amtinput()
-				let selectedName = this.form.fromType;
-				let toselectedName = this.form.toType;
-				if (selectedName == toselectedName) {
-					this.rata = '1'
-					return
-				}
-				let selectedItem = this.options.find(item => item.name === selectedName);
-				let toselectedItem = this.actions.find(item => item.name === toselectedName);
-				
-				this.moneylist.forEach((item) => {
-				  if (item.symbolCode == selectedItem.value ) {
-				    this.maxNum = item.availableBalance;
-				  }
-				});
-				
-				let data = await api.getRateInfo();
-				data.data &&
-					data.data.forEach((item) => {
-						if (item.currency == selectedItem.value && item.conversionCurrency == toselectedItem
-							.value) {
-							this.rata = item.rata;
-						}
-					});
-			},
-			// 关闭弹窗
-			onClose() {
-				this.$emit("update:dialogVisible", false);
-				this.$emit("onClose"); // 关闭弹窗时,通知父组件
-			},
-			// 提交
-			onSubmit() {
-				this.$refs["withdrawform"].validate(async (valid) => {
-					if (valid) {
-						let data = await api.transfer(this.form);
-						if (data.status == 0) {
-							this.$message.success(this.$t("划转成功"));
-							this.onClose();
-						}
-					} else {
-						console.log("outMoney err");
-						return false;
-					}
-				});
-			},
-		},
-	};
+import * as api from "@/axios/api";
+export default {
+  data() {
+    return {
+      form: {
+        fromType: "US", //账户
+        toType: "HK", //指定账户
+        amt: "", //划转金额
+      },
+      handling_fee: "", //手续费
+      rata: "", //汇率
+      price: "", //划转后金额
+      allMoney: "",
+      moneylist: [], //全部账户信息
+      rules: {
+        fromType: [
+          {
+            required: true,
+            message: this.$t("請選擇"),
+            trigger: "change",
+          },
+        ],
+        toType: [
+          {
+            required: true,
+            message: this.$t("請選擇"),
+            trigger: "change",
+          },
+        ],
+        bankId: [
+          {
+            required: true,
+            message: this.$t("請選擇"),
+            trigger: "change",
+          },
+        ],
+        amt: [
+          {
+            required: true,
+            message: this.$t("请输入"),
+          },
+        ],
+      },
+      options: [
+        {
+          name: "US",
+          value: "USD",
+        },
+        {
+          name: "HK",
+          value: "HKD",
+        },
+        {
+          name: "IN",
+          value: "INR",
+        },
+        {
+          name: "TW",
+          value: "TWD",
+        },
+      ],
+      actions: [
+        {
+          name: "US",
+          value: "USD",
+        },
+        {
+          name: "HK",
+          value: "HKD",
+        },
+        {
+          name: "IN",
+          value: "INR",
+        },
+        {
+          name: "TW",
+          value: "TWD",
+        },
+      ],
+      yhkactions: [],
+    };
+  },
+  props: {
+    dialogVisible: {
+      type: Boolean,
+      default: false,
+    },
+    moneyData: {
+      type: Array,
+      default: () => [],
+    },
+  },
+  computed: {
+    maxNum() {
+      let max = 0;
+      this.moneyData.forEach((i) => {
+        if (i.accectType == this.form.fromType) max = i.availableBalance;
+      });
+      return max;
+    },
+  },
+  created() {
+    this.getExchangeRate();
+    this.getfee();
+    this.getMoney();
+  },
+  methods: {
+    async getMoney() {
+      let data = await api.getMoney();
+      if (data.status === 0) {
+        this.moneylist = data.data;
+      }
+    },
+    amtinput(e) {
+      this.price = e * this.rata;
+    },
+    async getfee() {
+      let data = await api.getfee();
+      if (data.status == 0) {
+        this.handling_fee = data.data.cValue;
+      }
+    },
+    async getExchangeRate() {
+      // this.getMoney()
+      // this.amtinput()
+      let selectedName = this.form.fromType;
+      let toselectedName = this.form.toType;
+      if (selectedName == toselectedName) {
+        this.rata = "1";
+        return;
+      }
+      let selectedItem = this.options.find(
+        (item) => item.name === selectedName
+      );
+      let toselectedItem = this.actions.find(
+        (item) => item.name === toselectedName
+      );
+
+      let data = await api.getRateInfo();
+      data.data &&
+        data.data.forEach((item) => {
+          if (
+            item.currency == selectedItem.value &&
+            item.conversionCurrency == toselectedItem.value
+          ) {
+            this.rata = item.rata;
+          }
+        });
+    },
+    // 关闭弹窗
+    onClose() {
+      this.$emit("update:dialogVisible", false);
+      this.$emit("onClose"); // 关闭弹窗时,通知父组件
+    },
+    // 提交
+    onSubmit() {
+      this.$refs["withdrawform"].validate(async (valid) => {
+        if (valid) {
+          let data = await api.transfer(this.form);
+          if (data.status == 0) {
+            this.$message.success(this.$t("划转成功"));
+            this.onClose();
+          }
+        } else {
+          console.log("outMoney err");
+          return false;
+        }
+      });
+    },
+  },
+};
 </script>
 
 <style lang="scss" scoped>
-	::v-deep .el-input--suffix .el-input__inner {
-		width: 280px;
-	}
+::v-deep .el-input--suffix .el-input__inner {
+  width: 280px;
+}
 
-	::v-deep .el-select-dropdown__list {
-		display: flex;
-		flex-direction: column;
-	}
+::v-deep .el-select-dropdown__list {
+  display: flex;
+  flex-direction: column;
+}
 
-	::v-deep .el-radio__input.is-checked .el-radio__inner {
-		border-color: #c4d600;
-		background: #c4d600;
-	}
+::v-deep .el-radio__input.is-checked .el-radio__inner {
+  border-color: #c4d600;
+  background: #c4d600;
+}
 
-	::v-deep .el-radio__input.is-checked+.el-radio__label {
-		color: #c4d600;
-	}
+::v-deep .el-radio__input.is-checked + .el-radio__label {
+  color: #c4d600;
+}
 
-	.submit {
-		background-color: #c4d600 !important;
-		border-color: #c4d600 !important;
-	}
+.submit {
+  background-color: #c4d600 !important;
+  border-color: #c4d600 !important;
+}
 
-	.ts {
-		color: #dfb758;
-		text-align: end;
-	}
-</style>
\ No newline at end of file
+.ts {
+  color: #dfb758;
+  text-align: end;
+}
+</style>
diff --git a/src/views/account/components/Withdraw.vue b/src/views/account/components/Withdraw.vue
index f31a520..af33155 100644
--- a/src/views/account/components/Withdraw.vue
+++ b/src/views/account/components/Withdraw.vue
@@ -58,7 +58,13 @@
       <el-form-item v-if="!!form.assetsType">
         <div class="ts">
           {{ $t("可用餘額") }}
-          {{ maxNum }} USD
+          {{ maxNum }}
+          <span
+            v-for="i in moneyData"
+            :key="i.id"
+            v-show="i.accectType == form.assetsType"
+            >{{ i.symbolCode }}</span
+          >
         </div>
       </el-form-item>
 
@@ -93,7 +99,12 @@
         ],
         amt: [{ required: true, message: this.$t("请输入") }],
       },
-      options: [{ name: "US", value: "USD" },{ name: "HK", value: "HKD" },{ name: "IN", value: "INR" },{ name: "TW", value: "TWD" }],
+      options: [
+        { name: "US", value: "USD" },
+        { name: "HK", value: "HKD" },
+        { name: "IN", value: "INR" },
+        { name: "TW", value: "TWD" },
+      ],
       actions: [{ name: this.$t("hj215"), value: "YHK" }],
       yhkactions: [],
     };
@@ -103,9 +114,18 @@
       type: Boolean,
       default: false,
     },
-    maxNum: {
-      type: Number,
-      default: 0,
+    moneyData: {
+      type: Array,
+      default: () => [],
+    },
+  },
+  computed: {
+    maxNum() {
+      let max = 0;
+      this.moneyData.forEach((i) => {
+        if (i.accectType == this.form.assetsType) max = i.availableBalance;
+      });
+      return max;
     },
   },
   created() {
@@ -149,10 +169,10 @@
 </script>
 
 <style lang="scss" scoped>
-	::v-deep .el-select-dropdown__list{
-		display: flex;
-		flex-direction: column;
-	}
+::v-deep .el-select-dropdown__list {
+  display: flex;
+  flex-direction: column;
+}
 ::v-deep .el-radio__input.is-checked .el-radio__inner {
   border-color: #c4d600;
   background: #c4d600;
diff --git a/src/views/home/components/HomeRight.vue b/src/views/home/components/HomeRight.vue
index 752fdce..829fddb 100644
--- a/src/views/home/components/HomeRight.vue
+++ b/src/views/home/components/HomeRight.vue
@@ -45,17 +45,17 @@
         <div class="value">
           {{ obj.type | currencySymbol }}
           {{ (obj.nowPrice * bform.num) | _toLocaleString }}
-          <div v-if="obj.type != $mc">
+          <!-- <div v-if="obj.type != $mc">
             ≈ $
             {{ (obj.nowPrice * bform.num * rate(obj.type)) | _toLocaleString }}
-          </div>
+          </div> -->
         </div>
       </div>
 
       <div class="info_item flex-between">
         <div class="label">{{ $t("hj48") }}</div>
         <div class="value">
-          {{ moneyData.symbol }} {{ moneyData.availableBalance }}
+          {{ CurrentMoneyData.symbol }} {{ CurrentMoneyData.availableBalance }}
         </div>
       </div>
 
@@ -104,10 +104,10 @@
         <div class="value">
           {{ obj.type | currencySymbol }}
           {{ (obj.nowPrice * sform.num) | _toLocaleString }}
-          <div v-if="obj.type != $mc">
+          <!-- <div v-if="obj.type != $mc">
             ≈ $
             {{ (obj.nowPrice * sform.num * rate(obj.type)) | _toLocaleString }}
-          </div>
+          </div> -->
         </div>
       </div>
 
@@ -145,7 +145,7 @@
         100: "100%",
       },
       depositAmount: "", // 存款金额
-      moneyData: {}, // 账户金额
+      moneyData: [], // 账户金额
       pages: {}, // 已购买股票信息
     };
   },
@@ -159,6 +159,18 @@
       default: null,
     },
   },
+  computed: {
+    // 当前账户金额
+    CurrentMoneyData() {
+      let obj = {};
+      this.moneyData.forEach((i) => {
+        if (i.accectType == this.obj.type) {
+          obj = i;
+        }
+      });
+      return obj;
+    },
+  },
   watch: {
     obj: {
       handler(val) {
@@ -169,15 +181,10 @@
     },
     // 通过进度条来计算数量
     bVal(val) {
-      if (this.obj.type != this.$mc)
-        this.bform.num = Math.floor(
-          (this.moneyData.availableBalance * (val / 100)) /
-            (this.obj.nowPrice * this.rate(this.obj.type))
-        );
-      else
-        this.bform.num = Math.floor(
-          (this.moneyData.availableBalance * (val / 100)) / this.obj.nowPrice
-        );
+      this.bform.num = Math.floor(
+        (this.CurrentMoneyData.availableBalance * (val / 100)) /
+          this.obj.nowPrice
+      );
     },
     sVal(val) {
       this.sform.num = Math.ceil(this.pages.orderNum * (val / 100));
@@ -202,7 +209,7 @@
     async getMoney() {
       let data = await api.getMoney();
       if (data.status === 0) {
-        this.moneyData = data.data[0];
+        this.moneyData = data.data;
       }
     },
     // 买卖,买:0,卖:1
diff --git a/src/views/ipo/ipo.vue b/src/views/ipo/ipo.vue
index d58a9a5..257af68 100644
--- a/src/views/ipo/ipo.vue
+++ b/src/views/ipo/ipo.vue
@@ -135,19 +135,42 @@
   methods: {
     // 打开购买弹窗
     buyOpen(i) {
-      this.$confirm("", this.$t("操作确认"), {
+      // this.$confirm("", this.$t("操作确认"), {
+      //   confirmButtonText: this.$t("qr"),
+      //   cancelButtonText: this.$t("qx"),
+      // })
+      //   .then(async () => {
+      //     // 申购
+      //     let opt = {
+      //       newCode: i.code,
+      //       applyNums: i.orderNumber,
+      //       password: i.password,
+      //       newlistId: i.newlistId,
+      //       type: i.type,
+      //     };
+      //     let data = await api.getNewAdd(opt);
+
+      //     if (data.status == 0) {
+      //       this.$message.success(data.msg);
+      //       this.init(); // 重新获取列表
+      //     }
+      //   })
+      //   .catch(() => {});
+
+      this.$prompt(this.$t("sl"), this.$t("操作确认"), {
         confirmButtonText: this.$t("qr"),
         cancelButtonText: this.$t("qx"),
       })
-        .then(async () => {
+        .then(async (val) => {
           // 申购
           let opt = {
             newCode: i.code,
-            applyNums: i.orderNumber,
+            applyNums: val.value,
             password: i.password,
             newlistId: i.newlistId,
             type: i.type,
           };
+
           let data = await api.getNewAdd(opt);
 
           if (data.status == 0) {

--
Gitblit v1.9.3