diff --git a/src/components/MovementPolicyForm.vue b/src/components/MovementPolicyForm.vue
index c355430..1d6b148 100644
--- a/src/components/MovementPolicyForm.vue
+++ b/src/components/MovementPolicyForm.vue
@@ -344,7 +344,9 @@
- 更新
+ 更新
@@ -366,7 +368,7 @@ import {
import BaseRadio from "@/components/BaseRadio.vue";
export default {
model: { prop: "myForm", event: "getForm" },
- props: { myForm: { type: Object, default: () => {} } },
+ props: { myForm: { type: Object, default: () => {} }, robotId: "" },
components: { BaseRadio },
watch: {
form() {
@@ -465,6 +467,32 @@ export default {
)[0].content;
console.log(result, "source");
return result;
+ },
+ updateTrend() {
+ this.$http
+ .post("/Api/Signal/ReceiveSignal", {
+ NotifyType: this.NotifyType,
+ Symbol: this.form.Symbol,
+ KLinePeriodic: this.form.PeriodicSignal,
+ ClosePrice: this.ClosePrice,
+ RobotId: this.robotId,
+ IsDebug: true
+ })
+ .then(res => {
+ if (res.Code == 200) {
+ this.sMessage("success", "更新成功");
+ } else {
+ this.sMessage("danger", res.Message);
+ }
+ });
+ },
+ // 封装showNotification
+ sMessage(type, message) {
+ this.$notify({
+ type: type,
+ message,
+ timeout: 1800
+ });
}
}
};
diff --git a/src/components/SidebarPlugin/SideBar.vue b/src/components/SidebarPlugin/SideBar.vue
index abda1ae..29d3eeb 100644
--- a/src/components/SidebarPlugin/SideBar.vue
+++ b/src/components/SidebarPlugin/SideBar.vue
@@ -14,7 +14,7 @@
diff --git a/src/main.js b/src/main.js
index 6298849..40cbd1b 100644
--- a/src/main.js
+++ b/src/main.js
@@ -20,7 +20,17 @@ import router from "./router/index";
import BlackDashboard from "./plugins/blackDashboard";
import AxiosPlugin from "./utils/plugin/axios-plugin";
-import { Table, TableColumn, Tooltip, Switch,Select,Option } from "element-ui";
+import {
+ Table,
+ TableColumn,
+ Tooltip,
+ Switch,
+ Select,
+ Option,
+ Tabs,
+ TabPane,
+ Pagination
+} from "element-ui";
import "element-ui/lib/theme-chalk/index.css";
import i18n from "./i18n";
import "./registerServiceWorker";
@@ -34,6 +44,9 @@ Vue.use(Tooltip);
Vue.use(Switch);
Vue.use(Select);
Vue.use(Option);
+Vue.use(Tabs);
+Vue.use(TabPane);
+Vue.use(Pagination);
/* eslint-disable no-new */
new Vue({
router,
diff --git a/src/pages/Robot/edit.vue b/src/pages/Robot/edit.vue
index cdaf1cd..1e8d93c 100644
--- a/src/pages/Robot/edit.vue
+++ b/src/pages/Robot/edit.vue
@@ -1,48 +1,94 @@
-
-
Save
+
+
+
+
+
+ 保存设置
+
+
+
+
+
+
+
+
+ 温馨提示
+
+
+ 是否清除本轮购买参数?
+
+
+ 否
+ 是
+
+
+
+
diff --git a/src/pages/Robot/order.vue b/src/pages/Robot/order.vue
new file mode 100644
index 0000000..3d866a7
--- /dev/null
+++ b/src/pages/Robot/order.vue
@@ -0,0 +1,350 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 账号配置信息
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/prePages/js/columns.js b/src/pages/prePages/js/columns.js
index 8eb6b9d..0c0a76f 100644
--- a/src/pages/prePages/js/columns.js
+++ b/src/pages/prePages/js/columns.js
@@ -1,223 +1,223 @@
export const OrderColumns = [
{
- title: "利润",
- dataIndex: "Profit",
+ name: "利润",
+ prop: "Profit",
key: "Profit",
- scopedSlots: { customRender: "Profit" },
+ customSlot: "Profit"
},
{
- title: "购买成交量",
- dataIndex: "PurchaseCoinCount",
- key: "PurchaseCoinCount",
+ name: "购买成交量",
+ prop: "PurchaseCoinCount",
+ key: "PurchaseCoinCount"
},
- { title: "购买手续费", dataIndex: "PurchaseFee", key: "PurchaseFee" },
- { title: "购买成交价", dataIndex: "PurchasePrice", key: "PurchasePrice" },
+ { name: "购买手续费", prop: "PurchaseFee", key: "PurchaseFee" },
+ { name: "购买成交价", prop: "PurchasePrice", key: "PurchasePrice" },
{
- title: "购买成交次数",
- dataIndex: "PurchaseTradeCount",
- key: "PurchaseTradeCount",
+ name: "购买成交次数",
+ prop: "PurchaseTradeCount",
+ key: "PurchaseTradeCount"
},
- { title: "机器人名称", dataIndex: "RobotName", key: "RobotName" },
- { title: "销售成交量", dataIndex: "SaleCoinCount", key: "SaleCoinCount" },
- { title: "销售手续费", dataIndex: "SaleFee", key: "SaleFee" },
- { title: "销售成交价", dataIndex: "SalePrice", key: "SalePrice" },
- { title: "销售成交次数", dataIndex: "SaleTradeCount", key: "SaleTradeCount" },
+ { name: "机器人名称", prop: "RobotName", key: "RobotName" },
+ { name: "销售成交量", prop: "SaleCoinCount", key: "SaleCoinCount" },
+ { name: "销售手续费", prop: "SaleFee", key: "SaleFee" },
+ { name: "销售成交价", prop: "SalePrice", key: "SalePrice" },
+ { name: "销售成交次数", prop: "SaleTradeCount", key: "SaleTradeCount" },
{
- title: "订单状态",
- dataIndex: "Status",
+ name: "订单状态",
+ prop: "Status",
key: "Status",
- scopedSlots: { customRender: "status" },
+ customSlot: "status"
},
- { title: "订单交易对", dataIndex: "Symbol", key: "Symbol" },
+ { name: "订单交易对", prop: "Symbol", key: "Symbol" },
{
- title: "订单购买总价",
- dataIndex: "TotalPurchasePrice",
- key: "TotalPurchasePrice",
+ name: "订单购买总价",
+ prop: "TotalPurchasePrice",
+ key: "TotalPurchasePrice"
},
- { title: "订单销售总价", dataIndex: "TotalSalePrice", key: "TotalSalePrice" },
+ { name: "订单销售总价", prop: "TotalSalePrice", key: "TotalSalePrice" },
{
- title: "浮动盈亏",
- dataIndex: "UnstableProfit",
+ name: "浮动盈亏",
+ prop: "UnstableProfit",
key: "UnstableProfit",
- scopedSlots: { customRender: "UnstableProfit" },
- hidden: true,
+ customSlot: "UnstableProfit",
+ hidden: true
},
{
- title: "最后购买交易时间",
- dataIndex: "LastPurchaseTradeTime",
- key: "LastPurchaseTradeTime",
+ name: "最后购买交易时间",
+ prop: "LastPurchaseTradeTime",
+ key: "LastPurchaseTradeTime"
},
{
- title: "最后交易时间",
- dataIndex: "LastSaleTradeTime",
- key: "LastSaleTradeTime",
+ name: "最后交易时间",
+ prop: "LastSaleTradeTime",
+ key: "LastSaleTradeTime"
},
{
- title: "挂单时间",
- dataIndex: "CreateTime",
- key: "CreateTime",
- },
+ name: "挂单时间",
+ prop: "CreateTime",
+ key: "CreateTime"
+ }
];
export const RobotColumns = [
{
- title: "机器人名称",
- dataIndex: "Robot.Name",
- key: "Robot.Name",
+ name: "机器人名称",
+ prop: "Robot.Name",
+ key: "Robot.Name"
},
- { title: "货币对", dataIndex: "Robot.Symbol", key: "Robot.Symbol" },
+ { name: "货币对", prop: "Robot.Symbol", key: "Robot.Symbol" },
{
- title: "运行状态",
- dataIndex: "Robot.Status",
+ name: "运行状态",
+ prop: "Robot.Status",
key: "Robot.Status",
- scopedSlots: { customRender: "Status" },
+ customSlot: "Status"
},
{
- title: "只卖",
- dataIndex: "WaveBandPolicy.IsEnabledBuySignal",
+ name: "只卖",
+ prop: "WaveBandPolicy.IsEnabledBuySignal",
key: "WaveBandPolicy.IsEnabledBuySignal",
- scopedSlots: { customRender: "OnlySale" },
+ customSlot: "OnlySale"
},
{
- title: "持仓费用",
- dataIndex: "RobotAccount.TotalPurchasePrice",
- key: "RobotAccount.TotalPurchasePrice",
+ name: "持仓费用",
+ prop: "RobotAccount.TotalPurchasePrice",
+ key: "RobotAccount.TotalPurchasePrice"
},
{
- title: "持仓均价",
- dataIndex: "RobotAccount.AvgPurchasePrice",
- key: "RobotAccount.AvgPurchasePrice",
+ name: "持仓均价",
+ prop: "RobotAccount.AvgPurchasePrice",
+ key: "RobotAccount.AvgPurchasePrice"
},
{
- title: "浮动盈亏",
- dataIndex: "RobotAccount.FloatingPL",
- key: "RobotAccount.FloatingPL",
+ name: "浮动盈亏",
+ prop: "RobotAccount.FloatingPL",
+ key: "RobotAccount.FloatingPL"
},
{
- title: "总利润",
- dataIndex: "RobotAccount.TotalProfit",
- key: "RobotAccount.TotalProfit",
+ name: "总利润",
+ prop: "RobotAccount.TotalProfit",
+ key: "RobotAccount.TotalProfit"
},
{
- title: "配置",
- dataIndex: "Robot.CommonSetting",
+ name: "配置",
+ prop: "Robot.CommonSetting",
key: "Robot.CommonSetting",
- scopedSlots: { customRender: "CommonSetting" },
+ customSlot: "CommonSetting"
},
{
- title: "周期指标",
- dataIndex: "Robot.IntervalSetting",
+ name: "周期指标",
+ prop: "Robot.IntervalSetting",
key: "Robot.IntervalSetting",
- scopedSlots: { customRender: "IntervalSetting" },
+ customSlot: "IntervalSetting"
},
{
- title: "卖出设置",
- dataIndex: "Robot.SaleSetting",
+ name: "卖出设置",
+ prop: "Robot.SaleSetting",
key: "Robot.SaleSetting",
- scopedSlots: { customRender: "SaleSetting" },
+ customSlot: "SaleSetting"
},
{
- title: "操作",
- dataIndex: "action",
+ name: "操作",
+ prop: "action",
key: "action",
- scopedSlots: { customRender: "Action" },
- },
+ customSlot: "Action"
+ }
];
export const AccountColumns = [
{
- title: "账号名称",
- dataIndex: "Name",
- key: "Name",
+ name: "账号名称",
+ prop: "Name",
+ key: "Name"
},
{
- title: "账号AccessKey",
- dataIndex: "AccessKey",
- key: "AccessKey",
+ name: "账号AccessKey",
+ prop: "AccessKey",
+ key: "AccessKey"
},
{
- title: "账号SecretKey",
- dataIndex: "SecretKey",
- key: "SecretKey",
+ name: "账号SecretKey",
+ prop: "SecretKey",
+ key: "SecretKey"
},
{
- title: "帐号类型",
- dataIndex: "AccountType",
+ name: "帐号类型",
+ prop: "AccountType",
key: "AccountType",
- scopedSlots: { customRender: "AccountType" },
+ customSlot: "AccountType"
},
{
- title: "创建时间",
- dataIndex: "CreateTime",
- key: "CreateTime",
- },
+ name: "创建时间",
+ prop: "CreateTime",
+ key: "CreateTime"
+ }
];
export const tradeColumns = [
{
- title: "ID",
- dataIndex: "Id",
- key: "Id",
+ name: "ID",
+ prop: "Id",
+ key: "Id"
},
{
- title: "类型",
- dataIndex: "OrderType",
+ name: "类型",
+ prop: "OrderType",
key: "OrderType",
- scopedSlots: { customRender: "OrderType" },
+ customSlot: "OrderType"
},
{
- title: "时间",
- dataIndex: "purchaseKLineId",
+ name: "时间",
+ prop: "purchaseKLineId",
key: "purchaseKLineId",
- scopedSlots: { customRender: "KLineId" },
+ customSlot: "KLineId"
},
{
- title: "价格",
- dataIndex: "Price",
+ name: "价格",
+ prop: "Price",
key: "Price",
- scopedSlots: { customRender: "Price" },
+ customSlot: "Price"
},
{
- title: "数量",
- dataIndex: "Count",
+ name: "数量",
+ prop: "Count",
key: "Count",
- scopedSlots: { customRender: "Count" },
+ customSlot: "Count"
},
{
- title: "最大浮亏",
- dataIndex: "MaxLossRatio",
+ name: "最大浮亏",
+ prop: "MaxLossRatio",
key: "MaxLossRatio",
- scopedSlots: { customRender: "MaxLossRatio" },
+ customSlot: "MaxLossRatio"
},
{
- title: "盈亏",
- dataIndex: "Profit",
+ name: "盈亏",
+ prop: "Profit",
key: "Profit",
- scopedSlots: { customRender: "Profit" },
+ customSlot: "Profit"
},
{
- title: "累计盈亏",
- dataIndex: "TotalProfit",
+ name: "累计盈亏",
+ prop: "TotalProfit",
key: "TotalProfit",
- scopedSlots: { customRender: "TotalProfit" },
- },
+ customSlot: "TotalProfit"
+ }
];
export const logColumns = [
{
- title: "订单ID",
- dataIndex: "SpotGoodsOrderId",
- key: "SpotGoodsOrderId",
+ name: "订单ID",
+ prop: "SpotGoodsOrderId",
+ key: "SpotGoodsOrderId"
},
{
- title: "内容",
- dataIndex: "Content",
- key: "Content",
+ name: "内容",
+ prop: "Content",
+ key: "Content"
},
{
- title: "日志类型",
- dataIndex: "LogType",
+ name: "日志类型",
+ prop: "LogType",
key: "LogType",
width: 150,
filters: [
@@ -228,20 +228,20 @@ export const logColumns = [
{ text: "大趋势看多", value: 4 },
{ text: "大趋势看空", value: 5 },
{ text: "自动卖出", value: 10 },
- { text: "自动卖出(趋势收益)", value: 11 },
+ { text: "自动卖出(趋势收益)", value: 11 }
],
onFilter: (value, record) => record.LogType == value,
- scopedSlots: { customRender: "LogType" },
+ customSlot: "LogType"
},
{
- title: "机器人ID",
- dataIndex: "RobotId",
- key: "RobotId",
+ name: "机器人ID",
+ prop: "RobotId",
+ key: "RobotId"
},
{
- title: "创建时间",
- dataIndex: "CreateTime",
- key: "CreateTime",
- },
+ name: "创建时间",
+ prop: "CreateTime",
+ key: "CreateTime"
+ }
];