zhangxp
2023-06-07 432bbf252ffc66393ac10e14958a8c412b3e401c
申领单页面只缺一个申领单状态接口
已修改6个文件
已添加1个文件
271 ■■■■ 文件已修改
Source/UBCS-WEB/src/api/integration/application.js 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/UBCS-WEB/src/api/integration/integration.js 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/UBCS-WEB/src/components/transfer/index.vue 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/UBCS-WEB/src/views/integration/applicationForm.vue 146 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/UBCS-WEB/src/views/integration/integrationIndex.vue 78 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/UBCS-WEB/src/views/integration/integrationTransfer.vue 27 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/UBCS-WEB/vue.config.js 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/UBCS-WEB/src/api/integration/application.js
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,10 @@
import request from '@/router/axios';
// ç”³é¢†å•数据
export const getList = (params) => {
    return request({
      url: '/api/ubcs-applyjtcodeservice/DockingPreApplyCode/page',
      method: 'get',
      params: params
    })
  }
Source/UBCS-WEB/src/api/integration/integration.js
@@ -35,7 +35,7 @@
// å±žæ€§æ˜ å°„
export const gridAttrMapping = (params) => {
  return request({
    url: '/api//ubcs-applyjtcodeservice/DockingPreApplyCode/gridAttrMapping',
    url: '/api/ubcs-applyjtcodeservice/DockingPreApplyCode/gridAttrMapping',
    method: 'get',
    params: params
  })
@@ -63,6 +63,6 @@
  return request({
    url: '/api/ubcs-applyjtcodeservice/DockingPreApplyCode/syncClassifyModel',
    method: 'post',
    data: params
    params: params
  })
}
Source/UBCS-WEB/src/components/transfer/index.vue
@@ -128,11 +128,9 @@
        targetData() {
            if (this.targetOrder === 'original') {
                console.log('11111')
                return this.data.filter(item =>  this.value.indexOf(item) > -1
                );
            } else {
                console.log('22222')
                return this.value.reduce((arr, cur) => {
                    const val = this.dataObj[cur];
                    if (val) {
Source/UBCS-WEB/src/views/integration/applicationForm.vue
@@ -0,0 +1,146 @@
<template>
    <basic-container>
        <avue-crud :table-loading="loading" :data="data" :option="option" :search.sync="searchParam" :page.sync="page"
            ref="crud" @refresh-change="getDataList" @search-change="handleSearch" @search-reset="handleReset"
            @size-change="handleSizePage" @current-change="handleCurrentPage" @on-load="getDataList">
            <template slot="menuLeft">
                <el-button icon="el-icon-document" size="small" type="primary" @click="handleStatus">集团申请状态
                </el-button>
            </template>
        </avue-crud>
    </basic-container>
</template>
<script>
import { getList } from '@/api/integration/application.js'
import { dateFormat } from '@/util/date.js'
export default {
    data() {
        return {
            loading: false,
            data: [],
            page: {
                pageSize: 10,
                currentPage: 1,
                total: 0
            },
            searchParam: {},
            option: {
                height: "auto",
                index: true,
                border: true,
                addBtn: false,
                columnBtn: false,
                searchMenuSpan: 8,
                highlightCurrentRow: true,
                menu:false,
                column: [
                    {
                        label: '申请单号',
                        prop: 'id',
                        width: 300,
                        fixed: true,
                        search: true,
                    }, {
                        label: '集团码',
                        width: 200,
                        prop: 'groupCode',
                        search: true,
                    }, {
                        label: '操作类型',
                        width: 200,
                        prop: 'operationType',
                        type: 'select',
                        search: true,
                        dicData: [{
                            label: '申请',
                            value: 1
                        }, {
                            label: '更改',
                            value: 2
                        }]
                    }, {
                        label: '申请单数据信息',
                        width: 300,
                        prop: 'description'
                    },
                    {
                        label: '创建时间',
                        width: 200,
                        prop: 'createTime',
                        type: 'datetime',
                        search: true,
                    },
                    {
                        label: '更改时间',
                        width: 200,
                        prop: 'lastModifyTime',
                        type: 'datetime',
                        search: true,
                        formatter: () => {
                        }
                    }, {
                        label: '返回标识',
                        width: 100,
                        prop: 'code'
                    },
                    {
                        label: '返回信息',
                        width: 300,
                        prop: 'content'
                    },
                    {
                        label: '消息信息',
                        width: 300,
                        prop: 'msg'
                    }
                ]
            }
        }
    },
    methods: {
        handleStatus() {
        },
        async getDataList() {
            this.loading = true
            console.log(this.searchParam)
            const { pageSize, currentPage, total } = this.page
            let param = { size: pageSize, current: currentPage }
            const response = await getList({ ...param, ...this.searchParam })
            if (response.status === 200) {
                this.loading = false
                console.log(response)
                const data = response.data.data
                this.data = data.records
                this.page.total = data.total
            } else this.loading = false
        },
        handleSizePage(event) {
            this.page.pageSize = event
        },
        handleCurrentPage(event) {
            this.page.currentPage = event
        },
        handleReset() {
            this.searchParam = {}
        },
        handleSearch(form, done) {
            const { id, groupCode, operationType } = form
            let dataTime = { id, groupCode, operationType }
            if (form.hasOwnProperty('createTime')) {
                dataTime = { createTime: dateFormat(form.createTime), ...dataTime }
            }
            if (form.hasOwnProperty('lastModifyTime')) {
                dataTime = { lastModifyTime: dateFormat(form.lastModifyTime), ...dataTime }
            }
            console.log(dataTime)
            this.searchParam = dataTime
            this.page.currentPage = 1
            this.getDataList()
            done()
        }
    }
}
</script>
Source/UBCS-WEB/src/views/integration/integrationIndex.vue
@@ -16,7 +16,7 @@
                <el-card>
                    <el-form :model="form">
                        <el-form-item label="集团分类" label-width="70px" size="small">
                            <el-select clearable ref="selectTree" v-model="form.groupValue" placeholder="请选择"
                            <el-select clearable ref="selectTree" v-model="groupVal" placeholder="请选择"
                                popper-class="popperTreeSelect">
                                <el-option :value="groupVal" :label="groupVal">
                                    <el-tree ref="groupTree" :data="groupTreeData" empty-text="暂无数据" :props="defaultProps"
@@ -33,11 +33,16 @@
                            @row-dblclick="handleMapingRowClick" @selection-change="selectionChange" @select="setCurrentRow"
                            @select-all="handleSelectAll">
                            <template slot="menuLeft">
                                <el-button icon="el-icon-plus" size="small" type="primary" :disabled="disabledPush" @click="dialogPush = true">新 å¢ž
                                <el-button icon="el-icon-plus" size="small" type="primary" :disabled="disabledPush"
                                    @click="dialogPush = true">新 å¢ž
                                </el-button>
                                <el-button icon="el-icon-check" size="small" type="primary" @click="handleSave">保 å­˜
                                </el-button>
                                <el-button icon="el-icon-connection" size="small" type="primary" @click="handleSync">同步模型
                                <el-button icon="el-icon-connection" size="small" type="primary"
                                    @click="handleSync('all')">同步主模型
                                </el-button>
                                <el-button icon="el-icon-connection" size="small" type="primary"
                                    @click="handleSync('one')">同步详细模型
                                </el-button>
                            </template>
                        </avue-crud>
@@ -50,23 +55,8 @@
                </el-card>
            </el-main>
        </el-container>
        <!-- <el-dialog title="编码属性" :visible.sync="dialogPush" append-to-body="true" destroy-on-close width="30%"
            :before-close="handleClose">
            <el-form :model="form">
                <el-form-item label="查询条件" label-width="70px" size="small">
                    <el-input v-model="form.name" autocomplete="off" @change="handleQuery"></el-input>
                </el-form-item>
            </el-form>
            <p class="text_tip">*选择分类进行属性过滤, æˆ–者输入属性的全拼或者简拼进行查询! å¦‚: å§“名 (可输入xm或xinming )</p>
            <transfer v-model="transferValue" :data="transferData" :filter-method="filterMethod"
                filter-placeholder="请输入拼音全拼或者拼音缩写" :props="transferProps"></transfer>
            <span slot="footer" class="dialog-footer">
                <el-button @click="dialogPush = false">取 æ¶ˆ</el-button>
                <el-button type="primary" @click="handelTransferSave">保 å­˜</el-button>
            </span>
        </el-dialog> -->
        <integration-transfer :visible.sync="dialogPush" :data="transferData" :props="transferProps"
            @save="handelTransferSave"></integration-transfer>
        <integration-transfer :visible.sync="dialogPush" :data="transferData" :disabledData="filtermapping"
            :props="transferProps" @save="handelTransferSave"></integration-transfer>
    </div>
</template>
<script>
@@ -196,6 +186,17 @@
        window.handleBlur = that.handleBlur
    },
    computed: {
        filtermapping() {
            const data = this.mappingData.filter(item => {
                return !(Object.prototype.hasOwnProperty.call(item, 'targetAttrName') && (item.targetAttrName === null || item.targetAttrName === undefined || item.targetAttrName === ""))
            })
            const transfer = data.map(obj => {
                return obj.targetAttrName
            })
            return transfer
        }
    },
    methods: {
        // æŽ¥å£å·¦ä¾§æ ‘
        async getReferCodeClassifyTree() {
@@ -220,6 +221,7 @@
            if (response.status === 200) {
                this.loading = false
                this.mappingData = response.data.data
                console.log(this.filtermapping)
            }
        },
        // æŽ¥å£èŽ·å–å±žæ€§æ˜ å°„å–å€¼èŒƒå›´
@@ -276,11 +278,25 @@
                    message: "保存成功!"
                });
            }
        },
        // åŒæ­¥æ•°æ®
        async handleSync() {
            const response = await syncClassifyModel({ dockingPreAttrMappingVOList: this.tableData })
        async handleSync(type = 'all') {
            let param = { operationType: type }
            if (type === 'one') {
                param.classifyId = this.form.groupValue
            }
            if (this.form.groupValue === '' && type === 'one') {
                this.$message({
                    type: "error",
                    message: "请选择一条集团分类"
                });
            } else {
                console.log(param)
                const response = await syncClassifyModel(param)
                if (response.status === 200) {
                    console.log(response)
                }
            }
        },
        handelTransferSave(event) {
            let that = this
@@ -295,7 +311,7 @@
                const findRow = that.mappingData.findIndex(item => item.metaListId === that.mappingForm.metaListId)
                that.mappingData[findRow].targetAttrName = transferValue[0].name
                that.mappingData[findRow].targetAttrId = transferValue[0].oid
                this.dialogPush =false
                this.dialogPush = false
            }
        },
@@ -312,7 +328,7 @@
        },
        // é›†å›¢åˆ†ç±»æ ‘点击
        handleNodeClick(data) {
            this.form.groupValue = data.name
            this.form.groupValue = data.oid
            this.groupVal = data.name
            this.$refs.selectTree.blur()
            this.getGridAttrMapping(data.oid)
@@ -328,14 +344,13 @@
            if (event === 'mapping') this.$refs.crudMapping.rowCell(this.mappingForm, this.mappingForm.$index)
        },
        // é›†å›¢æ˜ å°„属性行选择单元格编辑(双击)
        handleMapingRowClick(row, column, cell, event) {
            console.log(row)
        handleMapingRowClick(row, column) {
            clearTimeout(this.times)
            this.mappingForm = row
            if (column.label === '默认值' || column.label === '属性名称') this.$refs.crudMapping.rowCell(row, row.$index)
        },
        // é›†å›¢æ˜ å°„属性行选择(单击)
        handleMapingClick(row, column, cell, event) {
        handleMapingClick(row) {
            clearTimeout(this.times)
            this.mappingForm = row
            this.times = setTimeout(() => {
@@ -343,15 +358,14 @@
            }, 300)
        },
        // å±žæ€§å–值范围单元格编辑(双击)
        handleRowClick(row, column, cell, event) {
        handleRowClick(row) {
            this.rangeForm = row
            this.$refs.crudRange.rowCell(row, row.$index)
        },
        // å±žæ€§å–值范围单元格编辑后
        handleUpdate(row, index, done, loading) {
        handleUpdate(row, index, done) {
            console.log(row)
            console.log(index)
            let data = []
            const findRow = this.mappingData.findIndex(item => item.metaListId === row.metaListId)
            this.rangeData[index] = row
            console.log(this.rangeData)
@@ -365,7 +379,7 @@
            done();
        },
        // å±žæ€§å–值范围单元格编辑后
        handleMapingUpdate(row, index, done, loading) {
        handleMapingUpdate(row, index, done) {
            console.log(row)
            console.log('修改后', row)
            this.$message({
Source/UBCS-WEB/src/views/integration/integrationTransfer.vue
@@ -22,13 +22,14 @@
    components: {
        transfer
    },
    name: 'Integration',
    name: 'IntegrationTransfer',
    props: {
        // æ˜¯å¦æ‰“å¼€
        visible: {
            typeof: Boolean,
            default: false
        },
        // å¼¹çª—标题
        title: {
            typeof: String,
            default: '编码属性'
@@ -48,6 +49,11 @@
                    disabled: 'disabled'
                };
            }
        },
        // å¦‚果有特殊操作,一条数据只能用一次的操作,就需要把禁用的数据字段用lebel对应的值传递过来
        disabledData: {
            typeof: Array,
            default: () => []
        },
        // æŸ¥è¯¢æ–‡æœ¬æ¡†çš„placeholder
        filterPlaceholder: {
@@ -75,14 +81,21 @@
            pinyin.setOptions({ checkPolyphone: false, charCase: 1 });
            let name = this.props.label
            let key = this.props.key
            let objs = this.data.map(item => {
            let data = this.data.map(item => {
                let objitem = { disabled: false, ...item }
                if (this.disabledData.length !== 0) {
                    this.disabledData.forEach(element => {
                        if (objitem[name] === element)  objitem.disabled = true
                    });
                }
                return objitem
            })
            return data.map(item => {
                let pinYin = pinyin.getFullChars(item[this.props.label])
                let renPing = pinyin.getCamelChars(item[this.props.label])
                const obj = { pinyins: pinYin, renPing: renPing, disabled: false, [name]: item[this.props.label], [key]: item[this.props.key] }
                const obj = { pinyins: pinYin, renPing: renPing, [name]: item[this.props.label], [key]: item[this.props.key], disabled: item.disabled }
                return obj
            })
            console.log(objs)
            return objs
        }
    },
    methods: {
@@ -102,8 +115,8 @@
        },
        // ç¡®å®šæŒ‰é’®ï¼Œè¿”回当前数据和修改后的数据
        handelTransferSave() {
            let that =this
            let datas= that.newdata
            let that = this
            let datas = that.newdata
            const findtra = datas.findIndex(item => item.oid === that.transferValue[0].oid)
            datas[findtra].disabled = true
            const obj = {
Source/UBCS-WEB/vue.config.js
@@ -26,11 +26,11 @@
    proxy: {
      '/api': {
        //本地服务接口地址
        target: 'http://localhost:37000',
        // target: 'http://localhost:37000',
        // target: 'http://192.168.1.63:37000',
        //target: 'http://192.168.3.7:37000',
        // target: 'http://dev.vci-tech.com:37000',
        //target: 'http://dev.vci-tech.com:37000',
        target: 'http://dev.vci-tech.com:37000',
        // target: 'http://192.168.1.51:37000/',
        //远程演示服务地址,可用于直接启动项目
        // target: 'https://saber.bladex.vip/api',