1
jhzh
2026-01-09 26e85aa1441ca246970694681ce2ba39e0a68979
1
12 files modified
4 files added
648 ■■■■■ changed files
.env 3 ●●●● patch | view | raw | blame | history
.env.development 3 ●●●● patch | view | raw | blame | history
.env.preview 4 ●●● patch | view | raw | blame | history
.husky/.gitignore 1 ●●●● patch | view | raw | blame | history
admin.rar patch | view | raw | blame | history
debug.log 2 ●●●●● patch | view | raw | blame | history
src/api/newshares.js 8 ●●●● patch | view | raw | blame | history
src/api/position.js 8 ●●●●● patch | view | raw | blame | history
src/config/router.config.js 2 ●●● patch | view | raw | blame | history
src/views/newshares/dazonglist.vue 55 ●●●● patch | view | raw | blame | history
src/views/newshares/newshareslist.vue 16 ●●●●● patch | view | raw | blame | history
src/views/position/components/financing-entrust.vue 488 ●●●●● patch | view | raw | blame | history
src/views/position/components/financing-flat.vue 4 ●●●● patch | view | raw | blame | history
src/views/position/components/financing-hold.vue 15 ●●●● patch | view | raw | blame | history
src/views/position/financing.vue 11 ●●●● patch | view | raw | blame | history
src/views/risksetting/productsetting.vue 28 ●●●● patch | view | raw | blame | history
.env
@@ -3,4 +3,5 @@
#VUE_APP_API_BASE_URL=https://api.zcpzi.com/
#VUE_APP_API_BASE_URL=https://api.stockcardsnow.com/
VUE_APP_API_BASE_URL=http://localhost:8091/
VUE_APP_API_BASE_URL=https://stock101.shengliankeji.top/
# VUE_APP_API_BASE_URL=http://192.168.10.7:8099/
.env.development
@@ -2,4 +2,5 @@
VUE_APP_PREVIEW=true
#VUE_APP_API_BASE_URL=https://api.stockcardsnow.com/
VUE_APP_API_BASE_URL=http://localhost:8091/
# VUE_APP_API_BASE_URL=http://192.168.10.7:8099/
VUE_APP_API_BASE_URL=https://stock101.shengliankeji.top/
.env.preview
@@ -1,3 +1,5 @@
NODE_ENV=production
VUE_APP_PREVIEW=true
VUE_APP_API_BASE_URL=http:localhost:8091
VUE_APP_API_BASE_URL=https://stock101.shengliankeji.top/
# VUE_APP_API_BASE_URL=http://192.168.10.7:8099/
.husky/.gitignore
New file
@@ -0,0 +1 @@
_
admin.rar
Binary files differ
debug.log
New file
@@ -0,0 +1,2 @@
[0106/152115.679:ERROR:third_party\crashpad\crashpad\util\win\registration_protocol_win.cc:108] CreateFile: 系统找不到指定的文件。 (0x2)
[0106/152130.855:ERROR:third_party\crashpad\crashpad\util\win\registration_protocol_win.cc:108] CreateFile: 系统找不到指定的文件。 (0x2)
src/api/newshares.js
@@ -12,10 +12,10 @@
  getStockSubscribeQcListByAdmin: '/admin/subscribe/getStockSubscribeQcListByAdmin.do', // 新股抢筹记录列表
  addStockSubscribeQcByAdmin: '/admin/subscribe/addStockSubscribeQcByAdmin.do', // 新股抢筹记录添加
  updateStockSubscribeQcByAdmin: 'admin/subscribe/updateStockSubscribeQcByAdmin.do', // 新股抢筹记录修改
  getDzListByAdmin:'/admin/stockDz/getDzListByAdmin.do', // 大宗交易列表
  addByAdmin:'/admin/stockDz/addByAdmin.do', // 大宗交易添加
  updateByAdmin:'/admin/stockDz/updateByAdmin.do', // 大宗交易修改
  deleteByAdmin:'/admin/stockDz/deleteByAdmin.do', // 大宗交易删除
  getDzListByAdmin:'/admin/stockDz/getDzListByAdmin.do', // 股东减持列表
  addByAdmin:'/admin/stockDz/addByAdmin.do', // 股东减持添加
  updateByAdmin:'/admin/stockDz/updateByAdmin.do', // 股东减持修改
  deleteByAdmin:'/admin/stockDz/deleteByAdmin.do', // 股东减持删除
}
/**
src/api/position.js
@@ -16,6 +16,7 @@
    userdetail: '/admin/user/detail.do', // 创建融资持仓 单个用户详情搜索
    stockgetSingleStock: '/api/stock/getSingleStock.do', // 创建融资持仓 获取单个股票信息
    positioncreate: '/admin/position/create.do', // 创建融资持仓
    positiontransferPositions: '/admin/position/transferPositions.do', // 委托转持仓
}
/**
@@ -29,6 +30,13 @@
 * @param parameter
 * @returns {*}
 */
export function positiontransferPositions(parameter) {
    return request({
        url: userApi.positiontransferPositions,
        method: 'post',
        data: qs.stringify(parameter),
    })
}
export function positionlist(parameter) {
    return request({
        url: userApi.positionlist,
src/config/router.config.js
@@ -202,7 +202,7 @@
            path: '/newshares/dazonglist',
            name: 'dazonglist',
            component: () => import('@/views/newshares/dazonglist'),
            meta: { title: '大宗交易列表', keepAlive: true, permission: ['dazonglist'] }
            meta: { title: '股东减持列表', keepAlive: true, permission: ['dazonglist'] }
          },
        ]
      },
src/views/newshares/dazonglist.vue
@@ -19,7 +19,7 @@
                                    </a-button>
                                    <a-button type="primary" icon="plus" style="margin-left: 8px"
                                        @click="addUserdialog = true, currentdetail = ''">
                                        添加大宗交易</a-button>
                                        添加股东减持</a-button>
                                </span>
                            </a-form-item>
                        </a-col>
@@ -48,18 +48,26 @@
                        </div>
                    </template>
                </span>
                <span slot="isShow" slot-scope="text,record">
                    <template>
                        <div>
                            <a-tag :color="record.isShow == 0 ? 'red' : record.isShow == 1 ? 'green' : ''">
                                {{ record.isShow == 0 ? '隐藏' : '显示' }}
                            </a-tag>
                        </div>
                    </template>
                </span>
                <template slot="action" slot-scope="text,record">
                    <a slot="action" href="javascript:;" @click="geteditStock(record)">{{ '修改大宗交易' }}</a>
                    <a slot="action" href="javascript:;" @click="geteditStock(record)">{{ '修改股东减持' }}</a>
                    <a-divider type="vertical" />
                    <a slot="action" href="javascript:;" @click="getdeleteStock(record)">{{ '删除大宗交易' }}</a>
                    <a slot="action" href="javascript:;" @click="getdeleteStock(record)">{{ '删除股东减持' }}</a>
                    <a-divider type="vertical" />
                </template>
            </a-table>
        </a-card>
        <a-modal :title="currentdetail ? '修改大宗交易' : '添加大宗交易'" :width="700" :visible="addUserdialog"
        <a-modal :title="currentdetail ? '修改股东减持' : '添加股东减持'" :width="700" :visible="addUserdialog"
            :confirmLoading="addUserDialogloading" @ok="OkaddUserdialog" @cancel="CanceladdUserdialog">
            <a-form :form="addUserform" ref="addUserform">
                <a-row :gutter="48">
@@ -77,10 +85,19 @@
                    </a-col>
                </a-row>
                <a-row :gutter="48">
                    <a-col :md="12" :lg="12" :sm="12">
                    <!-- <a-col :md="12" :lg="12" :sm="12">
                        <a-form-item label="交易密钥" :labelCol="labelCol" :wrapperCol="wrapperCol">
                            <a-input placeholder="请输入交易密钥"
                                v-decorator="['password', { rules: [{ required: true, message: '请输入交易密钥', }] }]" />
                        </a-form-item>
                    </a-col> -->
                    <a-col :md="12" :lg="12" :sm="12">
                        <a-form-item label="显示状态" :labelCol="labelCol" :wrapperCol="wrapperCol">
                            <a-select placeholder="请选择显示状态"
                                v-decorator="['isShow', { rules: [{ required: true, message: '请选择显示状态', }] }]">
                                <a-select-option :value="0">隐藏</a-select-option>
                                <a-select-option :value="1">显示</a-select-option>
                            </a-select>
                        </a-form-item>
                    </a-col>
                    <a-col :md="12" :lg="12" :sm="12">
@@ -107,6 +124,15 @@
                           </a-date-picker>
                       </a-form-item>
                   </a-col>
               </a-row>
               <a-row :gutter="48">
                   <a-col :md="12" :lg="12" :sm="12">
                       <a-form-item label="份额" :labelCol="labelCol" :wrapperCol="wrapperCol">
                            <a-input placeholder="请输入份额"
                                v-decorator="['stockShare', { rules: [{ required: true, message: '请输入份额', }] }]" />
                        </a-form-item>
                   </a-col>
               </a-row>
            </a-form>
        </a-modal>
@@ -148,6 +174,17 @@
                    scopedSlots: { customRender: 'stockType' },
                },
                {
                    title: '份额',
                    dataIndex: 'stockShare',
                    align: "center",
                },
                {
                    title: '是否显示',
                    dataIndex: 'isShow',
                    align: "center",
                    scopedSlots: { customRender: 'isShow' },
                },
                {
                    title: '开始时间',
                    dataIndex: 'startTime',
                    align: "center",
@@ -186,6 +223,8 @@
                pageNum: 1,
                pageSize: 10,
                keywords: '',
                isShow: undefined,
                stockShare:'',
            },
            datalist: [],
            labelCol: {
@@ -201,7 +240,7 @@
            addUserform: this.$form.createForm(this),
            addUserdialog: false,
            addUserDialogloading: false,
            fields: ['stockCode', 'stockNum', 'password', 'startTime','endTime','discount'],
            fields: ['stockCode', 'stockNum', 'password','isShow','stockShare', 'startTime','endTime','discount'],
            currentdetail: '',
            startTime: '',
            endTime: '',
@@ -296,6 +335,8 @@
                pageNum: 1,
                pageSize: 10,
                keywords: '',
                stockShare:'',
                isShow: undefined,
            }
        },
        getinit() {
src/views/newshares/newshareslist.vue
@@ -179,6 +179,12 @@
                            </a-date-picker>
                        </a-form-item>
                    </a-col>
                    <a-col :md="12" :lg="12" :sm="12">
                        <a-form-item label="折扣" :labelCol="labelCol" :wrapperCol="wrapperCol">
                            <a-input placeholder="请输入折扣"
                                v-decorator="['discount', { rules: [{ required: true, message: '请输入折扣', }] }]" />
                        </a-form-item>
                    </a-col>
                </a-row>
            </a-form>
        </a-modal>
@@ -259,6 +265,14 @@
                    }
                },
                {
                    title: '折扣',
                    dataIndex: 'discount',
                    align: "center",
                    customRender: (text, row, index) => {
                        return text ? text.toFixed(2) : '0.00'
                    }
                },
                {
                    title: '操作',
                    key: 'action',
                    align: "center",
@@ -300,7 +314,7 @@
            addUserdialog: false,
            addUserDialogloading: false,
            fields: ['name', 'code', 'price', 'orderNumber', 'zt', 'subscribeTime', 'subscriptionTime', 'stockType', 'code','listDate'],
            fields: ['name', 'code', 'price', 'orderNumber', 'discount', 'zt', 'subscribeTime', 'subscriptionTime', 'stockType', 'code','listDate'],
            currentdetail: '',
            subscribeTime: '',
            subscriptionTime: '',
src/views/position/components/financing-entrust.vue
New file
@@ -0,0 +1,488 @@
<template>
    <div>
        <a-card :bordered="false">
            <div class="table-page-search-wrapper">
                <a-form layout="inline">
                    <a-row :gutter="48">
                        <a-col :md="12" :lg="6" :sm="24">
                            <a-form-item label="持仓类型">
                                <a-select v-model="queryParam.positionType" placeholder="请选择持仓类型">
                                    <a-select-option :value="''">全部</a-select-option>
                                    <a-select-option :value="0">正式持仓</a-select-option>
                                    <a-select-option :value="1">模拟持仓</a-select-option>
                                </a-select>
                            </a-form-item>
                        </a-col>
                        <a-col :md="12" :lg="6" :sm="24">
                            <a-form-item label="下级代理">
                                <a-select v-model="queryParam.agentId" placeholder="请选择下级代理" @focus="getagentlist"
                                    :loading="agentloading">
                                    <a-select-option v-for="(item, index) in agentlist" :key="index" :value="item.id">
                                        {{ item.agentName }}
                                    </a-select-option>
                                </a-select>
                            </a-form-item>
                        </a-col>
                        <a-col :md="12" :lg="6" :sm="24">
                            <a-form-item label="用户Id">
                                <a-input v-model="queryParam.userId" style="width: 100%" placeholder="请输入用户Id" />
                            </a-form-item>
                        </a-col>
                        <a-col :md="12" :lg="6" :sm="24">
                            <a-form-item label="持仓订单号">
                                <a-input v-model="queryParam.positionSn" style="width: 100%" placeholder="请输入持仓订单号" />
                            </a-form-item>
                        </a-col>
                    </a-row>
                    <a-row :gutter="48">
                        <a-col :md="12" :lg="6" :sm="24">
                            <a-form-item>
                                <span class="table-page-search-submitButtons">
                                    <a-button @click="getqueryParam" icon="redo">
                                        重置</a-button>
                                    <a-button type="primary" icon="search" style="margin-left: 8px"
                                        @click="queryParam.pageNum = 1, getlist()">查询
                                    </a-button>
                                </span>
                            </a-form-item>
                        </a-col>
                    </a-row>
                </a-form>
            </div>
        </a-card>
        <a-card :bordered="false" style="margin-top: 16px;">
            <a-button type="primary" @click="batchTransferPositions" :disabled="selectedRowKeys.length === 0">
                批量转持仓
            </a-button>
        </a-card>
        <a-table bordered :loading="loading" :pagination="pagination" :columns="columns" :data-source="datalist"
            rowKey="id" :scroll="{ x: 2800 }" :rowSelection="rowSelection">
            <span slot="stockName" slot-scope="text,record">
                <template>
                    <div>
                        <span style="margin-right:10px">{{ record.stockName }}</span>
                        <a-tag
                            :color="record.stockPlate == '科创' ? 'blue' : !record.stockPlate ? 'orange' : record.stockPlate == '创业' ? 'pink' : 'purple'">
                            {{ record.stockPlate == '科创' ? '科创' : !record.stockPlate ? '股票' : record.stockPlate }}
                        </a-tag>
                        <p>({{ record.stockCode }})</p>
                    </div>
                </template>
            </span>
            <span slot="positionType" slot-scope="text,record">
                <template>
                    <div>
                        <a-tag :color="record.positionType == 1 ? 'blue' : 'green'">
                            {{ record.positionType == 1 ? '模拟持仓' : '正式持仓' }}
                        </a-tag>
                    </div>
                </template>
            </span>
            <span slot="orderDirection" slot-scope="text,record">
                <template>
                    <div>
                        <a-tag :color="record.orderDirection == '买涨' ? 'red' : 'green'">
                            {{ record.orderDirection }}
                        </a-tag>
                    </div>
                </template>
            </span>
            <span slot="now_price" slot-scope="text,record">
                <template>
                    <div>
                        <p
                            :class="Number(record.now_price) - record.buyOrderPrice < 0 ? 'greens' : Number(record.now_price) - record.buyOrderPrice > 0 ? 'reds' : ''">
                            {{ record.now_price }}
                        </p>
                    </div>
                </template>
            </span>
            <span slot="profitAndLose" slot-scope="text">
                <template>
                    <div>
                        <p :class="text < 0 ? 'greens' : text > 0 ? 'reds' : ''">
                            {{ text }}
                        </p>
                    </div>
                </template>
            </span>
            <span slot="allProfitAndLose" slot-scope="text">
                <template>
                    <div>
                        <p :class="text < 0 ? 'greens' : text > 0 ? 'reds' : ''">
                            {{ text }}
                        </p>
                    </div>
                </template>
            </span>
            <template slot="action" slot-scope="text,record">
                <a slot="action" href="javascript:;" @click="getCompulsoryclosing(record.id)">转持仓</a>
            </template>
        </a-table>
        <a-modal title="锁仓" :width="640" :visible="Lockvisibledialog" :confirmLoading="Lockvisibleloading"
            @ok="getDialogok" @cancel="handleCancel">
            <a-form :form="Lockvisibleform" ref="createModal">
                <a-form-item>
                    <a-input
                        v-decorator="['lockMsg', { rules: [{ required: true, message: '请输入锁仓原因!', whitespace: true }] }]"
                        placeholder="请输入锁仓原因!" />
                </a-form-item>
            </a-form>
        </a-modal>
    </div>
</template>
<script>
import { positionlist, positionlock, positionsell,positiontransferPositions } from '@/api/position'
import { nextagent } from '@/api/home'
import moment from 'moment'
export default {
    name: 'financinghold',
    data() {
        return {
            columns: [
                {
                    title: '融资名称',
                    dataIndex: 'stockName',
                    align: "center",
                    width: 180,
                    scopedSlots: { customRender: 'stockName' },
                },
                {
                    title: '账户类型',
                    dataIndex: 'positionType',
                    align: "center",
                    scopedSlots: { customRender: 'positionType' },
                },
                {
                    title: '用户名称(ID)',
                    dataIndex: 'nickName',
                    align: "center",
                    customRender: (text, row, index) => {
                        return `${row.nickName}(${row.userId})`
                    }
                },
                {
                    title: '持仓订单号(ID)',
                    dataIndex: 'positionSn',
                    align: "center",
                    customRender: (text, row, index) => {
                        return `${row.positionSn}(${row.id})`
                    }
                },
                {
                    title: '买卖方向',
                    dataIndex: 'orderDirection',
                    align: "center",
                    scopedSlots: { customRender: 'orderDirection' },
                },
                {
                    title: '买入价',
                    dataIndex: 'buyOrderPrice',
                    align: "center",
                    customRender: (text, row, index) => {
                        return text.toFixed(2)
                    }
                },
                // {
                //     title: '现价',
                //     dataIndex: 'now_price',
                //     align: "center",
                //     scopedSlots: { customRender: 'now_price' },
                // },
                // {
                //     title: '浮动盈亏',
                //     dataIndex: 'profitAndLose',
                //     align: "center",
                //     scopedSlots: { customRender: 'profitAndLose' },
                // },
                // {
                //     title: '总盈亏',
                //     dataIndex: 'allProfitAndLose',
                //     align: "center",
                //     scopedSlots: { customRender: 'allProfitAndLose' },
                // },
                {
                    title: '数量(股)',
                    dataIndex: 'orderNum',
                    align: "center",
                },
                {
                    title: '总市值',
                    dataIndex: 'orderTotalPrice',
                    align: "center",
                },
                {
                    title: '杠杆倍数',
                    dataIndex: 'orderLever',
                    align: "center",
                },
                {
                    title: '手续费',
                    dataIndex: 'orderFee',
                    align: "center",
                },
                {
                    title: '印花税',
                    dataIndex: 'orderSpread',
                    align: "center",
                },
                {
                    title: '留仓费',
                    dataIndex: 'orderStayFee',
                    align: "center",
                },
                {
                    title: '留仓天数',
                    dataIndex: 'orderStayDays',
                    align: "center",
                },
                // {
                //     title: '锁定原因',
                //     dataIndex: 'lockMsg',
                //     align: "center",
                // },
                {
                    title: '买入时间',
                    dataIndex: 'buyOrderTime',
                    align: "center",
                    width: 180,
                    customRender: (text, row, index) => {
                        return text ? moment(text).format('YYYY-MM-DD HH:mm:ss') : ''
                    }
                },
                {
                    title: '操作',
                    key: 'action',
                    align: "center",
                    fixed: 'right',
                    width: 150,
                    scopedSlots: { customRender: 'action' },
                },
            ],
            //表头
            pagination: {
                total: 0,
                pageSize: 10,//每页中显示10条数据
                showSizeChanger: true,
                pageSizeOptions: ["10", "20", "50", "100"],//每页中显示的数据
                onShowSizeChange: (current, pageSize) => this.onSizeChange(current, pageSize), // 改变每页数量时更新显示
                onChange: (page, pageSize) => this.onPageChange(page, pageSize),//点击页码事件
                showTotal: total => `共有 ${total} 条数据`,  //分页中显示总的数据
            },
            loading: false,
            queryParam: {
                pageNum: 1,
                pageSize: 10,
                positionType: '',
                agentId: undefined,
                userId: '',
                positionSn: '',
                state: 0,
            },
            datalist: [],
            agentlist: [],
            agentloading: false,
            Lockvisibledialog: false,
            Lockvisibleloading: false,
            Lockvisibleform: this.$form.createForm(this),
            clickpositionId: '',
            agentqueryParam: {
                pageNum: 1,
                pageSize: 100,
            },
            selectedRowKeys: [],
        }
    },
    computed: {
        rowSelection() {
            return {
                selectedRowKeys: this.selectedRowKeys,
                onChange: (selectedRowKeys) => {
                    this.selectedRowKeys = selectedRowKeys
                },
            }
        }
    },
    created() {
        this.getlist()
    },
    methods: {
        getCompulsoryclosing(val) {
            var that = this
            this.$confirm({
                title: '提示',
                content: '确认要转持仓吗?',
                onOk() {
                    var data = {
                        positionId: val,
                    }
                    positiontransferPositions(data).then(res => {
                        if (res.status == 0) {
                            that.$message.success({ content: res.msg, duration: 2 });
                            // 从选中列表中移除已转持仓的id
                            that.selectedRowKeys = that.selectedRowKeys.filter(id => id !== val)
                            that.getlist()
                        } else {
                            that.$message.error({ content: '转持仓失败' });
                        }
                    }).catch(error => {
                        that.$message.error({ content: '转持仓失败' });
                    })
                },
                onCancel() {
                    console.log('Cancel');
                },
            });
        },
        batchTransferPositions() {
            if (this.selectedRowKeys.length === 0) {
                this.$message.warning('请至少选择一条记录');
                return;
            }
            var that = this
            this.$confirm({
                title: '提示',
                content: `确认要批量转持仓吗? 共${this.selectedRowKeys.length}条记录`,
                onOk() {
                    var data = {
                        positionId: that.selectedRowKeys.join(','),
                    }
                    positiontransferPositions(data).then(res => {
                        if (res.status == 0) {
                            that.$message.success({ content: res.msg, duration: 2 });
                            that.selectedRowKeys = []
                            that.getlist()
                        } else {
                            that.$message.error({ content: '批量转持仓失败' });
                        }
                    }).catch(error => {
                        that.$message.error({ content: '批量转持仓失败' });
                    })
                },
                onCancel() {
                    console.log('Cancel');
                },
            });
        },
        getLockopen(val) {
            var that = this
            this.$confirm({
                title: '提示',
                content: '确认要解锁该持仓单?',
                onOk() {
                    var data = {
                        state: 0,
                        positionId: val,
                    }
                    positionlock(data).then(res => {
                        if (res.status == 0) {
                            that.$message.success({ content: res.msg, duration: 2 });
                            that.getlist()
                        } else {
                            that.$message.error({ content: res.msg });
                        }
                    })
                },
                onCancel() {
                    console.log('Cancel');
                },
            });
        },
        handleCancel() {
            this.Lockvisibledialog = false
            const form = this.$refs.createModal.form
            form.resetFields()
        },
        getDialogok() {
            const form = this.$refs.createModal.form
            form.validateFields((errors, values) => {
                if (!errors) {
                    this.Lockvisibleloading = true
                    var data = {
                        state: 1,
                        lockMsg: values.lockMsg,
                        positionId: this.clickpositionId,
                    }
                    positionlock(data).then(res => {
                        if (res.status == 0) {
                            this.Lockvisibledialog = false
                            this.$message.success({ content: res.msg, duration: 2 });
                            form.resetFields()
                            this.getlist()
                        } else {
                            this.$message.error({ content: res.msg });
                        }
                        this.Lockvisibleloading = false
                    }).catch(error => {
                        reject(error)
                    })
                }
            })
        },
        getinit() {
            this.queryParam = {
                pageNum: 1,
                pageSize: 10,
                positionType: '',
                agentId: undefined,
                userId: '',
                positionSn: '',
                state: 0,
            }
            this.getlist()
        },
        getqueryParam() {
            this.queryParam = {
                pageNum: 1,
                pageSize: 10,
                positionType: '',
                agentId: undefined,
                userId: '',
                positionSn: '',
                state: 0,
            }
        },
        getagentlist() {
            var that = this;
            this.agentloading = true
            nextagent(this.agentqueryParam).then(res => {
                this.agentlist = res.data.list
                setTimeout(() => {
                    that.agentloading = false
                }, 500);
            })
        },
        getlist() {
            this.loading = true
            positionlist(this.queryParam).then(res => {
                this.datalist = res.data.list
                this.pagination.total = res.data.total
                this.loading = false
            })
        },
        onPageChange(page, pageSize) {
            this.queryParam.pageNum = page
            this.getlist()
        },
        onSizeChange(current, pageSize) {
            this.queryParam.pageNum = current
            this.queryParam.pageSize = pageSize
            this.getlist()
        },
    }
}
</script>
<style scoped>
.greens {
    color: #52c41a;
}
.reds {
    color: #f5222d;
}
</style>
src/views/position/components/financing-flat.vue
@@ -442,7 +442,7 @@
                agentId: undefined,
                userId: '',
                positionSn: '',
                state: 1,
                state: 2,
                beginTime: '',
                endTime: '',
            }
@@ -461,7 +461,7 @@
                agentId: undefined,
                userId: '',
                positionSn: '',
                state: 1,
                state: 2,
                beginTime: '',
                endTime: '',
            }
src/views/position/components/financing-hold.vue
@@ -124,10 +124,18 @@
        <a-modal title="锁仓" :width="640" :visible="Lockvisibledialog" :confirmLoading="Lockvisibleloading"
            @ok="getDialogok" @cancel="handleCancel">
            <a-form :form="Lockvisibleform" ref="createModal">
                <a-form-item>
                <a-form-item label="锁仓原因">
                    <a-input
                        v-decorator="['lockMsg', { rules: [{ required: true, message: '请输入锁仓原因!', whitespace: true }] }]"
                        placeholder="请输入锁仓原因!" />
                </a-form-item>
                <a-form-item label="锁仓天数">
                    <a-input-number
                        v-decorator="['lockDays', { rules: [{ required: true, message: '请输入锁仓天数!' }] }]"
                        placeholder="请输入锁仓天数"
                        :min="1"
                        :precision="0"
                        style="width: 100%" />
                </a-form-item>
            </a-form>
        </a-modal>
@@ -362,6 +370,7 @@
                    var data = {
                        state: 1,
                        lockMsg: values.lockMsg,
                        lockDays: values.lockDays,
                        positionId: this.clickpositionId,
                    }
                    positionlock(data).then(res => {
@@ -388,7 +397,7 @@
                agentId: undefined,
                userId: '',
                positionSn: '',
                state: 0,
                state: 1,
            }
            this.getlist()
        },
@@ -400,7 +409,7 @@
                agentId: undefined,
                userId: '',
                positionSn: '',
                state: 0,
                state: 1,
            }
        },
        getagentlist() {
src/views/position/financing.vue
@@ -8,18 +8,21 @@
                <a-tab-pane key="2" tab="股票平仓单" forceRender>
                    <financingFlat ref="financingFlats"></financingFlat>
                </a-tab-pane>
                <a-tab-pane key="3" tab="指数持仓单" forceRender>
                <!-- <a-tab-pane key="3" tab="指数持仓单" forceRender>
                    <indexHold ref="indexHold"></indexHold>
                </a-tab-pane>
                <a-tab-pane key="4" tab="指数平仓单" forceRender>
                    <indexFlat ref="indexFlat"></indexFlat>
                </a-tab-pane>
                </a-tab-pane> -->
                <!-- <a-tab-pane key="5" tab="期货持仓单" forceRender>
                    <futuresHold ref="futuresHold"></futuresHold>
                </a-tab-pane>
                <a-tab-pane key="6" tab="期货平仓单" forceRender>
                    <futuresFlat ref="futuresFlat"></futuresFlat>
                </a-tab-pane> -->
                <a-tab-pane key="7" tab="股票委托单" forceRender>
                    <financingEntrust ref="financingEntrust"></financingEntrust>
                </a-tab-pane>
            </a-tabs>
        </a-card>
    </page-header-wrapper>
@@ -28,6 +31,7 @@
<script>
import financingHold from './components/financing-hold'
import financingFlat from './components/financing-flat'
import financingEntrust from './components/financing-entrust'
import indexHold from './components/index-hold'
import indexFlat from './components/index-flat'
import futuresHold from './components/futures-hold'
@@ -37,6 +41,7 @@
    components: {
        financingHold,
        financingFlat,
        financingEntrust,
        indexHold,
        indexFlat,
        futuresHold,
@@ -59,7 +64,7 @@
            } else if (val == 5) {
                this.$refs.futuresHold.getinit()
            } else if (val == 6) {
                this.$refs.futuresFlat.getinit()
                this.$refs.financingEntrust.getinit()
            }
        }
    }
src/views/risksetting/productsetting.vue
@@ -4,30 +4,46 @@
            <a-card class="card" title="A股" :bordered="false" :loading="loading">
                <span slot="extra">状态为开启即表示用户可以进行该产品的交易</span>
                <a-row class="form-row" :gutter="48">
                    <a-col :md="8" :lg="8" :sm="12">
                    <!-- <a-col :md="8" :lg="8" :sm="12">
                        <a-form-item label="融资融券交易" :labelCol="labelCol" :wrapperCol="wrapperCol">
                            <a-switch v-decorator="['stockDisplay', { valuePropName: 'checked' }]">
                                <a-icon slot="checkedChildren" type="check" />
                                <a-icon slot="unCheckedChildren" type="close" />
                            </a-switch>
                        </a-form-item>
                    </a-col>
                    <a-col :md="8" :lg="8" :sm="12">
                    </a-col> -->
                    <!-- <a-col :md="8" :lg="8" :sm="12">
                        <a-form-item label="科创板交易" :labelCol="labelCol" :wrapperCol="wrapperCol">
                            <a-switch v-decorator="['kcStockDisplay', { valuePropName: 'checked' }]">
                                <a-icon slot="checkedChildren" type="check" />
                                <a-icon slot="unCheckedChildren" type="close" />
                            </a-switch>
                        </a-form-item>
                    </a-col>
                    <a-col :md="8" :lg="8" :sm="12">
                    </a-col> -->
                    <!-- <a-col :md="8" :lg="8" :sm="12">
                        <a-form-item label="指数交易" :labelCol="labelCol" :wrapperCol="wrapperCol">
                            <a-switch v-decorator="['indexDisplay', { valuePropName: 'checked' }]">
                                <a-icon slot="checkedChildren" type="check" />
                                <a-icon slot="unCheckedChildren" type="close" />
                            </a-switch>
                        </a-form-item>
                    </a-col> -->
                    <a-col :md="8" :lg="8" :sm="12">
                        <a-form-item label="交易提现" :labelCol="labelCol" :wrapperCol="wrapperCol">
                            <a-switch v-decorator="['tranWithdrawDisplay', { valuePropName: 'checked' }]">
                                <a-icon slot="checkedChildren" type="check" />
                                <a-icon slot="unCheckedChildren" type="close" />
                            </a-switch>
                        </a-form-item>
                    </a-col>
                    <!-- <a-col :md="8" :lg="8" :sm="12">
                        <a-form-item label="股东持减" :labelCol="labelCol" :wrapperCol="wrapperCol">
                            <a-switch v-decorator="['stockDzDisplay', { valuePropName: 'checked' }]">
                                <a-icon slot="checkedChildren" type="check" />
                                <a-icon slot="unCheckedChildren" type="close" />
                            </a-switch>
                        </a-form-item>
                    </a-col> -->
                </a-row>
            </a-card>
            <!-- <a-card class="card" title="期货" :bordered="false" :loading="loading"> -->
@@ -125,7 +141,7 @@
        return {
            addUserform: this.$form.createForm(this),
            loading: false,
            fields: ['stockDisplay', 'kcStockDisplay', 'indexDisplay', 'futuresDisplay', 'realNameDisplay', 'fundsDisplay', 'delayDisplay', 'expandDisplay', 'marginDisplay', 'endDisplay',],
            fields: ['stockDisplay', 'kcStockDisplay', 'indexDisplay', 'futuresDisplay', 'realNameDisplay', 'fundsDisplay', 'delayDisplay', 'expandDisplay', 'marginDisplay', 'endDisplay', 'tranWithdrawDisplay', 'stockDzDisplay'],
            labelCol: {
                xs: { span: 10 },
                sm: { span: 10 },