|
@@ -293,7 +293,7 @@ window.SPEC_DATA = (function () {
|
|
|
{ label: "用户ID", type: "input", ph: "精确搜索" }, { label: "手机号", type: "input", ph: "精确搜索" }, { label: "委托编号", type: "input", ph: "精确搜索" },
|
|
{ label: "用户ID", type: "input", ph: "精确搜索" }, { label: "手机号", type: "input", ph: "精确搜索" }, { label: "委托编号", type: "input", ph: "精确搜索" },
|
|
|
{ label: "账户", type: "input", ph: "模糊搜索" }, { label: "用户名称", type: "input", ph: "模糊搜索" }, { label: "股票代码/名称", type: "input", ph: "模糊搜索" },
|
|
{ label: "账户", type: "input", ph: "模糊搜索" }, { label: "用户名称", type: "input", ph: "模糊搜索" }, { label: "股票代码/名称", type: "input", ph: "模糊搜索" },
|
|
|
{ label: "委托状态", type: "select", ph: "全部", multiple: true }, { label: "下单类型", type: "select", ph: "全部" }, { label: "下单方式", type: "select", ph: "全部" },
|
|
{ label: "委托状态", type: "select", ph: "全部", multiple: true }, { label: "下单类型", type: "select", ph: "全部" }, { label: "下单方式", type: "select", ph: "全部" },
|
|
|
- { label: "委托日期", type: "daterange", value: ["2026-09-25", "2026-09-25"], sep: "至" },
|
|
|
|
|
|
|
+ { label: "委托日期", type: "daterange", ph: ["起始", "结束"], sep: "至" }, // 前端没有默认日期,显示占位
|
|
|
];
|
|
];
|
|
|
const trsActions = [["查找", "primary", "search"], ["重置", "", "refresh"], ["导出", "", "download"]];
|
|
const trsActions = [["查找", "primary", "search"], ["重置", "", "refresh"], ["导出", "", "download"]];
|
|
|
|
|
|
|
@@ -350,29 +350,32 @@ window.SPEC_DATA = (function () {
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
- // 委托查询表格列(trs/order/index.vue)。align 为代码现状;group 为激进套的分组
|
|
|
|
|
|
|
+ // 委托查询表格列(trs/order/index.vue,2026-10-16 按前端现状回改):列序按原型(用户 4 列 → 股票代码 → 股票名称 → 交易渠道 → …),
|
|
|
|
|
+ // w 取列上的建议宽度;align 为前端现状(文字列居中、数字列右对齐、备注左对齐,原型口径);group 为激进套的分组
|
|
|
|
|
+ const ctr = "center";
|
|
|
const trsColumns = [
|
|
const trsColumns = [
|
|
|
- { key: "uid", title: "用户ID", w: 90, group: "用户" }, { key: "acct", title: "账户", w: 120, group: "用户" },
|
|
|
|
|
- { key: "uname", title: "用户名称", w: 110, group: "用户" }, { key: "phone", title: "手机号", w: 120, group: "用户" },
|
|
|
|
|
- { key: "channel", title: "交易渠道", w: 100, tag: "trade_channel", group: "委托" },
|
|
|
|
|
- { key: "code", title: "股票代码", w: 100, group: "委托" }, { key: "sname", title: "股票名称", w: 110, group: "委托" },
|
|
|
|
|
- { key: "dir", title: "委托方向", w: 90, tag: "direction", group: "委托" }, { key: "ptype", title: "报价方式", w: 90, tag: "price_req_type", group: "委托" },
|
|
|
|
|
- { key: "status", title: "委托状态", w: 180, tag: "trs_order_status", group: "委托" },
|
|
|
|
|
|
|
+ { key: "uid", title: "用户ID", w: 90, align: ctr, group: "用户" }, { key: "acct", title: "账户", w: 120, align: ctr, group: "用户" },
|
|
|
|
|
+ { key: "uname", title: "用户名称", w: 110, align: ctr, group: "用户" }, { key: "phone", title: "手机号", w: 130, align: ctr, group: "用户" },
|
|
|
|
|
+ { key: "code", title: "股票代码", w: 100, align: ctr, group: "委托" }, { key: "sname", title: "股票名称", w: 110, align: ctr, group: "委托" },
|
|
|
|
|
+ { key: "channel", title: "交易渠道", w: 100, align: ctr, tag: "trade_channel", group: "委托" },
|
|
|
|
|
+ { key: "dir", title: "委托方向", w: 90, align: ctr, tag: "direction", group: "委托" }, { key: "ptype", title: "报价方式", w: 90, align: ctr, tag: "price_req_type", group: "委托" },
|
|
|
|
|
+ { key: "status", title: "委托状态", w: 180, align: ctr, tag: "trs_order_status", group: "委托" },
|
|
|
{ key: "qty", title: "委托数量", w: 110, num: true, group: "委托" }, { key: "price", title: "委托价格", w: 100, num: true, group: "委托" },
|
|
{ key: "qty", title: "委托数量", w: 110, num: true, group: "委托" }, { key: "price", title: "委托价格", w: 100, num: true, group: "委托" },
|
|
|
- { key: "otime", title: "委托时间", w: 160, group: "委托" },
|
|
|
|
|
|
|
+ { key: "otime", title: "委托时间", w: 185, align: ctr, group: "委托" },
|
|
|
{ key: "fqty", title: "成交数量", w: 110, num: true, group: "成交" }, { key: "fprice", title: "成交价格", w: 100, num: true, group: "成交" },
|
|
{ key: "fqty", title: "成交数量", w: 110, num: true, group: "成交" }, { key: "fprice", title: "成交价格", w: 100, num: true, group: "成交" },
|
|
|
- { key: "ccy", title: "交易币种", w: 90, group: "成交" }, { key: "famt", title: "成交金额", w: 130, num: true, group: "成交" },
|
|
|
|
|
- { key: "ftime", title: "成交时间", w: 160, group: "成交" },
|
|
|
|
|
|
|
+ { key: "ccy", title: "交易币种", w: 90, align: ctr, group: "成交" }, { key: "famt", title: "成交金额", w: 140, num: true, group: "成交" },
|
|
|
|
|
+ { key: "ftime", title: "成交时间", w: 185, align: ctr, group: "成交" },
|
|
|
{ key: "comm", title: "佣金", w: 100, num: true, group: "费用" }, { key: "stamp", title: "印花税", w: 100, num: true, group: "费用" },
|
|
{ key: "comm", title: "佣金", w: 100, num: true, group: "费用" }, { key: "stamp", title: "印花税", w: 100, num: true, group: "费用" },
|
|
|
{ key: "fee", title: "规费", w: 100, num: true, group: "费用" }, { key: "total", title: "交易总费用", w: 110, num: true, group: "费用" },
|
|
{ key: "fee", title: "规费", w: 100, num: true, group: "费用" }, { key: "total", title: "交易总费用", w: 110, num: true, group: "费用" },
|
|
|
- { key: "amt", title: "发生金额(交易币种)", w: 170, num: true, group: "结算" }, { key: "sccy", title: "结算币种", w: 90, group: "结算" },
|
|
|
|
|
|
|
+ { key: "amt", title: "发生金额(交易币种)", w: 170, num: true, group: "结算" }, { key: "sccy", title: "结算币种", w: 90, align: ctr, group: "结算" },
|
|
|
{ key: "samt", title: "发生金额(结算币种)", w: 170, num: true, group: "结算" },
|
|
{ key: "samt", title: "发生金额(结算币种)", w: 170, num: true, group: "结算" },
|
|
|
- { key: "no", title: "委托编号", w: 200, group: "来源" }, { key: "operator", title: "操作方", w: 120, group: "来源" },
|
|
|
|
|
- { key: "otype", title: "下单类型", w: 100, tag: "order_type", group: "来源" }, { key: "omode", title: "下单方式", w: 100, tag: "order_mode", group: "来源" },
|
|
|
|
|
- { key: "ip", title: "IP", w: 130, group: "来源" }, { key: "lbs", title: "LBS", w: 130, group: "来源" },
|
|
|
|
|
- { key: "vpn", title: "是否用VPN", w: 100, group: "来源" }, { key: "remark", title: "备注", w: 140, group: "来源" },
|
|
|
|
|
|
|
+ { key: "no", title: "委托编号", w: 200, align: ctr, group: "来源" }, { key: "operator", title: "操作方", w: 120, align: ctr, group: "来源" },
|
|
|
|
|
+ { key: "otype", title: "下单类型", w: 100, align: ctr, tag: "order_type", group: "来源" }, { key: "omode", title: "下单方式", w: 100, align: ctr, tag: "order_mode", group: "来源" },
|
|
|
|
|
+ { key: "ip", title: "IP", w: 150, align: ctr, group: "来源" }, { key: "lbs", title: "LBS", w: 130, align: ctr, group: "来源" },
|
|
|
|
|
+ { key: "vpn", title: "是否用VPN", w: 100, align: ctr, group: "来源" }, { key: "remark", title: "备注", w: 140, group: "来源" },
|
|
|
];
|
|
];
|
|
|
// [用户, 渠道, 股票, 方向, 报价, 状态, 数量, 价格, 成交数量, 成交价, 下单类型, 下单方式, 子单数]
|
|
// [用户, 渠道, 股票, 方向, 报价, 状态, 数量, 价格, 成交数量, 成交价, 下单类型, 下单方式, 子单数]
|
|
|
|
|
+ // 子单数 0 = 单通道单(2026-10-16 起后端用主单补一条通道子行,子单编号同主单);2 = 卖出跨通道拆单(子单编号带 -1/-2)
|
|
|
const trsPlan = [
|
|
const trsPlan = [
|
|
|
[0, "QFII", 0, "买入", "限价", "已报", 2000, 11.62, 0, 0, "正常下单", "iOS", 0],
|
|
[0, "QFII", 0, "买入", "限价", "已报", 2000, 11.62, 0, 0, "正常下单", "iOS", 0],
|
|
|
[1, "QFII", 1, "卖出", "限价", "已成", 2000, 245.2, 2000, 245.18, "后台下单", "CRM", 2],
|
|
[1, "QFII", 1, "卖出", "限价", "已成", 2000, 245.2, 2000, 245.18, "后台下单", "CRM", 2],
|
|
@@ -387,24 +390,28 @@ window.SPEC_DATA = (function () {
|
|
|
];
|
|
];
|
|
|
const trsUsers = [["10021", "ceshi1", "李四测"], ["10034", "zhangmy", "张明远"], ["10058", "wangzh", "王子豪"], ["10077", "chensy", "陈思雨"], ["10092", "liujg", "刘建国"], ["10105", "zhaoyl", "赵雅琳"]];
|
|
const trsUsers = [["10021", "ceshi1", "李四测"], ["10034", "zhangmy", "张明远"], ["10058", "wangzh", "王子豪"], ["10077", "chensy", "陈思雨"], ["10092", "liujg", "刘建国"], ["10105", "zhaoyl", "赵雅琳"]];
|
|
|
const trsStocks = [["000007", "全新好"], ["300750", "宁德时代"], ["600519", "贵州茅台"], ["601318", "中国平安"], ["600036", "招商银行"], ["601899", "紫金矿业"], ["688981", "中芯国际"], ["000333", "美的集团"], ["601012", "隆基绿能"], ["002594", "比亚迪"]];
|
|
const trsStocks = [["000007", "全新好"], ["300750", "宁德时代"], ["600519", "贵州茅台"], ["601318", "中国平安"], ["600036", "招商银行"], ["601899", "紫金矿业"], ["688981", "中芯国际"], ["000333", "美的集团"], ["601012", "隆基绿能"], ["002594", "比亚迪"]];
|
|
|
|
|
+ const trsRoutes = ["VIL001", "CMSI-QFII", "HTSC-01"]; // 通道账户名,子单行写「子单 N · 通道名」
|
|
|
const trsRows = [];
|
|
const trsRows = [];
|
|
|
trsPlan.forEach((p, i) => {
|
|
trsPlan.forEach((p, i) => {
|
|
|
const u = trsUsers[p[0]], s = trsStocks[p[2]], t = ["10:42:16", "10:15:03", "09:48:51", "09:41:27", "09:38:02", "09:35:44", "09:33:10", "09:31:58", "09:31:05", "09:30:12"][i];
|
|
const u = trsUsers[p[0]], s = trsStocks[p[2]], t = ["10:42:16", "10:15:03", "09:48:51", "09:41:27", "09:38:02", "09:35:44", "09:33:10", "09:31:58", "09:31:05", "09:30:12"][i];
|
|
|
|
|
+ const split = p[12] > 1, n = split ? p[12] : 1; // 子单笔数:拆单按计划,单通道单也有 1 条
|
|
|
|
|
+ const no = "T20260925" + String(431 - i * 9).padStart(5, "0");
|
|
|
const famt = p[8] * p[9], comm = famt * 0.0003, stamp = p[3] === "卖出" ? famt * 0.0005 : 0, fee = famt * 0.0000687, total = comm + stamp + fee;
|
|
const famt = p[8] * p[9], comm = famt * 0.0003, stamp = p[3] === "卖出" ? famt * 0.0005 : 0, fee = famt * 0.0000687, total = comm + stamp + fee;
|
|
|
const amt = famt ? (p[3] === "买入" ? -(famt + total) : famt - total) : 0;
|
|
const amt = famt ? (p[3] === "买入" ? -(famt + total) : famt - total) : 0;
|
|
|
|
|
+ // 母单级字段(交易币种、结算币种、操作方、下单类型、下单方式、IP、LBS、VPN、备注)子单留空,和前端一致
|
|
|
const mk = (sub, qty, fq) => ({
|
|
const mk = (sub, qty, fq) => ({
|
|
|
- sub, kids: sub ? 0 : p[12], uid: u[0], acct: u[1], uname: u[2], phone: "1380000" + String(1001 + p[0]), channel: sub === 2 ? (p[1] === "QFII" ? "深沪港通" : "QFII") : p[1],
|
|
|
|
|
|
|
+ sub, kids: sub ? 0 : n, parent: sub ? no : "", uid: u[0], acct: u[1], uname: u[2], phone: "1380000" + String(1001 + p[0]), channel: sub === 2 ? (p[1] === "QFII" ? "深沪港通" : "QFII") : p[1],
|
|
|
code: s[0], sname: s[1], dir: p[3], ptype: p[4], status: p[5], qty: fmt(qty, 0), price: fmt(p[7]), otime: "2026-09-25 " + t,
|
|
code: s[0], sname: s[1], dir: p[3], ptype: p[4], status: p[5], qty: fmt(qty, 0), price: fmt(p[7]), otime: "2026-09-25 " + t,
|
|
|
- fqty: fmt(fq, 0), fprice: fq ? fmt(p[9]) : "--", ccy: "CNY", famt: fq ? fmt(fq * p[9]) : "--", ftime: fq ? "2026-09-25 " + t.slice(0, 6) + "59" : "--",
|
|
|
|
|
|
|
+ fqty: fmt(fq, 0), fprice: fq ? fmt(p[9]) : "--", ccy: sub ? "" : "CNY", famt: fq ? fmt(fq * p[9]) : "--", ftime: fq ? "2026-09-25 " + t.slice(0, 6) + "59" : "--",
|
|
|
comm: fq ? fmt(comm * fq / (p[8] || 1)) : "--", stamp: fq ? fmt(stamp * fq / (p[8] || 1)) : "--", fee: fq ? fmt(fee * fq / (p[8] || 1)) : "--", total: fq ? fmt(total * fq / (p[8] || 1)) : "--",
|
|
comm: fq ? fmt(comm * fq / (p[8] || 1)) : "--", stamp: fq ? fmt(stamp * fq / (p[8] || 1)) : "--", fee: fq ? fmt(fee * fq / (p[8] || 1)) : "--", total: fq ? fmt(total * fq / (p[8] || 1)) : "--",
|
|
|
amt: fq ? fmt(amt * fq / (p[8] || 1)) : "--", sccy: sub ? "" : "HKD", samt: fq ? fmt(amt * fq / (p[8] || 1) * 1.0944) : "--",
|
|
amt: fq ? fmt(amt * fq / (p[8] || 1)) : "--", sccy: sub ? "" : "HKD", samt: fq ? fmt(amt * fq / (p[8] || 1) * 1.0944) : "--",
|
|
|
- no: "T20260925" + String(431 - i * 9).padStart(5, "0") + (sub ? "-" + sub : ""), operator: sub ? "" : p[10] === "正常下单" ? "--" : "admin",
|
|
|
|
|
|
|
+ no: split && sub ? no + "-" + sub : no, operator: sub ? "" : p[10] === "正常下单" ? "--" : "admin",
|
|
|
otype: sub ? "" : p[10], omode: sub ? "" : p[11], ip: "203.0.113." + (20 + i), lbs: ["上海", "深圳", "香港", "北京"][i % 4], vpn: i === 3 ? "是" : "否",
|
|
otype: sub ? "" : p[10], omode: sub ? "" : p[11], ip: "203.0.113." + (20 + i), lbs: ["上海", "深圳", "香港", "北京"][i % 4], vpn: i === 3 ? "是" : "否",
|
|
|
- remark: p[5] === "废单" ? "超出持仓可卖数量" : "", route: sub ? ["VIL001", "CMSI-QFII", "HTSC-01"][sub - 1] : "", // 子单(卖出跨通道拆单)的通道账户名
|
|
|
|
|
- cancel: p[5] === "待撤" ? ["撤单结果未知", "danger", "上轮撤单未取得明确结果,可人工再次撤单"] : null,
|
|
|
|
|
|
|
+ remark: !sub && p[5] === "废单" ? "超出持仓可卖数量" : "", route: sub ? (split ? trsRoutes[sub - 1] : trsRoutes[i % 3]) : "", // 子单的通道账户名
|
|
|
|
|
+ cancel: p[5] === "待撤" ? ["撤单结果未知", "danger", "上轮撤单未取得明确结果,可人工再次撤单"] : null, // 委托状态格下叠的撤单结果(OrderStatusCell)
|
|
|
});
|
|
});
|
|
|
trsRows.push(mk(0, p[6], p[8]));
|
|
trsRows.push(mk(0, p[6], p[8]));
|
|
|
- for (let k = 1; k <= p[12]; k++) trsRows.push(mk(k, p[6] / p[12], p[8] / p[12]));
|
|
|
|
|
|
|
+ for (let k = 1; k <= n; k++) trsRows.push(mk(k, p[6] / n, p[8] / n));
|
|
|
});
|
|
});
|
|
|
|
|
|
|
|
/* ---------- 销售端 · 订单管理(sales/order/components/OrderSearchForm.vue、OrderTable.vue,management 模式) ---------- */
|
|
/* ---------- 销售端 · 订单管理(sales/order/components/OrderSearchForm.vue、OrderTable.vue,management 模式) ---------- */
|