<template>
  <div>
    <base-input
      label=" 单轮趋势最大持仓金额"
      v-model="accountInfo.MaxOrderTotalPurchasePricePerRound"
      disabled
    ></base-input>
    <base-input
      label=" 单日持仓最大金额(当天内购买未在当天内出售)"
      v-model="accountInfo.MaxTotalPurchasePricePerDay"
      disabled
    ></base-input>
    <base-input
      label=" 订单持仓最长时间"
      v-model="accountInfo.MaxTotalPurchasePricePerDay"
      disabled
    ></base-input>
    <p>
      订单持仓最长时间：{{
        accountInfo.MaxOrderHoldTime && secToMin(accountInfo.MaxOrderHoldTime)
      }}
    </p>

    <p>
      订单持仓最短时间：{{
        accountInfo.MinOrderHoldTime && secToMin(accountInfo.MinOrderHoldTime)
      }}
    </p>

    <p>
      订单最大浮动亏损比：{{
        accountInfo.MaxOrderLossRatio &&
          accountInfo.MaxOrderLossRatio.toFixed(2)
      }}%
    </p>

    <p>
      持仓最大浮动亏损比：{{
        accountInfo.MaxAccountLossRatio &&
          accountInfo.MaxAccountLossRatio.toFixed(2)
      }}%
    </p>

    <p>
      最大盈利金额、订单盈利占比：{{
        accountInfo.MaxOrderProfit && accountInfo.MaxOrderProfit.toFixed(4)
      }}({{
        accountInfo.MaxOrderProfitRatio &&
          accountInfo.MaxOrderProfitRatio.toFixed(2)
      }}%)
    </p>

    <p>
      最小盈利金额、订单盈利占比：{{
        accountInfo.MinOrderProfit && accountInfo.MinOrderProfit.toFixed(4)
      }}({{
        accountInfo.MinOrderProfitRatio &&
          accountInfo.MinOrderProfitRatio.toFixed(2)
      }}%)
    </p>
  </div>
</template>
<script>
import { secToMin } from "../../utils/TimeUtils";
export default {
  model: { prop: "accountInfo", event: "accountChange" },
  props: { accountInfo: { type: Object, default: () => {} } },
  data() {
    return { secToMin };
  }
};
</script>

<style></style>
