鲁班七号
2023-07-22 369886d399783734d07fb617f074b2e74a773f2e
关于批发出口的打证支持。
已修改1个文件
349 ■■■■■ 文件已修改
src/views/license/licenseInfo/index.vue 349 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/license/licenseInfo/index.vue
@@ -5,34 +5,19 @@
                <div class="basic_search" style="display:inline-block">
                    <span>区域:</span>
                    <el-select v-model="params.province" clearable filterable @change="changeArea('province')">
                        <el-option
                            v-for="item in provinceList"
                            :key="item.id"
                            :label="item.name"
                            :value="item.name"
                        >
                        <el-option v-for="item in provinceList" :key="item.id" :label="item.name" :value="item.name">
                        </el-option>
                    </el-select>
                </div>
                <div class="basic_search" style="display:inline-block">
                    <el-select v-model="params.city" prop="city" clearable filterable @change="changeArea('city')">
                        <el-option
                            v-for="item in cityList"
                            :key="item.id"
                            :label="item.name"
                            :value="item.name"
                        >
                        <el-option v-for="item in cityList" :key="item.id" :label="item.name" :value="item.name">
                        </el-option>
                    </el-select>
                </div>
                <div class="basic_search" style="display:inline-block">
                    <el-select v-model="params.district" clearable filterable>
                        <el-option
                            v-for="item in districtList"
                            :key="item.id"
                            :label="item.name"
                            :value="item.name"
                        >
                        <el-option v-for="item in districtList" :key="item.id" :label="item.name" :value="item.name">
                        </el-option>
                    </el-select>
                </div>
@@ -41,26 +26,14 @@
            <div style="margin-bottom: 10px">
                <div class="basic_search" style="display:inline-block">
                    <span>创建时间:</span>
                    <el-date-picker
                        value-format="yyyy-MM-dd HH:mm:ss"
                        v-model="validTime1"
                        type="datetimerange"
                        range-separator="-"
                        start-placeholder="开始日期"
                        end-placeholder="结束日期"
                    >
                    <el-date-picker value-format="yyyy-MM-dd HH:mm:ss" v-model="validTime1" type="datetimerange"
                        range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期">
                    </el-date-picker>
                </div>
                <div class="basic_search" style="display:inline-block">
                    <span>发证时间:</span>
                    <el-date-picker
                        value-format="yyyy-MM-dd HH:mm:ss"
                        v-model="validTime2"
                        type="datetimerange"
                        range-separator="-"
                        start-placeholder="开始日期"
                        end-placeholder="结束日期"
                    >
                    <el-date-picker value-format="yyyy-MM-dd HH:mm:ss" v-model="validTime2" type="datetimerange"
                        range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期">
                    </el-date-picker>
                </div>
            </div>
@@ -80,36 +53,22 @@
            <div class="carrier_search">
                <span>审核状态:</span>
                <el-select filterable clearable v-model="params.reviewstatus">
                    <el-option
                        v-for="item in reviewStatusList"
                        :key="item.id"
                        :label="item.name"
                        :value="item.id"
                    />
                    <el-option v-for="item in reviewStatusList" :key="item.id" :label="item.name" :value="item.id" />
                </el-select>
            </div>
            <div style="margin-top: 10px;">
                <span>许可证状态:</span>
                <el-select filterable clearable v-model="params.validstatus">
                    <el-option
                        v-for="item in validStatusList"
                        :key="item.id"
                        :label="item.name"
                        :value="item.id"
                    />
                    <el-option v-for="item in validStatusList" :key="item.id" :label="item.name" :value="item.id" />
                </el-select>
                <span>发证类型:</span>
                <el-select filterable clearable v-model="params.licensecode">
                    <el-option
                        v-for="item in licenseStatusList"
                        :key="item.id"
                        :label="item.name"
                        :value="item.id"
                    />
                    <el-option v-for="item in licenseStatusList" :key="item.id" :label="item.name" :value="item.id" />
                </el-select>
                <el-button  style="margin-left: 10px;" type="primary" v-if="isSupervision!=='null'"  @click="openLicenseForm('新增','')">添加</el-button>
                <el-button style="margin-left: 10px;" type="primary" v-if="isSupervision!=='null'"
                    @click="openLicenseForm('新增','')">添加</el-button>
                <el-button  style="margin-left: 10px;" type="primary"  @click="searchData()">查询</el-button>
                <el-button  style="margin-left: 10px;" type="primary"  @click="exportRetail()">零售许可证台账导出</el-button>
                <el-button  style="margin-left: 10px;" type="primary"  @click="exportWholesale()">批发许可证台账导出</el-button>
@@ -117,16 +76,8 @@
        </div>
        <div class="table_content">
            <el-table
                v-loading="listLoading"
                :key="tableKey"
                :data="licenseList"
                border
                fit
                @sort-change="sortChange"
                highlight-current-row
                style="width: 100%;"
            >
            <el-table v-loading="listLoading" :key="tableKey" :data="licenseList" border fit @sort-change="sortChange"
                highlight-current-row style="width: 100%;">
                <el-table-column label="序号" type="index" align="center" width="60"/>
                <el-table-column label="行政区划" prop="province" align="center"  sortable="custom">
                    <template slot-scope="scope">
@@ -176,37 +127,40 @@
                </el-table-column>
                <el-table-column label="操作" align="center" width="180" class-name="small-padding fixed-width">
                    <template slot-scope="scope">
                        <el-button  type="text" @click="commit(scope.row.id)" v-if="isSupervision!=='null' && (scope.row.reviewstatus== 0||scope.row.reviewstatus===3) ?true:false">提交</el-button>
                        <el-button type="text" @click="openLicenseForm('修改',scope.row)" v-if="isSupervision==='null'?false:true">修改</el-button>
                        <el-button type="text" @click="openLicenseForm('审核',scope.row)" v-if="isSupervision ==='null' &&scope.row.reviewstatus !==2&&scope.row.reviewstatus !==3">审核</el-button>
                        <el-button type="text" @click="refuse(scope.row.id)" v-if="isSupervision ==='null'&&scope.row.reviewstatus !==3">驳回</el-button>
                        <el-button  type="text" @click="deleteById(scope.row.id)" v-if="isSupervision==='null'?false:true">删除</el-button>
                        <br><el-button  type="text" v-print="printObj1" @click="giveData(scope.row)"  v-if="isSupervision==='null' && scope.row.reviewstatus === 2?true:false">打印正本(新)</el-button>
                        <el-button  type="text" v-print="printObj2"  @click="giveDetail(scope.row)" v-if="isSupervision==='null' && scope.row.reviewstatus === 2?true:false">打印副本(新)</el-button>
                        <el-button  type="text" v-print="printObj3" @click="giveData(scope.row)"  v-if="isSupervision==='null' && scope.row.reviewstatus === 2?true:false">打印正本(旧)</el-button>
                        <el-button  type="text" v-print="printObj4"  @click="giveDetail(scope.row)" v-if="isSupervision==='null' && scope.row.reviewstatus === 2?true:false">打印副本(旧)</el-button>
                        <el-button type="text" @click="commit(scope.row.id)"
                            v-if="isSupervision!=='null' && (scope.row.reviewstatus== 0||scope.row.reviewstatus===3) ?true:false">提交</el-button>
                        <el-button type="text" @click="openLicenseForm('修改',scope.row)"
                            v-if="isSupervision==='null'?false:true">修改</el-button>
                        <el-button type="text" @click="openLicenseForm('审核',scope.row)"
                            v-if="isSupervision ==='null' &&scope.row.reviewstatus !==2&&scope.row.reviewstatus !==3">审核</el-button>
                        <el-button type="text" @click="refuse(scope.row.id)"
                            v-if="isSupervision ==='null'&&scope.row.reviewstatus !==3">驳回</el-button>
                        <el-button type="text" @click="deleteById(scope.row.id)"
                            v-if="isSupervision==='null'?false:true">删除</el-button>
                        <br><el-button type="text" v-print="printObj1" @click="giveData(scope.row)"
                            v-if="isSupervision==='null' && scope.row.reviewstatus === 2?true:false">打印正本(新)</el-button>
                        <el-button type="text" v-print="printObj2" @click="giveDetail(scope.row)"
                            v-if="isSupervision==='null' && scope.row.reviewstatus === 2?true:false">打印副本(新)</el-button>
                        <el-button type="text" v-print="printObj3" @click="giveData(scope.row)"
                            v-if="isSupervision==='null' && scope.row.reviewstatus === 2?true:false">打印正本(旧)</el-button>
                        <el-button type="text" v-print="printObj4" @click="giveDetail(scope.row)"
                            v-if="isSupervision==='null' && scope.row.reviewstatus === 2?true:false">打印副本(旧)</el-button>
                    </template>
                </el-table-column>
                <el-table-column label="其他操作" v-if="isSupervision === 'null'" align="center" width="180" class-name="small-padding fixed-width">
                <el-table-column label="其他操作" v-if="isSupervision === 'null'" align="center" width="180"
                    class-name="small-padding fixed-width">
                    <template slot-scope="scope">
                        <el-button  type="text" v-if="scope.row.reviewstatus === 2" @click="openDelayLicenseDialog(scope.row)">延期</el-button>
                        <el-button  type="text" v-if="scope.row.reviewstatus === 2" @click="openModLicenseDialog(scope.row)">变更</el-button>
                        <el-button type="text" v-if="scope.row.reviewstatus === 2"
                            @click="openDelayLicenseDialog(scope.row)">延期</el-button>
                        <el-button type="text" v-if="scope.row.reviewstatus === 2"
                            @click="openModLicenseDialog(scope.row)">变更</el-button>
                    </template>
                </el-table-column>
            </el-table>
            <br>
            <el-pagination
                v-show="recordTotal>0"
                :current-page="currentPage"
                :page-sizes="[10, 20, 30, 50]"
                :page-size="pageSize"
                :total="recordTotal"
                layout="total, sizes, prev, pager, next, jumper"
                background
                style="float:right;"
                @size-change="handleSizeChange"
                @current-change="handleCurrentChange"
            />
            <el-pagination v-show="recordTotal>0" :current-page="currentPage" :page-sizes="[10, 20, 30, 50]"
                :page-size="pageSize" :total="recordTotal" layout="total, sizes, prev, pager, next, jumper" background
                style="float:right;" @size-change="handleSizeChange" @current-change="handleCurrentChange" />
            <br>
        </div>
        <div v-show="false">
@@ -219,7 +173,8 @@
                        <span style="display: inline-block;font-size: 20px;">&nbsp;&nbsp;{{code}}</span>
                    </el-col>
                    <el-col :span="6">
                        <div style="width: 40%;height: 40%;margin-left:65px;padding-top: 35px" id="qrcode" ref="qrcode"></div>
                        <div style="width: 40%;height: 40%;margin-left:65px;padding-top: 35px" id="qrcode" ref="qrcode">
                        </div>
                    </el-col>
                </el-row>
                <el-row style="text-align: center;height:35px;font-size: 20px;margin-top:70px">
@@ -254,7 +209,8 @@
                        <span v-if="type === 3">主要负责人</span>
                    </el-col>
                    <el-col :span="11"  style="font-size: 27px">
                        <span v-if="type === 2">{{province === "新疆维吾尔自治区"? "新疆":province}}{{city}}{{district}}{{address}}</span>
                        <span
                            v-if="type === 2">{{province === "新疆维吾尔自治区"? "新疆":province}}{{city}}{{district}}{{address}}</span>
                        <span v-if="type === 3">{{mainpersonname}}</span>
                    </el-col>
                    <el-col :span="3" style="font-size: 27px;font-weight: bold">
@@ -275,8 +231,10 @@
                        <span v-if="type === 3">单位地址</span>
                    </el-col>
                    <el-col :span="11"  style="font-size: 27px">
                        <span v-if="type === 2">{{storageprovince === "新疆维吾尔自治区"? "新疆":storageprovince}}{{storagecity}}{{storagedistrict}}{{storageaddress}}</span>
                        <span v-if="type === 3">{{province === "新疆维吾尔自治区"? "新疆":province}}{{city}}{{district}}{{address}}</span>
                        <span
                            v-if="type === 2">{{storageprovince === "新疆维吾尔自治区"? "新疆":storageprovince}}{{storagecity}}{{storagedistrict}}{{storageaddress}}</span>
                        <span
                            v-if="type === 3">{{province === "新疆维吾尔自治区"? "新疆":province}}{{city}}{{district}}{{address}}</span>
                    </el-col>
                    <el-col :span="3" style="font-size: 27px;font-weight: bold">
                        <span v-if="type === 2">库房面积</span>
@@ -385,7 +343,8 @@
                                <span v-if="type === 3">主要负责人</span>
                            </el-col>
                            <el-col :span="18">
                                <span v-if="type === 2">{{province === "新疆维吾尔自治区"? "新疆":province}}{{city}}{{district}}{{address}}</span>
                                <span
                                    v-if="type === 2">{{province === "新疆维吾尔自治区"? "新疆":province}}{{city}}{{district}}{{address}}</span>
                                <span v-if="type === 3">{{mainpersonname}}</span>
                            </el-col>
                        </el-row>
@@ -396,8 +355,10 @@
                                <span v-if="type === 3">单位地址</span>
                            </el-col>
                            <el-col :span="18">
                                <span v-if="type === 2">{{province === "新疆维吾尔自治区"? "新疆":province}}{{city}}{{district}}{{storageaddress}}</span>
                                <span v-if="type === 3">{{province === "新疆维吾尔自治区"? "新疆":province}}{{city}}{{district}}{{address}}</span>
                                <span
                                    v-if="type === 2">{{province === "新疆维吾尔自治区"? "新疆":province}}{{city}}{{district}}{{storageaddress}}</span>
                                <span
                                    v-if="type === 3">{{province === "新疆维吾尔自治区"? "新疆":province}}{{city}}{{district}}{{address}}</span>
                            </el-col>
                        </el-row>
                        <el-row style="height: 60px;margin-top: 4px">
@@ -444,7 +405,8 @@
                                </el-row>
                            </el-col>
                            <el-col :span="10">
                                <div style="width:20px;height:20px;margin-top: 14px;margin-left: 28px" class="qrcode" id="qrcode2" ref="qrcode"></div>
                                <div style="width:20px;height:20px;margin-top: 14px;margin-left: 28px" class="qrcode"
                                    id="qrcode2" ref="qrcode"></div>
                            </el-col>
                        </el-row>
@@ -524,7 +486,8 @@
                        <span style="display: inline-block;font-size: 25px;"></span>
                    </el-col>
                    <el-col :span="6">
                        <div style="width: 40%;height: 40%;margin-left:20%;padding-top: 10px" id="qrcode3" ref="qrcode"/>
                        <div style="width: 40%;height: 40%;margin-left:20%;padding-top: 10px" id="qrcode3"
                            ref="qrcode" />
                    </el-col>
                </el-row>
                <el-row style="height:50px;font-size: 20px;margin-top:280px;margin-left:1050px;">
@@ -701,12 +664,7 @@
                </el-row>
            </div>
        </div>
        <el-dialog
            :visible.sync="refuseVisible"
            append-to-body
            :close-on-click-modal="false"
            width="30%"
        >
        <el-dialog :visible.sync="refuseVisible" append-to-body :close-on-click-modal="false" width="30%">
            <el-form ref="refuseForm" :model="refuseForm" label-position="right" label-width="80px" >
                <el-form-item label="驳回理由:" prop="name">
                    <el-input type="textarea" :rows="2" v-model="refuseForm.rejectnote"/>
@@ -723,18 +681,35 @@
</template>
<script>
import licenseInfoForm from "./components/licenseInfoForm";
import { computePageCount } from '@/utils'
import {getLicenseList ,getExportLicense,reviewLicenseInfo ,deleteById} from "@/api/license";
    import {
        computePageCount
    } from '@/utils'
    import {
        getLicenseList,
        getExportLicense,
        reviewLicenseInfo,
        deleteById
    } from "@/api/license";
import Cookies from "js-cookie";
import LicenseInfoForm from "./components/licenseInfoForm";
import {deleteCertificate} from "../../../api/tranportList";
import {parseError} from "../../../utils/messageDialog";
import {getCityListData, getProvinceListData , } from "@/api/area";
    import {
        deleteCertificate
    } from "../../../api/tranportList";
    import {
        parseError
    } from "../../../utils/messageDialog";
    import {
        getCityListData,
        getProvinceListData,
    } from "@/api/area";
import QRCode from "qrcodejs2";
import {formatDateDay} from "../../../utils";
import {refuseLicense} from "../../../api/license";
    import {
        formatDateDay
    } from "../../../utils";
    import {
        refuseLicense
    } from "../../../api/license";
import LicenseDelayForm  from "./components/licenseDelayForm"
import LicenseModForm  from "./components/licenseModForm"
@@ -833,34 +808,79 @@
            },
            searchContent:'',
            licenseList:[],
            reviewStatusList:[
                {id:0,name:'等待提交'},
                {id:1,name:'等待审核'},
                {id:2,name:'审核通过'},
                {id:3,name:'审核驳回'},
                reviewStatusList: [{
                        id: 0,
                        name: '等待提交'
                    },
                    {
                        id: 1,
                        name: '等待审核'
                    },
                    {
                        id: 2,
                        name: '审核通过'
                    },
                    {
                        id: 3,
                        name: '审核驳回'
                    },
            ],
          licenseStatusList:[
            {id:'NEW',name:'新发'},
            {id:'POSTP',name:'延期'},
            {id:'MOD',name:'变更'},
                licenseStatusList: [{
                        id: 'NEW',
                        name: '新发'
                    },
                    {
                        id: 'POSTP',
                        name: '延期'
                    },
                    {
                        id: 'MOD',
                        name: '变更'
                    },
          ],
          validStatusList:[
            {id:-1,name:'已注销'},
            {id:1,name:'有效'},
                validStatusList: [{
                        id: -1,
                        name: '已注销'
                    },
                    {
                        id: 1,
                        name: '有效'
                    },
          ],
            typeList:[
                {id:1,name:'烟花爆竹经营(生产)许可证'},
                {id:2,name:'烟花爆竹经营(批发)许可证'},
                {id:3,name:'烟花爆竹经营(长期零售)许可证'},
                {id:4,name:'烟花爆竹经营(短期零售)许可证'}
                typeList: [{
                        id: 1,
                        name: '烟花爆竹经营(生产)许可证'
                    },
                    {
                        id: 2,
                        name: '烟花爆竹经营(批发)许可证'
                    },
                    {
                        id: 3,
                        name: '烟花爆竹经营(长期零售)许可证'
                    },
                    {
                        id: 4,
                        name: '烟花爆竹经营(短期零售)许可证'
                    }
            ],
            licensetypeList:[
                {id:1,name:'长期'},
                {id:2,name:'临时'}
                licensetypeList: [{
                        id: 1,
                        name: '长期'
                    },
                    {
                        id: 2,
                        name: '临时'
                    }
            ],
              dealingtypeList:[
                {id:1,name:'专柜'},
                {id:2,name:'专店'}
                dealingtypeList: [{
                        id: 1,
                        name: '专柜'
                    },
                    {
                        id: 2,
                        name: '专店'
                    }
              ],
            printObj1:{
                id:'printMe1',
@@ -922,7 +942,12 @@
            this.storageprovince =val.storageprovince
            this.storagecity =val.storagecity
            this.storagedistrict =val.storagedistrict
            this.dealingrange = val.dealingRangeStr
                //带出口的特殊情况
                if (val.remark.indexOf("批发出口")!= -1 ){
                    this.dealingrange = val.dealingRangeStr+" (批发出口) ★★★"
                }else{
                    this.dealingrange = val.dealingRangeStr+"  ★★★"
                }
            this.effectdate = formatDateDay(val.effectdate)
            this.noeffectdate = formatDateDay(val.noeffectdate)
            this.issuingunit = val.issuingunit
@@ -1072,6 +1097,7 @@
                this.pageTotal = computePageCount(res.data.result.totalCount, res.data.result.pageSize)
                this.currentPage = res.data.result.current
                this.licenseList = res.data.result.result
            }
            this.listLoading = false
        },
@@ -1095,7 +1121,10 @@
                cancelButtonText:'取消',
                type:'warning',
            }).then(()=> {
                reviewLicenseInfo({id:val,reviewstatus:1}).then( ()=>{
                    reviewLicenseInfo({
                        id: val,
                        reviewstatus: 1
                    }).then(() => {
                    this.getLicenseListData()
                    this.$notify({
                        title:'成功',
@@ -1104,10 +1133,14 @@
                        duration:2000,
                    })
                }).catch(error => {
                    parseError({error: error, vm: this})
                        parseError({
                            error: error,
                            vm: this
                        })
                })
            })
        },
            //删除
        deleteById(val){
            this.$confirm('删除此条信息,是否继续','提示',{
                confirmButtonText:'确定',
@@ -1124,16 +1157,23 @@
                        });
                        this.getLicenseListData()
                    } else {
                        parseError({error: res.message, vm: this})
                            parseError({
                                error: res.message,
                                vm: this
                            })
                    }
                }).catch(error => {
                    parseError({error: error, vm: this})
                        parseError({
                            error: error,
                            vm: this
                        })
                })
            })
        },
        sortChange(){
        },
            //获取地区
      async changeArea(value){
        if(value === 'province'){
          this.params.city = ''
@@ -1165,14 +1205,18 @@
        if(res.data.code === "200"){
          this.provinceList = res.data.result.provinceList
        }
      },//获取省
            },
            //导出excel
      async exportRetail(){
         let params = {...this.params}
                let params = {
                    ...this.params
                }
        params.type = 3
        params.reviewstatus = 2
         getExportLicense(params).then(res=>{
           if(res.data.code === '200'){
             if(res.data.result === null ||res.data.result === [] || res.data.result.length === 0){
                        if (res.data.result === null || res.data.result === [] || res.data.result.length ===
                            0) {
               this.$message({
                 type:'warning',
                 message:'无数据可导出'
@@ -1225,13 +1269,15 @@
                     item.reservekg,
                     item.noeffectdate,
                     item.licensecode,
                     this.licensetypeList.filter(it=>it.id === item.licensetype).name,
                                        this.licensetypeList.filter(it => it.id === item
                                            .licensetype).name,
                     item.dealingRangeStr,
                     item.dealingarea,
                     item.mainpersonname,
                     item.issuingunit,
                     item.name,
                     this.dealingtypeList.filter(it=>it.id === item.dealingtype).name
                                        this.dealingtypeList.filter(it => it.id === item
                                            .dealingtype).name
                   ]
                 })
                 excel.export_json_to_excel({
@@ -1251,12 +1297,15 @@
         })
      },
      async exportWholesale(){
        let params = {...this.params}
                let params = {
                    ...this.params
                }
        params.type = 2
        params.reviewstatus = 2
        getExportLicense(params).then(res=>{
          if(res.data.code === '200'){
            if(res.data.result === null ||res.data.result === [] || res.data.result.length === 0){
                        if (res.data.result === null || res.data.result === [] || res.data.result.length ===
                            0) {
              this.$message({
                type:'warning',
                message:'无数据可导出'
@@ -1304,8 +1353,10 @@
                    item.noeffectdate,
                    item.dealingRangeStr,
                    item.mainpersonname,
                    [item.province,item.city,item.district].join("-"),
                    eval(item.licenseStorage).reduce((sum,e)=>sum+Number(e.area || 0),0),
                                        [item.province, item.city, item.district].join(
                                            "-"),
                                        eval(item.licenseStorage).reduce((sum, e) =>
                                            sum + Number(e.area || 0), 0),
                    item.address,
                    item.issuingdate,
                    item.licensecode,
@@ -1314,7 +1365,8 @@
                    item.reservekg,
                    item.code,
                    item.effectdate,
                    eval(item.licenseStorage).reduce((sum,e)=>sum+Number(e.storagearea || 0),0),
                                        eval(item.licenseStorage).reduce((sum, e) =>
                                            sum + Number(e.storagearea || 0), 0),
                    item.issuingunit,
                  ]
                })
@@ -1372,6 +1424,7 @@
.carrier_search{
    display: inline-block;
}
.carrier_search_input{
    width:200px;
}