| @@ -12,9 +12,9 @@ module.exports = { | |||
| proxyTable: { | |||
| "/api": { | |||
| // 请求的目标主机 | |||
| //target: 'http://218.59.175.44:8082/nsgk_test/', // 公网测试环境 | |||
| target: 'http://localhost:8080', // 公网测试环境 | |||
| // target: `http://192.168.0.116:8091/nsgk_api/`, // 内网测试环境 | |||
| target: 'http://localhost:8080/', | |||
| //target: 'http://localhost:8080/', | |||
| //target: 'http://192.168.0.106:8080/', | |||
| changeOrigin: true, | |||
| pathRewrite: { | |||
| @@ -52,3 +52,39 @@ export function generateEmployerCode(params) { | |||
| method: 'get' | |||
| }); | |||
| } | |||
| // 发包方签字授权(个人) | |||
| export function authorizeSignaturePsn(id, redirectUrl) { | |||
| return request({ | |||
| url: '/service/fbf/authorize/psn/' + id, | |||
| method: 'get', | |||
| params: {redirectUrl}, | |||
| }); | |||
| } | |||
| // 发包方签字授权(机构) | |||
| export function authorizeSignatureOrg(id, redirectUrl) { | |||
| return request({ | |||
| url: '/service/fbf/authorize/org/' + id, | |||
| method: 'post', | |||
| params: {redirectUrl}, | |||
| }); | |||
| } | |||
| // 发包方企业印章授权(机构) | |||
| export function authorizeOrgSeal(id, redirectUrl) { | |||
| return request({ | |||
| url: '/service/fbf/authorize/oegSeal/' + id, | |||
| method: 'post', | |||
| params: {redirectUrl}, | |||
| }); | |||
| } | |||
| // 发包方企业印章授权完成(机构) | |||
| export function authorizeOrgSealFinished(id, redirectUrl) { | |||
| return request({ | |||
| url: '/service/fbf/authorizeFinished/oegSeal/' + id, | |||
| method: 'post', | |||
| params: {redirectUrl}, | |||
| }); | |||
| } | |||
| @@ -885,6 +885,14 @@ export function listCbht(query) { | |||
| }) | |||
| } | |||
| // 查询承包合同详情 | |||
| export function getCbhtDetail(id) { | |||
| return request({ | |||
| url: '/service/cbht/get/' + id, | |||
| method: 'get', | |||
| }) | |||
| } | |||
| // 承包合同甲方签名 | |||
| export function cbhtFirstSign(data,id) { | |||
| return request({ | |||
| @@ -911,10 +919,11 @@ export function signedContractDownload(id) { | |||
| } | |||
| // 签字合同预览 | |||
| export function viewSignedContract(id) { | |||
| export function viewSignedContract(id, type) { | |||
| return request({ | |||
| url: '/open/villageAffairs/public/sign/view/' + id, | |||
| method: 'get' | |||
| method: 'get', | |||
| params: {type}, | |||
| }); | |||
| } | |||
| @@ -1050,19 +1059,29 @@ export function getMessage(id) { | |||
| }) | |||
| } | |||
| //e签宝-发包方合同网签 | |||
| export function eqbFbfhtwq(data){ | |||
| export function eqbFbfhtwq(data, parms){ | |||
| return request({ | |||
| url: '/open/villageAffairs/public/eqbFbfhtwq', | |||
| method: 'post', | |||
| data: data | |||
| data: data, | |||
| params: parms, | |||
| }) | |||
| } | |||
| //e签宝-发包方合同网签 | |||
| export function eqbFbfhtwqFinish(data){ | |||
| return request({ | |||
| url: '/open/villageAffairs/public/eqbFbfhtwqFinish', | |||
| method: 'post', | |||
| data: data, | |||
| }) | |||
| } | |||
| //e签宝-发包方批量生成签署流程 | |||
| export function batchEqbContractSignProcess(data){ | |||
| export function batchEqbContractSignProcess(data, parms){ | |||
| return request({ | |||
| url: '/service/cbf/batchEqbContractSignProcess', | |||
| method: 'post', | |||
| data: data | |||
| data: data, | |||
| params: parms, | |||
| }) | |||
| } | |||
| //e签宝-发包方批量签署 | |||
| @@ -1084,11 +1103,12 @@ export function batchContractCompleted() { | |||
| } | |||
| //e签宝-合同网签 | |||
| export function eqbCbfhtwq(data){ | |||
| export function eqbCbfhtwq(data, parms){ | |||
| return request({ | |||
| url: '/open/villageAffairs/public/eqbCbfhtwq', | |||
| method: 'post', | |||
| data: data | |||
| data: data, | |||
| params: parms, | |||
| }) | |||
| } | |||
| // 资源公开 | |||
| @@ -81,11 +81,12 @@ export function examineSign(data){ | |||
| }) | |||
| } | |||
| //承包方e签宝授权 | |||
| export function eqbEmpower(data){ | |||
| export function eqbEmpower(data, redirectUrl){ | |||
| return request({ | |||
| url:'/open/villageAffairs/public/eqbEmpower', | |||
| method: 'post', | |||
| data: data | |||
| data: data, | |||
| params: {redirectUrl}, | |||
| }) | |||
| } | |||
| //承包合同相关统计 | |||
| @@ -23,7 +23,7 @@ | |||
| <van-field v-model="form.realname" label="法人姓名" placeholder="请输入法人姓名" required :rules="[{ required:true }]"/> | |||
| <van-field v-model="form.idCardNum" label="法人身份证号" placeholder="请输入法人身份证号" required :rules="[{ required:true }]"/> | |||
| <van-field name="uploader" label="法人证件照" required> | |||
| <van-field name="uploader" label="法人证件照(人像面)" required> | |||
| <template #input> | |||
| <van-uploader :after-read="afterReadFRZJZ" :before-delete="deleteFileFRZJZ" v-model="fileListFRZJZ" multiple :max-count="1" /> | |||
| </template> | |||
| @@ -33,7 +33,7 @@ | |||
| <van-field v-model="form.realname" label="姓名" placeholder="请输入姓名" required :rules="[{ required:true }]"/> | |||
| <van-field v-model="form.idCardNum" label="身份证号" placeholder="请输入身份证号" required :rules="[{ required:true }]"/> | |||
| <van-field v-model="form.address" label="联系地址" placeholder="请输入联系地址" /> | |||
| <van-field name="uploader" label="身份证(正)" required :border="false"></van-field> | |||
| <van-field name="uploader" label="身份证(人像面)" required :border="false"></van-field> | |||
| <van-field name="uploader"> | |||
| <template #input> | |||
| <van-uploader :after-read="afterReadSFZ" :before-delete="deleteFileSFZ" v-model="fileListSFZ" multiple :max-count="1" /> | |||
| @@ -7,8 +7,8 @@ | |||
| </div> | |||
| <div class="search_info"> | |||
| <div class="search_block"> | |||
| <i class="icon"></i> | |||
| <input type="text" class="ipt" placeholder="搜索" v-model="queryParams.name" @input="getSearchList"> | |||
| <van-search class="search_block searchHeight" v-model="queryParams.queryOr" @input="getSearchList" :placeholder="searchPlaceholder" /> | |||
| <van-icon name="filter-o" color="#1989fa" class="filter-icon" @click="openContractionStatus" /> | |||
| </div> | |||
| <div class="total">共{{listLength}}个合同</div> | |||
| </div> | |||
| @@ -57,18 +57,42 @@ | |||
| <van-uploader v-model="fileList" :after-read="afterRead" @delete="deleteFile1" multiple /> | |||
| </div> | |||
| </van-popup> | |||
| <van-popup v-model="typeVisible" lock-scroll closeable position="top" > | |||
| <div style="padding: 0.2rem 0.3rem 0.3rem;"> | |||
| <van-cell-group> | |||
| <van-cell> | |||
| <div style="text-align: center; font-size: 18px;">筛选</div> | |||
| </van-cell> | |||
| <field-select | |||
| v-model="queryParams.contractionStatus" | |||
| label="合同状态" | |||
| value-key="dictLabel" | |||
| data-key="dictValue" | |||
| placeholder="选择合同状态" | |||
| :columns="contractionStatusOptions" | |||
| :clearable="true" | |||
| /> | |||
| </van-cell-group> | |||
| <div style="padding: 0.2rem 0.5rem 0;"> | |||
| <van-button round type="primary" block @click="refresh">搜索</van-button> | |||
| </div> | |||
| </div> | |||
| </van-popup> | |||
| </div> | |||
| </template> | |||
| <script> | |||
| import { contractionList , delInfo , commonAttach , attachmentList , systemAttachment } from "@/api/sunVillage_info/fixedAssets"; | |||
| import request from '@/utils/request' | |||
| import Selector from "@/components/common/Selector.vue"; | |||
| import FieldSelect from "@/components/form/FieldSelect.vue"; | |||
| export default { | |||
| name: "certificateList", | |||
| components: {FieldSelect, Selector}, | |||
| data() { | |||
| return { | |||
| applicationList:[], | |||
| applicationListSecond:[], | |||
| assetStatusOptions:[], | |||
| auditStatus:[], | |||
| loading: false, | |||
| @@ -81,12 +105,18 @@ | |||
| pageNum:1, | |||
| pageSize:10, | |||
| orderByColumn:'createTime', | |||
| contractionStatus: null, | |||
| secondParty: null, | |||
| isAsc:'desc', | |||
| name:'', | |||
| params:{}, | |||
| queryOr: null, | |||
| }, | |||
| uploadFiles1:[], | |||
| projectId:'', | |||
| projectIndex:'' | |||
| projectIndex:'', | |||
| typeVisible: false, | |||
| contractionStatusOptions: [], | |||
| }; | |||
| }, | |||
| created() { | |||
| @@ -96,14 +126,17 @@ | |||
| }, | |||
| methods: { | |||
| getList(){ | |||
| this.loading = true; | |||
| this.queryParams.params = {}; | |||
| this.queryParams.params["queryOr"] = this.queryParams.queryOr; | |||
| setTimeout(() => { | |||
| contractionList(this.queryParams).then(response => { | |||
| this.listLength = response.total; | |||
| this.applicationList = []; | |||
| for (var i = 0; i < response.rows.length; i++) { | |||
| response.rows[i].contractionStatus = this.selectDictLabel(this.contractionStatusOptions, response.rows[i].contractionStatus); | |||
| response.rows[i].totalAmount = Number(response.rows[i].totalAmount ).toFixed(2).replace(/(\d)(?=(\d{3})+\.)/g, ($0, $1) => { return $1 + ","; }).replace(/\.$/, "") | |||
| this.applicationList.push(response.rows[i]); | |||
| this.applicationListSecond.push(response.rows[i]); | |||
| } | |||
| if(this.applicationList.length >= response.total){ | |||
| this.finished = true; | |||
| @@ -115,11 +148,6 @@ | |||
| }); | |||
| }, 1000); | |||
| }, | |||
| getSearchList(){ | |||
| this.applicationList = []; | |||
| this.queryParams.pageNum = 1; | |||
| this.getList(); | |||
| }, | |||
| afterRead(file) { | |||
| // 此时可以自行将文件上传至服务器 | |||
| this.uploadFiles1.push(file.file); | |||
| @@ -153,9 +181,7 @@ | |||
| }, | |||
| /** 删除按钮操作 */ | |||
| handleDelete(row,index) { | |||
| const ids = row.id || this.ids; | |||
| this.$dialog.alert( | |||
| { | |||
| message:'是否确认删除合同信息?', | |||
| @@ -182,11 +208,36 @@ | |||
| goAdd(){ | |||
| this.$router.push('/sunVillage_info/informationAdd') | |||
| }, | |||
| getSearchList(){ | |||
| this.applicationList = []; | |||
| this.queryParams.pageNum = 1; | |||
| this.getList(); | |||
| }, | |||
| openContractionStatus() { | |||
| this.typeVisible = true; | |||
| }, | |||
| refresh() { | |||
| this.typeVisible = false; | |||
| this.queryParams.pageNum = 1; | |||
| this.listLength = 0; | |||
| this.applicationList = []; | |||
| this.finished = false; | |||
| this.getList(); | |||
| }, | |||
| }, | |||
| computed: { | |||
| searchPlaceholder() { | |||
| let typeName = this.contractionStatusOptions.find((x) => x.dictValue == this.queryParams.contractionStatus); | |||
| return '搜索' + (typeName ? typeName.dictLabel : ''); | |||
| }, | |||
| } | |||
| } | |||
| </script> | |||
| <style scoped lang="scss"> | |||
| /deep/ .van-search__content{ | |||
| background-color: transparent; | |||
| } | |||
| .home_wrapper{ | |||
| background: #e9e9e9; | |||
| min-height: 100vh; | |||
| @@ -229,29 +280,39 @@ | |||
| padding:20px 23px; | |||
| display: flex; | |||
| .search_block{ | |||
| height: 59px; | |||
| width: 535px; | |||
| border-radius: 59px; | |||
| background: #fff; | |||
| display: flex; | |||
| border:2px solid #3494ff; | |||
| padding-right: 35px; | |||
| align-items: center; | |||
| .icon{ | |||
| width: 30px; | |||
| height: 30px; | |||
| background: url('../../assets/images/sunVillage_info/fixedAssets_icon_1.png') no-repeat; | |||
| background-size: 100% 100%; | |||
| display: block; | |||
| margin:0 8px 0 26px; | |||
| } | |||
| .ipt{ | |||
| flex: 1; | |||
| font-size: 26px; | |||
| background: none; | |||
| border:0 none; | |||
| line-height: 59px; | |||
| } | |||
| width: 535px; | |||
| border-radius: 59px; | |||
| background: #fff; | |||
| display: flex; | |||
| border:2px solid #3494ff; | |||
| padding-right: 20px; | |||
| align-items: center; | |||
| &.searchHeight{ | |||
| border: none; | |||
| height: 57px; | |||
| padding-left: 0; | |||
| } | |||
| .icon{ | |||
| width: 30px; | |||
| height: 30px; | |||
| background: url('../../assets/images/sunVillage_info/fixedAssets_icon_1.png') no-repeat; | |||
| background-size: 100% 100%; | |||
| display: block; | |||
| margin:0 8px 0 26px; | |||
| } | |||
| .filter-icon { | |||
| font-weight: bold; | |||
| font-size: .4rem; | |||
| width: .6rem; | |||
| text-align: center; | |||
| } | |||
| .ipt{ | |||
| flex: 1; | |||
| font-size: 26px; | |||
| background: none; | |||
| border:0 none; | |||
| line-height: 59px; | |||
| } | |||
| } | |||
| .total{ | |||
| flex: 1; | |||
| @@ -213,10 +213,21 @@ | |||
| this.handleReset(); | |||
| }); | |||
| }, | |||
| getUrl(type) { | |||
| let url = location.href; | |||
| let index = url.indexOf('?'); | |||
| url = index < 0 ? url : url.substring(0, index); | |||
| if(type) | |||
| url += '?callback=' + type; | |||
| return url; | |||
| }, | |||
| reload() { | |||
| location.replace(this.getUrl()); | |||
| }, | |||
| contractSign(val){ | |||
| eqbCbfhtwq(val).then(response => { | |||
| this.noticeUrl = response.data; | |||
| this.htqsShow = true; | |||
| eqbCbfhtwq(val, {redirectUrl: this.getUrl('cbf&ht=' + val.id)}).then(response => { | |||
| this.noticeUrl = response.data.url; | |||
| this.htqsShow = true; | |||
| }); | |||
| }, | |||
| @@ -329,7 +340,7 @@ | |||
| }); | |||
| }, | |||
| contractView(id) { | |||
| viewSignedContract(id).then(response => { | |||
| viewSignedContract(id, 'cbf').then(response => { | |||
| if (response.code === 200) { | |||
| this.noticeUrl = response.data; | |||
| this.htqsShow = true; | |||
| @@ -2,7 +2,7 @@ | |||
| <div class="home_wrapper"> | |||
| <div class="header_main" > | |||
| {{this.$route.query.shStatus?'承包方审核':'承包方授权'}} | |||
| <div class="return_btn" @click="onClickLeft"></div> | |||
| <div class="return_btn" @click="back"></div> | |||
| </div> | |||
| <div class="list_main"> | |||
| <div class="titBox"> | |||
| @@ -288,15 +288,41 @@ | |||
| this.getDicts(k).then((resp) => this.options[k] = resp.data); | |||
| } | |||
| }, | |||
| getUrl(type) { | |||
| let url = location.href; | |||
| let index = url.indexOf('?'); | |||
| url = index < 0 ? url : url.substring(0, index); | |||
| if(type) | |||
| url += '?callback=' + type; | |||
| return url; | |||
| }, | |||
| reload() { | |||
| location.replace(this.getUrl()); | |||
| }, | |||
| /*承包方授权*/ | |||
| cbfsq(){ | |||
| eqbEmpower(this.form).then(response => { | |||
| eqbEmpower(this.form, this.getUrl(/*'psn'*/)).then(response => { | |||
| if(response.code === 200 ){ | |||
| // this.sqbutShow = false; | |||
| this.$notify({type: 'success', message: '授权成功'}); | |||
| this.showSignBtn = false; | |||
| this.showAuthBtn = false; | |||
| this.showAuthPic = true; | |||
| if(response.data.realname) | |||
| { | |||
| // this.sqbutShow = false; | |||
| this.$notify({type: 'success', message: '授权成功'}); | |||
| this.showSignBtn = false; | |||
| this.showAuthBtn = false; | |||
| this.showAuthPic = true; | |||
| } | |||
| else | |||
| { | |||
| console.log('打开E签宝个人认证授权页面: ' + response.data.authUrl); | |||
| this.$toast({ | |||
| icon: 'fail', | |||
| message: '将跳转至个人认证授权页面', | |||
| duration: '1000', | |||
| onClose: () => { | |||
| window.location.href = (response.data.authUrl); | |||
| } | |||
| }); | |||
| } | |||
| } | |||
| }); | |||
| }, | |||
| @@ -441,6 +467,9 @@ | |||
| type: mime | |||
| }) | |||
| }, | |||
| back() { | |||
| this.$router.push({path:'/sunVillage_info/index_code_rights'}); | |||
| }, | |||
| }, | |||
| } | |||
| </script> | |||
| @@ -121,7 +121,18 @@ | |||
| </template> | |||
| <script> | |||
| import { listCbht,eqbFbfhtwq, signProcessArchive, signedContractDownload,viewSignedContract, cbhtFirstSign, attachmentList, commonAttach, systemAttachment } from "@/api/sunVillage_info/fixedAssets"; | |||
| import { | |||
| listCbht, | |||
| eqbFbfhtwq, | |||
| signProcessArchive, | |||
| signedContractDownload, | |||
| viewSignedContract, | |||
| cbhtFirstSign, | |||
| attachmentList, | |||
| commonAttach, | |||
| systemAttachment, | |||
| getCbhtDetail | |||
| } from "@/api/sunVillage_info/fixedAssets"; | |||
| import vueEsign from "vue-esign"; | |||
| import $ from "jquery"; | |||
| @@ -174,6 +185,21 @@ | |||
| this.signingStatusData = res.data; | |||
| }); | |||
| this.height = window.screen.height * 1.28 - 20; | |||
| switch(this.$route.query.callback) // 带callback为认证完的回调 | |||
| { | |||
| case 'fbf': | |||
| let htId = this.$route.query.ht || ''; | |||
| getCbhtDetail(htId).then(({data}) => { | |||
| if(data.signingMode == '2' && data.fbfqszt !='2' && data.signingStatus !=='9') | |||
| this.contractSign(data); | |||
| else | |||
| console.log(`合同${htId}不允许签署`); | |||
| }); | |||
| break; | |||
| default: | |||
| break; | |||
| } | |||
| }, | |||
| methods: { | |||
| canvasTTdown() { | |||
| @@ -270,10 +296,32 @@ | |||
| this.$refs.esign.reset(); | |||
| $('#canvasTT').css('display', 'block') | |||
| }, | |||
| getUrl(type) { | |||
| let url = location.href; | |||
| let index = url.indexOf('?'); | |||
| url = index < 0 ? url : url.substring(0, index); | |||
| if(type) | |||
| url += '?callback=' + type; | |||
| return url; | |||
| }, | |||
| reload() { | |||
| location.replace(this.getUrl()); | |||
| }, | |||
| contractSign(val){ | |||
| eqbFbfhtwq(val).then(response => { | |||
| this.noticeUrl = response.data; | |||
| this.htqsShow = true; | |||
| eqbFbfhtwq(val, {redirectUrl: this.getUrl('fbf&ht=' + val.id)}).then(response => { | |||
| if(response.data.authorized) | |||
| { | |||
| this.noticeUrl = response.data.url; | |||
| this.htqsShow = true; | |||
| } | |||
| else | |||
| { | |||
| this.$notify({type: 'warning', message: '企业机构印章未授权, 请先进行授权操作'}); | |||
| console.log('打开E签宝机构印章对外授权页面: ' + response.data.authorizationSignUrl); | |||
| setTimeout(() => { | |||
| window.location.href = (response.data.authorizationSignUrl); | |||
| }, 1000); | |||
| } | |||
| }); | |||
| }, | |||
| @@ -315,7 +363,7 @@ | |||
| }) | |||
| }, | |||
| contractView(id) { | |||
| viewSignedContract(id).then(response => { | |||
| viewSignedContract(id, 'fbf').then(response => { | |||
| if (response.code === 200) { | |||
| this.noticeUrl = response.data; | |||
| this.htqsShow = true; | |||
| @@ -151,13 +151,24 @@ | |||
| },3000) | |||
| }); | |||
| }, | |||
| getUrl(type) { | |||
| let url = location.href; | |||
| let index = url.indexOf('?'); | |||
| url = index < 0 ? url : url.substring(0, index); | |||
| if(type) | |||
| url += '?callback=' + type; | |||
| return url; | |||
| }, | |||
| reload() { | |||
| location.replace(this.getUrl()); | |||
| }, | |||
| batchEqbContractSignProcess(val){ | |||
| this.$toast.loading({ | |||
| message: "数据处理中", | |||
| forbidClick: true, | |||
| duration: 10000000000, | |||
| }); | |||
| batchEqbContractSignProcess(val).then(response => { | |||
| batchEqbContractSignProcess(val, {redirectUrl: this.getUrl('fbf&ht=')}).then(response => { | |||
| this.$toast.clear(); | |||
| this.$toast.success(response.data); | |||
| let _this = this; | |||
| @@ -70,6 +70,7 @@ import {listSiyigongkai, delSiyigongkai, listSiyigongkaiOpen} from "@/api/sunVil | |||
| pageNum:1, | |||
| pageSize:10, | |||
| isAsc:'desc', | |||
| orderByColumn:'createTime', | |||
| openYear:'', | |||
| otherType: null, | |||
| }, | |||
| @@ -2,7 +2,7 @@ | |||
| <div class="home_wrapper"> | |||
| <div class="header_main" > | |||
| 发包方授权 | |||
| <div class="return_btn" @click="onClickLeft"></div> | |||
| <div class="return_btn" @click="back"></div> | |||
| </div> | |||
| <div class="list_main"> | |||
| <div class="titBox"> | |||
| @@ -33,8 +33,14 @@ | |||
| <van-field readonly label="审核人签字" input-align="right" :border="false" /> | |||
| <img :src="'/api'+form.shrqz" width="100%" alt="" v-if="form.shrqz" /> | |||
| <div style="margin: 30px auto 0;width: 50%;"> | |||
| <van-button round block type="primary" native-type="submit" @click="handleAuthorization(form.id)" v-if="!form.personAccountId && !form.companyAccountId" > | |||
| 授权 | |||
| <van-button size="small" round block type="primary" native-type="submit" @click="handleAuthorizationPsn(form.id)" v-if="!form.personAccountId" class="auth-button"> | |||
| 个人授权 | |||
| </van-button> | |||
| <van-button size="small" round block type="primary" native-type="submit" @click="handleAuthorizationOrg(form.id)" v-if="!form.companyAccountId" class="auth-button"> | |||
| 企业授权 | |||
| </van-button> | |||
| <van-button size="small" round block type="primary" native-type="submit" :disabled="!form.companySealId" @click="handleAuthorizationOrgSeal(form.id)" v-if="!form.companySealId || form.companySealAuthorized !== 'Y'" class="auth-button"> | |||
| 企业印章授权 | |||
| </van-button> | |||
| </div> | |||
| <img class="bottomImg" src="../../assets/images/sunVillage_info/employer_authorized.png" alt="" v-if="form.personAccountId && form.companyAccountId" /> | |||
| @@ -44,8 +50,15 @@ | |||
| <script> | |||
| // import { getList} from "@/api/sunVillage_info/sysCbf"; | |||
| import { listFbf, authorizeSignature } from "@/api/contracted/fbf"; | |||
| import { | |||
| listFbf, | |||
| authorizeSignaturePerson, | |||
| authorizeSignaturePsn, | |||
| authorizeSignatureOrg, | |||
| authorizeOrgSeal | |||
| } from "@/api/contracted/fbf"; | |||
| import $ from "jquery"; | |||
| import router from "@/router"; | |||
| export default { | |||
| name: "certificateList", | |||
| data() { | |||
| @@ -55,30 +68,165 @@ | |||
| }; | |||
| }, | |||
| created() { | |||
| this.getFbfList(); | |||
| switch(this.$route.query.callback) // 带callback为认证完的回调 | |||
| { | |||
| /* case 'psn': | |||
| this.getFbfList().then((id) => { | |||
| console.log('个人认证回调'); | |||
| this.callbackAuthorizationPsn(id); | |||
| }); | |||
| break; | |||
| case 'org': | |||
| this.getFbfList().then((id) => { | |||
| console.log('机构认证回调'); | |||
| this.callbackAuthorizationOrg(id); | |||
| }); | |||
| break;*/ | |||
| case 'orgSeal': | |||
| this.getFbfList().then((id) => { | |||
| console.log('企业印章授权回调'); | |||
| this.callbackAuthorizationOrgSeal(id); | |||
| }); | |||
| break; | |||
| default: | |||
| this.getFbfList(); | |||
| break; | |||
| } | |||
| this.getFbfList(); | |||
| }, | |||
| methods: { | |||
| getFbfList() { | |||
| listFbf({deptId: this.$store.state.user.loginDeptId, translate_dict: 1}).then(response => { | |||
| return listFbf({deptId: this.$store.state.user.loginDeptId, translate_dict: 1}).then(response => { | |||
| if (response.rows.length > 0) { | |||
| this.form = response.rows[0]; | |||
| return Promise.resolve(this.form.id); | |||
| } | |||
| else | |||
| return Promise.reject(); | |||
| }).catch(() => { | |||
| return Promise.reject(); | |||
| }); | |||
| }, | |||
| handleAuthorizationPsn(id) { | |||
| authorizeSignaturePsn(id, this.getUrl(/*'psn'*/)).then(response => { | |||
| if (response.code === 200) { | |||
| if(response.data.realname) | |||
| { | |||
| this.$toast({ | |||
| icon: 'success', | |||
| message: '授权成功', | |||
| duration: '1000', | |||
| onClose: () => { | |||
| this.getFbfList(); | |||
| } | |||
| }) | |||
| } | |||
| else | |||
| { | |||
| console.log('打开E签宝个人认证授权页面: ' + response.data.authUrl); | |||
| this.$toast({ | |||
| icon: 'fail', | |||
| message: '将跳转至个人认证授权页面', | |||
| duration: '1000', | |||
| onClose: () => { | |||
| window.location.href = (response.data.authUrl); | |||
| } | |||
| }); | |||
| } | |||
| } | |||
| }); | |||
| }, | |||
| handleAuthorization(id) { | |||
| authorizeSignature(id).then(response => { | |||
| handleAuthorizationOrg(id) { | |||
| authorizeSignatureOrg(id, this.getUrl(/*'org'*/)).then(response => { | |||
| if (response.code === 200) { | |||
| this.$toast({ | |||
| icon: 'success', | |||
| message: '授权成功', | |||
| duration: '1000', | |||
| onClose: () => { | |||
| this.getFbfList(); | |||
| if(response.data.realname) | |||
| { | |||
| this.$toast({ | |||
| icon: 'success', | |||
| message: '授权成功', | |||
| duration: '1000', | |||
| onClose: () => { | |||
| this.getFbfList(); | |||
| } | |||
| }) | |||
| } | |||
| else | |||
| { | |||
| console.log('打开E签宝机构认证授权页面: ' + response.data.authUrl); | |||
| this.$toast({ | |||
| icon: 'fail', | |||
| message: '将跳转至企业认证授权页面', | |||
| duration: '1000', | |||
| onClose: () => { | |||
| window.location.href = (response.data.authUrl); | |||
| } | |||
| }); | |||
| } | |||
| } | |||
| }); | |||
| }, | |||
| handleAuthorizationOrgSeal(id) { | |||
| authorizeOrgSeal(id, this.getUrl('orgSeal')).then(response => { | |||
| if (response.code === 200) { | |||
| if(response.data.realname) | |||
| { | |||
| this.$toast({ | |||
| icon: 'success', | |||
| message: '授权成功', | |||
| duration: '1000', | |||
| onClose: () => { | |||
| this.getFbfList(); | |||
| } | |||
| }) | |||
| } | |||
| else | |||
| { | |||
| console.log('打开E签宝机构印章授权页面: ' + response.data.authUrl); | |||
| this.$toast({ | |||
| icon: 'fail', | |||
| message: '将跳转至企业印章授权页面', | |||
| duration: '1000', | |||
| onClose: () => { | |||
| window.location.href = (response.data.authUrl); | |||
| } | |||
| }); | |||
| } | |||
| } | |||
| }) | |||
| }); | |||
| }, | |||
| getUrl(type) { | |||
| let url = location.href; | |||
| let index = url.indexOf('?'); | |||
| url = index < 0 ? url : url.substring(0, index); | |||
| if(type) | |||
| url += '?callback=' + type; | |||
| return url; | |||
| }, | |||
| reload() { | |||
| location.replace(this.getUrl()); | |||
| }, | |||
| callbackAuthorizationOrgSeal(id) { | |||
| authorizeOrgSeal(id, this.getUrl(/*'orgSeal'*/)).then(response => { | |||
| if (response.code === 200) { | |||
| if(response.data.realname) | |||
| { | |||
| this.reload(); | |||
| } | |||
| else | |||
| { | |||
| console.log('E签宝机构印章授权失败'); | |||
| this.$toast({ | |||
| icon: 'fail', | |||
| message: '企业印章授权失败', | |||
| duration: '1000', | |||
| }); | |||
| } | |||
| } | |||
| }); | |||
| } | |||
| }, | |||
| back() { | |||
| this.$router.push({path:'/sunVillage_info/index'}); | |||
| }, | |||
| }, | |||
| } | |||
| </script> | |||
| @@ -140,6 +288,10 @@ | |||
| margin: 25px auto 0; | |||
| border-radius: 15PX; | |||
| box-shadow: 4px 6px 5px rgba(63, 68, 75, 0.1); | |||
| .auth-button { | |||
| margin-bottom: .1rem; | |||
| } | |||
| } | |||
| .titBox { | |||
| @@ -89,11 +89,9 @@ | |||
| methods: { | |||
| getDetail() { | |||
| specialPublicityDetail(this.queryParams).then((resp) => { | |||
| console.log() | |||
| resp.data.specialPublicityType = this.selectDictLabel(this.specialPublicityTypeOptions, resp.data.specialPublicityType); | |||
| if(resp.data.openContent.indexOf('<img') > -1){ | |||
| if(resp.data.openContent !=null && resp.data.openContent !="" && resp.data.openContent.indexOf('<img') > -1){ | |||
| resp.data.openContent = resp.data.openContent.replace(/<img/g,'<img style="width:100%;"') | |||
| console.log(resp.data) | |||
| } | |||
| this.form = resp.data; | |||
| }); | |||
| @@ -363,39 +363,39 @@ | |||
| padding:20px 23px; | |||
| display: flex; | |||
| .search_block{ | |||
| width: 535px; | |||
| border-radius: 59px; | |||
| background: #fff; | |||
| display: flex; | |||
| border:2px solid #3494ff; | |||
| padding-right: 20px; | |||
| align-items: center; | |||
| &.searchHeight{ | |||
| border: none; | |||
| height: 57px; | |||
| padding-left: 0; | |||
| width: 535px; | |||
| border-radius: 59px; | |||
| background: #fff; | |||
| display: flex; | |||
| border:2px solid #3494ff; | |||
| padding-right: 20px; | |||
| align-items: center; | |||
| &.searchHeight{ | |||
| border: none; | |||
| height: 57px; | |||
| padding-left: 0; | |||
| } | |||
| .icon{ | |||
| width: 30px; | |||
| height: 30px; | |||
| background: url('../../assets/images/sunVillage_info/fixedAssets_icon_1.png') no-repeat; | |||
| background-size: 100% 100%; | |||
| display: block; | |||
| margin:0 8px 0 26px; | |||
| } | |||
| .icon{ | |||
| width: 30px; | |||
| height: 30px; | |||
| background: url('../../assets/images/sunVillage_info/fixedAssets_icon_1.png') no-repeat; | |||
| background-size: 100% 100%; | |||
| display: block; | |||
| margin:0 8px 0 26px; | |||
| } | |||
| .filter-icon { | |||
| font-weight: bold; | |||
| font-size: .4rem; | |||
| width: .6rem; | |||
| text-align: center; | |||
| .filter-icon { | |||
| font-weight: bold; | |||
| font-size: .4rem; | |||
| width: .6rem; | |||
| text-align: center; | |||
| } | |||
| .ipt{ | |||
| flex: 1; | |||
| font-size: 26px; | |||
| background: none; | |||
| border:0 none; | |||
| line-height: 59px; | |||
| } | |||
| .ipt{ | |||
| flex: 1; | |||
| font-size: 26px; | |||
| background: none; | |||
| border:0 none; | |||
| line-height: 59px; | |||
| } | |||
| } | |||
| .total{ | |||
| flex: 1; | |||