chunk-1747aa06.d27adabe0e4d37fb8b27.js 21 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-1747aa06"],{1891:function(t,e,r){"use strict";var n=r("5636"),a=r.n(n);a.a},5636:function(t,e,r){},e0c0:function(t,e,r){"use strict";r.r(e);var n=function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",[r("div",{staticClass:"searchForm"},[r("div",{staticClass:"leftFrom"},[r("el-form",{ref:"params",staticClass:"formList",attrs:{model:t.params,"label-width":"100px"}},[r("el-form-item",{attrs:{label:"用户ID"}},[r("el-input",{attrs:{placeholder:"请输入用户ID",onkeyup:"this.value=this.value.replace(/[, ]/g,'')"},model:{value:t.params.member_id,callback:function(e){t.$set(t.params,"member_id","string"===typeof e?e.trim():e)},expression:"params.member_id"}})],1),r("el-form-item",{attrs:{label:"用户名称"}},[r("el-input",{attrs:{placeholder:"请输入用户名称",onkeyup:"this.value=this.value.replace(/[, ]/g,'')"},model:{value:t.params.username,callback:function(e){t.$set(t.params,"username","string"===typeof e?e.trim():e)},expression:"params.username"}})],1),r("el-form-item",{attrs:{label:"订单号"}},[r("el-input",{attrs:{placeholder:"请输入订单号",onkeyup:"this.value=this.value.replace(/[, ]/g,'')"},model:{value:t.params.ordernum,callback:function(e){t.$set(t.params,"ordernum","string"===typeof e?e.trim():e)},expression:"params.ordernum"}})],1),r("el-form-item",{attrs:{label:"币种"}},[r("el-select",{attrs:{clearable:"",placeholder:"请选择币种"},model:{value:t.params.from_coin,callback:function(e){t.$set(t.params,"from_coin",e)},expression:"params.from_coin"}},t._l(t.coinList,(function(t){return r("el-option",{key:t.id,attrs:{label:t.currency,value:t.currency}})})),1)],1),r("el-form-item",{attrs:{label:"请选择时间"}},[r("el-date-picker",{attrs:{type:"datetimerange","value-format":"timestamp","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期","default-time":["00:00:00","23:59:59"]},on:{change:t.changeTime},model:{value:t.timeData,callback:function(e){t.timeData=e},expression:"timeData"}})],1)],1)],1),r("div",{staticClass:"inquire"},[r("el-button",{staticClass:"demand",attrs:{type:"primary"},on:{click:t.inquire}},[t._v("查询")])],1)]),r("div",[r("p",[t._v("客户盈亏总额:"+t._s(t.profitAll)+" USDT")]),r("p",[t._v("总金额(带杠杆):"+t._s(t.amountAll)+" USDT")])]),r("div",{staticClass:"tabs"},[r("div"),r("div",{staticClass:"tabs_btn"},[r("el-button",{staticClass:"greenbg",on:{click:function(e){return t.refresh()}}},[t._v("刷新")])],1)]),r("div",[r("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticStyle:{width:"100%"},attrs:{data:t.tableData,border:"","cell-style":{textAlign:"center"},"header-cell-style":{textAlign:"center"},height:"600"}},[r("el-table-column",{attrs:{prop:"enter_price",label:"订单"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[r("p",[t._v("币种:"+t._s(e.row.from_coin))]),r("p",[t._v("最新价:")]),r("p",{staticStyle:{color:"#409EFF"}},[t._v(t._s(e.row.index_price))]),r("p",[t._v("用户名称:"+t._s(e.row.username))]),r("p",[t._v("订单号:"+t._s(e.row.ordernum))])])]}}])}),r("el-table-column",{attrs:{prop:"mode",label:"模式/杠杆"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[t._v(" "+t._s("1"==e.row.mode?"逐仓":"全仓")+" ")]),r("div",{style:"1"==e.row.long_or_short?"color:#42b983;":"color:#f00;"},[t._v(" "+t._s("1"==e.row.long_or_short?"做多":"做空")+" ")]),r("div",[t._v(" "+t._s(e.row.leverage)+"倍杠杆 ")])]}}])}),r("el-table-column",{attrs:{prop:"margin",label:"保证金(usdt)"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[r("p",[t._v("余额:")]),r("p",[t._v(t._s(e.row.balance))]),r("p",[t._v("持仓保证金:")]),r("p",[t._v(t._s(e.row.margin))]),r("p",[t._v("可用保证金:")]),r("p",[t._v(t._s(e.row.available_balance))])])]}}])}),r("el-table-column",{attrs:{prop:"enter_price",label:"持仓金额/数量(含手续费)"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[r("p",[t._v("持仓均价:")]),r("p",[t._v(t._s(e.row.average_price))]),r("p",[t._v("持仓数量:")]),r("p",[t._v(t._s(e.row.quantity))]),r("p",[t._v("持仓金额:")]),r("p",[t._v(t._s(e.row.amount))])])]}}])}),r("el-table-column",{attrs:{prop:"enter_price",label:"价格"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[r("p",[t._v("开仓价格:")]),r("p",[t._v(t._s(e.row.enter_price))]),r("p",[t._v("平仓价格:")]),r("p",[t._v(t._s(e.row.closing_price))]),r("p",[t._v("止盈价格:")]),r("p",[t._v(t._s(e.row.take_profit_price))]),r("p",[t._v("止损价格:")]),r("p",[t._v(t._s(e.row.stop_loss_price))])])]}}])}),r("el-table-column",{attrs:{prop:"profit",label:"浮动盈亏"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[0==Number(e.row.profit)?r("p",[t._v("盈亏:"+t._s(e.row.profit))]):t._e(),Number(e.row.profit)>0?r("p",[t._v("盈亏:"),r("span",{staticStyle:{color:"#42b983"}},[t._v(t._s(e.row.profit))])]):t._e(),Number(e.row.profit)<0?r("p",[t._v("盈亏:"),r("span",{staticStyle:{color:"#f00"}},[t._v(t._s(e.row.profit))])]):t._e(),0==Number(e.row.profit_rate)?r("p",[t._v("涨跌:"+t._s(e.row.profit_rate)+"%")]):t._e(),Number(e.row.profit_rate)>0?r("p",[t._v("涨跌:"),r("span",{staticStyle:{color:"#42b983"}},[t._v(t._s(e.row.profit_rate)+"%")])]):t._e(),Number(e.row.profit_rate)<0?r("p",[t._v("涨跌:"),r("span",{staticStyle:{color:"#f00"}},[t._v(t._s(e.row.profit_rate)+"%")])]):t._e()])]}}])}),r("el-table-column",{attrs:{prop:"status",label:"状态"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[t._v(" "+t._s("-1"==e.row.status?"已取消":"0"==e.row.status?"待成交":"1"==e.row.status?"持仓":"已平仓")+" ")])]}}])}),r("el-table-column",{attrs:{prop:"is_pending",label:"是否委托中"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[t._v(" "+t._s("-1"==e.row.is_pending?"已取消":"0"==e.row.is_pending?"已经成交":"委托中")+" ")])]}}])}),r("el-table-column",{attrs:{prop:"fee",label:"手续费"}}),r("el-table-column",{attrs:{prop:"end_type",label:"平仓类型"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[t._v(" "+t._s("1"==e.row.end_type?"手动平仓":"2"==e.row.end_type?"强制平仓":"3"==e.row.end_type?"止盈":"4"==e.row.end_type?"止损":"5"==e.row.end_type?"自动平仓":"")+" ")])]}}])}),r("el-table-column",{attrs:{prop:"control_detail",label:"点控"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[r("p",[t._v("类型:"+t._s(1==e.row.control_detail.type?"止盈":2==e.row.control_detail.type?"止损":3==e.row.control_detail.type?"盈利百分比":""))]),3!=e.row.control_detail.type?r("p",[t._v("价格:"+t._s(e.row.control_detail.price))]):r("p",[t._v("百分比:"+t._s(e.row.control_detail.price)+"%")]),r("p",[t._v("执行时间:"+t._s(t.timestampToDatetime(e.row.control_detail.act_time)))])])]}}])}),r("el-table-column",{attrs:{prop:"closing_at",label:"时间"},scopedSlots:t._u([{key:"default",fn:function(e){return[r("div",[r("p",[t._v("平仓时间:"+t._s(t.timestampToDatetime(e.row.closing_at)))]),r("p",[t._v("更新时间:"+t._s(t.timestampToDatetime(e.row.updated_at)))]),r("p",[t._v("创建时间:"+t._s(t.timestampToDatetime(e.row.created_at)))])])]}}])}),r("el-table-column",{attrs:{prop:"employee_name",label:"操作员"}}),r("el-table-column",{attrs:{prop:"closing_at",label:"操作"},scopedSlots:t._u([{key:"default",fn:function(e){return["1"==e.row.is_control&&"1"==e.row.status?r("el-button",{staticClass:"greenbg",on:{click:function(r){return t.pcClick(e.row)}}},[t._v("取消点控")]):r("span",[t._v("-")])]}}])})],1),r("el-dialog",{staticClass:"info-dialog",attrs:{visible:t.pcDialog,width:"600px",title:"取消点控","before-close":t.pcClose},on:{"update:visible":function(e){t.pcDialog=e}}},[r("div",{staticStyle:{"font-size":"20px","text-align":"center"}},[t._v(" 确定取消点控? ")]),r("template",{slot:"footer"},[r("div",{staticClass:"dialog-footer"},[r("el-button",{staticClass:"dialog-cancel-btn",on:{click:t.pcClose}},[t._v("取 消")]),r("el-button",{staticClass:"dialog-confirm-btn",attrs:{type:"primary",loading:t.btnLoading},on:{click:t.sumbitFrom}},[t._v("确 定 ")])],1)])],2),r("Paginate",{attrs:{page:t.params.page,total:t.total},on:{currentChange:t.handleCurrentChange,sizeChange:t.handleSizeChange}})],1)])},a=[],o=r("365c"),u=r("f201"),i=r("0238"),c=r("c466"),l={name:"contractIndex",components:{Paginate:i["a"]},data:function(){return{pickerOptions:{disabledDate:function(t){return t.getTime()<Date.now()-864e5}},amountAll:0,profitAll:0,params:{page:1,page_size:this.$store.state.attr.pageSize,member_id:"",username:"",ordernum:"",from_coin:"",created_at_start:"",created_at_end:""},timeData:[],coinList:[],tableData:[],loading:!1,total:0,btnLoading:!1,pcTypeList:[{id:1,text:"止盈"},{id:2,text:"止亏"},{id:3,text:"盈利百分比"}],pcFrom:{},pcFromData:{id:0,type:"",price:"",act_time:""},pcDialog:!1}},computed:{},watch:{},mounted:function(){this.finstall(),this.install()},methods:{finstall:function(){var t=this;Object(o["bc"])().then((function(e){console.log("icon",e.data.list),t.coinList=e.data.list}))},install:function(){var t=this,e={is_control:1,page:this.cal.accSub(this.params.page,1),page_size:this.params.page_size,member_id:this.params.member_id,username:this.params.username,ordernum:this.params.ordernum,from_coin:this.params.from_coin,created_at_start:this.params.created_at_start,created_at_end:this.params.created_at_end};Object(u["t"])(e).then((function(e){200===e.code?(t.amountAll=e.data.amountAll,t.profitAll=e.data.profitAll,t.total=parseInt(e.data.listTotalCount),t.tableData=e.data.list):t.$message.error(e.message),t.loading=!1}))},refresh:function(){this.tableData=[],this.params.page=1,this.install()},inquire:function(){this.params.page=1,console.log(this.params),this.install()},changeTime:function(t){t?(this.params.created_at_start=t[0]/1e3,this.params.created_at_end=t[1]/1e3):(this.params.created_at_start="",this.params.created_at_end="")},pcClick:function(t){this.pcFrom=t,this.pcDialog=!0},pcType:function(){var t=this.pcFromData.type;this.pcFromData.price=1==t?this.pcFrom.take_profit_price:2==t?this.pcFrom.stop_loss_price:""},pcClose:function(){this.pcDialog=!1},sumbitFrom:function(){var t=this;this.pcFromData.id=this.pcFrom.id;var e=this.pcFromData.id,r={id:e};this.btnLoading=!0,Object(u["P"])(r).then((function(e){200===e.code?(t.$message.success("取消成功"),t.pcDialog=!1,t.tableData=[],t.params.page=1,t.install()):t.$message.error(e.message),t.btnLoading=!1}))},handleCurrentChange:function(t){this.params.page=t,this.install()},handleSizeChange:function(t,e){this.params.page_size=t,this.install()},timestampToDatetime:function(t){return Object(c["a"])(t,!0)}},beforeCreate:function(){},created:function(){},beforeMount:function(){},beforeUpdate:function(){},updated:function(){},beforeDestroy:function(){},destroyed:function(){},activated:function(){}},s=l,d=(r("1891"),r("2877")),p=Object(d["a"])(s,n,a,!1,null,"2153ffc6",null);e["default"]=p.exports},f201:function(t,e,r){"use strict";r.d(e,"U",(function(){return a})),r.d(e,"j",(function(){return o})),r.d(e,"zb",(function(){return u})),r.d(e,"B",(function(){return i})),r.d(e,"k",(function(){return c})),r.d(e,"vb",(function(){return l})),r.d(e,"c",(function(){return s})),r.d(e,"i",(function(){return d})),r.d(e,"f",(function(){return p})),r.d(e,"g",(function(){return m})),r.d(e,"e",(function(){return f})),r.d(e,"h",(function(){return b})),r.d(e,"b",(function(){return _})),r.d(e,"v",(function(){return h})),r.d(e,"u",(function(){return g})),r.d(e,"x",(function(){return v})),r.d(e,"w",(function(){return O})),r.d(e,"y",(function(){return w})),r.d(e,"sb",(function(){return j})),r.d(e,"fb",(function(){return y})),r.d(e,"ob",(function(){return x})),r.d(e,"o",(function(){return k})),r.d(e,"xb",(function(){return S})),r.d(e,"wb",(function(){return T})),r.d(e,"yb",(function(){return D})),r.d(e,"rb",(function(){return C})),r.d(e,"qb",(function(){return P})),r.d(e,"pb",(function(){return F})),r.d(e,"T",(function(){return A})),r.d(e,"tb",(function(){return z})),r.d(e,"R",(function(){return L})),r.d(e,"Q",(function(){return $})),r.d(e,"S",(function(){return N})),r.d(e,"A",(function(){return q})),r.d(e,"z",(function(){return E})),r.d(e,"t",(function(){return I})),r.d(e,"N",(function(){return U})),r.d(e,"P",(function(){return J})),r.d(e,"eb",(function(){return H})),r.d(e,"n",(function(){return M})),r.d(e,"a",(function(){return B})),r.d(e,"l",(function(){return G})),r.d(e,"d",(function(){return K})),r.d(e,"m",(function(){return Q})),r.d(e,"O",(function(){return R})),r.d(e,"ib",(function(){return V})),r.d(e,"nb",(function(){return W})),r.d(e,"jb",(function(){return X})),r.d(e,"lb",(function(){return Y})),r.d(e,"kb",(function(){return Z})),r.d(e,"gb",(function(){return tt})),r.d(e,"mb",(function(){return et})),r.d(e,"hb",(function(){return rt})),r.d(e,"db",(function(){return nt})),r.d(e,"cb",(function(){return at})),r.d(e,"Z",(function(){return ot})),r.d(e,"ab",(function(){return ut})),r.d(e,"bb",(function(){return it})),r.d(e,"H",(function(){return ct})),r.d(e,"D",(function(){return lt})),r.d(e,"C",(function(){return st})),r.d(e,"G",(function(){return dt})),r.d(e,"F",(function(){return pt})),r.d(e,"E",(function(){return mt})),r.d(e,"I",(function(){return ft})),r.d(e,"L",(function(){return bt})),r.d(e,"K",(function(){return _t})),r.d(e,"J",(function(){return ht})),r.d(e,"M",(function(){return gt})),r.d(e,"r",(function(){return vt})),r.d(e,"p",(function(){return Ot})),r.d(e,"s",(function(){return wt})),r.d(e,"q",(function(){return jt})),r.d(e,"V",(function(){return yt})),r.d(e,"Y",(function(){return xt})),r.d(e,"X",(function(){return kt})),r.d(e,"W",(function(){return St})),r.d(e,"ub",(function(){return Tt}));var n=r("b775");function a(t){return Object(n["b"])({url:"/common-dic/update2",method:"POST",data:t})}function o(t){return Object(n["b"])({url:"/withdrawal-net/index",method:"get",params:t})}function u(t){return Object(n["b"])({url:"/withdrawal-net/create",method:"POST",data:t})}function i(t,e){return Object(n["b"])({url:"/withdrawal-net/update",method:"put",params:t,data:e})}function c(t){return Object(n["b"])({url:"/common-dic/index2",method:"get",params:t})}function l(t){return Object(n["b"])({url:"/withdrawal-net/delete",method:"delete",params:t})}function s(t){return Object(n["b"])({url:"/coin/index",method:"get",params:t})}function d(t,e){return Object(n["b"])({url:"/coin/update",method:"put",params:t,data:e})}function p(t){return Object(n["b"])({url:"/coin-recharge-net",method:"get",params:t})}function m(t){return Object(n["b"])({url:"/coin-recharge-net/delete",method:"delete",params:t})}function f(t){return Object(n["b"])({url:"/coin/net",method:"get",params:t})}function b(t){return Object(n["b"])({url:"/coin-recharge-net/create",method:"POST",data:t})}function _(t){return Object(n["b"])({url:"/invite-level/index",method:"get",params:t})}function h(t,e){return Object(n["b"])({url:"/invite-level/update",method:"put",params:t,data:e})}function g(t){return Object(n["b"])({url:"/invite-level/create",method:"POST",data:t})}function v(t){return Object(n["b"])({url:"/invite-profit-static/index",method:"get",params:t})}function O(t){return Object(n["b"])({url:"/invite-profit-static/detail",method:"get",params:t})}function w(t){return Object(n["b"])({url:"/invite-profit-static/profit",method:"get",params:t})}function j(t){return Object(n["b"])({url:"/wallet/transfer-log",method:"get",params:t})}function y(t){return Object(n["b"])({url:"/wallet/transfer-export",method:"get",responseType:"blob",params:t})}function x(t){return Object(n["b"])({url:"/wallet/flash-exchange-log",method:"get",params:t})}function k(t){return Object(n["b"])({url:"/wallet/flash-exchange-export",method:"get",responseType:"blob",params:t})}function S(t){return Object(n["b"])({url:"/withdraw/index",method:"get",params:t})}function T(t){return Object(n["b"])({url:"/withdraw/export",method:"get",responseType:"blob",params:t})}function D(t,e){return Object(n["b"])({url:"/withdraw/update",method:"put",params:t,data:e})}function C(t){return Object(n["b"])({url:"/wallet/operate-log",method:"get",params:t})}function P(t){return Object(n["b"])({url:"/wallet/operate",method:"POST",data:t})}function F(t){return Object(n["b"])({url:"/wallet/modify-wallet-operate-remark",method:"PATCH",data:t})}function A(t){return Object(n["b"])({url:"/wallet/operate-export",method:"get",responseType:"blob",params:t})}function z(t){return Object(n["b"])({url:"/withdraw/abandon",method:"POST",data:t})}function L(t){return Object(n["b"])({url:"/recharge/confirm",method:"POST",data:t})}function $(t){return Object(n["b"])({url:"/recharge/abandon",method:"POST",data:t})}function N(t){return Object(n["b"])({url:"/recharge/export",method:"get",responseType:"blob",params:t})}function q(t){return Object(n["b"])({url:"/invite-profit-static/log",method:"get",params:t})}function E(t){return Object(n["b"])({url:"/invite-profit-static/change-type",method:"get",params:t})}function I(t){return Object(n["b"])({url:"/futures-order/index",method:"get",params:t})}function U(t){return Object(n["b"])({url:"/futures-order/close",method:"POST",data:t})}function J(t){return Object(n["b"])({url:"/futures-order/cancel-close",method:"POST",data:t})}function H(t){return Object(n["b"])({url:"/coin-control/index",method:"get",params:t})}function M(t,e){return Object(n["b"])({url:"/coin-control/update",method:"put",params:t,data:e})}function B(t){return Object(n["b"])({url:"/coin-control/create",method:"post",data:t})}function G(t,e){return Object(n["b"])({url:"/coin-control/delete",method:"DELETE",params:t,data:e})}function K(t){return Object(n["b"])({url:"/coin-control/coin",method:"get",params:t})}function Q(t){return Object(n["b"])({url:"/futures-order/close-fee",method:"get",params:t})}function R(t){return Object(n["b"])({url:"/futures-order/close-all",method:"POST",params:t})}function V(t){return Object(n["b"])({url:"/tutorial/index",method:"get",params:t})}function W(t){return Object(n["b"])({url:"/tutorial-type/index",method:"get",params:t})}function X(t){return Object(n["b"])({url:"/tutorial-type/create",method:"POST",data:t})}function Y(t,e){return Object(n["b"])({url:"/tutorial-type/update",method:"put",params:t,data:e})}function Z(t){return Object(n["b"])({url:"/tutorial-type/delete",method:"delete",params:t})}function tt(t){return Object(n["b"])({url:"/tutorial/create",method:"POST",data:t})}function et(t,e){return Object(n["b"])({url:"/tutorial/update",method:"put",params:t,data:e})}function rt(t){return Object(n["b"])({url:"/tutorial/delete",method:"delete",params:t})}function nt(t){return Object(n["b"])({url:"/task/index",method:"get",params:t})}function at(t,e){return Object(n["b"])({url:"/task/update",method:"put",params:t,data:e})}function ot(t){return Object(n["b"])({url:"/task/create",method:"POST",data:t})}function ut(t){return Object(n["b"])({url:"/task/delete",method:"delete",params:t})}function it(t){return Object(n["b"])({url:"/task-member/index",method:"get",params:t})}function ct(t){return Object(n["b"])({url:"/option-order/index",method:"get",params:t})}function lt(t){return Object(n["b"])({url:"/option-coin/index",method:"get",params:t})}function st(t){return Object(n["b"])({url:"/option-coin/coin",method:"get",params:t})}function dt(t,e){return Object(n["b"])({url:"/option-coin/update",method:"put",params:t,data:e})}function pt(t){return Object(n["b"])({url:"/option-coin/delete",method:"delete",params:t})}function mt(t){return Object(n["b"])({url:"/option-coin/create",method:"post",data:t})}function ft(t){return Object(n["b"])({url:"/option-rule/index",method:"get",params:t})}function bt(t,e){return Object(n["b"])({url:"/option-rule/update",method:"put",params:t,data:e})}function _t(t){return Object(n["b"])({url:"/option-rule/delete",method:"delete",params:t})}function ht(t){return Object(n["b"])({url:"/option-rule/create",method:"post",data:t})}function gt(t){return Object(n["b"])({url:"/option-order/statistics",method:"get"})}function vt(t){return Object(n["b"])({url:"/footer/index",method:"get",params:t})}function Ot(t){return Object(n["b"])({url:"/footer/create",method:"post",data:t})}function wt(t,e){return Object(n["b"])({url:"/footer/update",method:"put",params:t,data:e})}function jt(t){return Object(n["b"])({url:"/footer/delete",method:"delete",params:t})}function yt(t){return Object(n["b"])({url:"/spread-level/index",method:"get",params:t})}function xt(t,e){return Object(n["b"])({url:"/spread-level/update",method:"put",params:t,data:e})}function kt(t){return Object(n["b"])({url:"/spread-level/delete",method:"delete",params:t})}function St(t){return Object(n["b"])({url:"/spread-level/create",method:"post",data:t})}function Tt(t){return Object(n["b"])({url:"/withdraw-account/index",method:"get",params:t})}}}]);