企业列表画面
parent
e58c9edf93
commit
1f2ef70023
|
|
@ -0,0 +1,68 @@
|
||||||
|
import { defHttp } from '@/utils/http/axios';
|
||||||
|
|
||||||
|
enum Api {
|
||||||
|
// 企业信息
|
||||||
|
LoadBidCompanyInfo = '/api/BidCompanyInfo/LoadBidCompanyInfo',
|
||||||
|
UploadFile = '/api/Files/Upload',
|
||||||
|
AddBidCompanyInfo = '/api/BidCompanyInfo/AddBidCompanyInfo',
|
||||||
|
EditBidCompanyInfo = '/api/BidCompanyInfo/EditBidCompanyInfo',
|
||||||
|
DeleteBidCompanyInfo = '/api/BidCompanyInfo/DeleteBidCompanyInfo',
|
||||||
|
ReviewBidCompanyInfo = '/api/BidCompanyInfo/ReviewBidCompanyInfo',
|
||||||
|
AddCompanyAccount = '/api/BidCompanyInfo/AddCompanyAccount',
|
||||||
|
}
|
||||||
|
const getRequestBidCompanyInfoListUrl = (userType) => {
|
||||||
|
switch(userType){
|
||||||
|
case 1:
|
||||||
|
// 招标代理
|
||||||
|
return '/api/BiddingAgency/LoadBiddingAgencyByUser'
|
||||||
|
case 2:
|
||||||
|
// 供应商
|
||||||
|
return '/api/BidCompanyInfo/LoadCompanyInfoByUser'
|
||||||
|
case 3:
|
||||||
|
// 甲方公司
|
||||||
|
return '/api/BidCompanyInfo/LoadBidCompanyInfo'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 企业信息
|
||||||
|
export function LoadBidCompanyInfo(params, userType) {
|
||||||
|
return defHttp.get({
|
||||||
|
url: getRequestBidCompanyInfoListUrl(userType),
|
||||||
|
params,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
export const uploadFile = (params) =>
|
||||||
|
defHttp.post({
|
||||||
|
url: Api.UploadFile,
|
||||||
|
params,
|
||||||
|
headers: {
|
||||||
|
'Content-type': 'multipart/form-data',
|
||||||
|
},
|
||||||
|
})
|
||||||
|
export function AddBidCompanyInfo(params) {
|
||||||
|
return defHttp.post({
|
||||||
|
url: Api.AddBidCompanyInfo,
|
||||||
|
params,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
export function EditBidCompanyInfo(params) {
|
||||||
|
return defHttp.post({
|
||||||
|
url: Api.EditBidCompanyInfo,
|
||||||
|
params,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
export function DeleteBidCompanyInfo(id) {
|
||||||
|
return defHttp.post({
|
||||||
|
url: `${Api.DeleteBidCompanyInfo}?id=${id}`,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
export function ReviewBidCompanyInfo(id) {
|
||||||
|
return defHttp.post({
|
||||||
|
url: `${Api.ReviewBidCompanyInfo}?id=${id}`,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
export function AddCompanyAccount(params) {
|
||||||
|
return defHttp.post({
|
||||||
|
url: Api.AddCompanyAccount,
|
||||||
|
params,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,249 @@
|
||||||
|
<template>
|
||||||
|
|
||||||
|
<div class="title-div">
|
||||||
|
<div class="title-span-div">
|
||||||
|
<div class="title-icon"></div>
|
||||||
|
<div class="title-span">账号管理</div>
|
||||||
|
</div>
|
||||||
|
<div class="close-button" @click="emits('changeManageModal',false)"></div>
|
||||||
|
</div>
|
||||||
|
<div class="interval"></div>
|
||||||
|
<a-spin tip="加载中..." :spinning="loading">
|
||||||
|
<div class="modal-content">
|
||||||
|
<div class="left-content">
|
||||||
|
<div class="item-title">企业名称</div>
|
||||||
|
<a-input class="item-input" v-model:value="companyName" placeholder="请输入企业名称" disabled/>
|
||||||
|
<div class="item-title">账号分配</div>
|
||||||
|
<a-select
|
||||||
|
class="item-select"
|
||||||
|
v-model:value="userId"
|
||||||
|
:options="userOptions"
|
||||||
|
placeholder="请为企业分配账号"
|
||||||
|
>
|
||||||
|
<template #suffixIcon>
|
||||||
|
<div class="search-select-suffixIcon"></div>
|
||||||
|
</template>
|
||||||
|
</a-select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="interval"></div>
|
||||||
|
<div class="footer">
|
||||||
|
<a-button class="cancel-button" @click="emits('changeManageModal',false)">取消</a-button>
|
||||||
|
<a-button class="save-button" type="primary" @click="submit">确认提交</a-button>
|
||||||
|
</div>
|
||||||
|
</a-spin>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { ref, defineEmits, defineProps, onMounted } from "vue"
|
||||||
|
import { message, Modal } from "ant-design-vue";
|
||||||
|
import { AddBidCompanyInfo, AddCompanyAccount } from '@/api/demo/enterprise'
|
||||||
|
import { getAccountList } from '@/api/demo/system';
|
||||||
|
const props = defineProps(['info'])
|
||||||
|
const emits = defineEmits(['changeManageModal', 'query'])
|
||||||
|
onMounted(() => {
|
||||||
|
companyId.value = props.info.id
|
||||||
|
companyName.value = props.info.name
|
||||||
|
getAccountList({page:1,limit:999}).then(res => {
|
||||||
|
userOptions.value = res.items.map(item => {
|
||||||
|
return { label: item.name, value: item.id }
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
|
const companyId = ref('')
|
||||||
|
const companyName = ref('')
|
||||||
|
const userId = ref()
|
||||||
|
const userOptions = ref([])
|
||||||
|
const loading = ref(false)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
const submit = () => {
|
||||||
|
if(!userId.value){
|
||||||
|
return message.warning('请为企业分配账号!')
|
||||||
|
}
|
||||||
|
loading.value = true
|
||||||
|
let params = [
|
||||||
|
{
|
||||||
|
companyId: companyId.value,
|
||||||
|
userId: userId.value
|
||||||
|
}
|
||||||
|
]
|
||||||
|
console.log('params',params)
|
||||||
|
AddCompanyAccount(params).then(res => {
|
||||||
|
message.success('保存成功!')
|
||||||
|
emits('query')
|
||||||
|
emits('changeManageModal',false)
|
||||||
|
}).finally(() => {
|
||||||
|
loading.value = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.title-div{
|
||||||
|
width: 100%;
|
||||||
|
height: 64px;
|
||||||
|
padding-top: 15px;
|
||||||
|
padding-left: 26px;
|
||||||
|
padding-right: 35px;
|
||||||
|
padding-bottom: 14px;
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
.title-span-div{
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
.title-icon{
|
||||||
|
width: 3px;
|
||||||
|
height: 18px;
|
||||||
|
background: #0B60BD;
|
||||||
|
box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
margin-right: 9px;
|
||||||
|
}
|
||||||
|
.title-span{
|
||||||
|
font-family: PingFangSC-Medium;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 20px;
|
||||||
|
color: #11131B;
|
||||||
|
line-height: 33px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.close-button{
|
||||||
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
|
background-image: url('/public/tender/tender_close_modal_button.png');
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.interval{
|
||||||
|
width: 100%;
|
||||||
|
height: 1px;
|
||||||
|
box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border: 1px solid #DBDBDB;
|
||||||
|
opacity: 0.66;
|
||||||
|
}
|
||||||
|
.modal-content{
|
||||||
|
display: flex;
|
||||||
|
padding-top: 24px;
|
||||||
|
padding-left: 38px;
|
||||||
|
padding-right: 40px;
|
||||||
|
padding-bottom: 27px;
|
||||||
|
.item-title{
|
||||||
|
font-family: PingFangSC-Regular;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 13px;
|
||||||
|
color: #000000;
|
||||||
|
line-height: 20px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
margin-bottom: 7px;
|
||||||
|
}
|
||||||
|
.item-input{
|
||||||
|
width: 100%;
|
||||||
|
height: 40px;
|
||||||
|
background: #FFFFFF;
|
||||||
|
// box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 6px;
|
||||||
|
border: 1px solid #A9BBD8;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
}
|
||||||
|
.item-select{
|
||||||
|
width: 100%;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
:deep(.ant-select-selector){
|
||||||
|
height: 40px;
|
||||||
|
background: #FFFFFF;
|
||||||
|
// box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 6px;
|
||||||
|
border: 1px solid #A9BBD8;
|
||||||
|
}
|
||||||
|
:deep(.ant-select-selection-item){
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
font-family: PingFangSC-Regular;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 13px;
|
||||||
|
color: #000000;
|
||||||
|
line-height: 20px;
|
||||||
|
}
|
||||||
|
:deep(.ant-select-selection-placeholder){
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
font-family: PingFangSC-Regular;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 13px;
|
||||||
|
color: rgba(0, 0, 0, 0.55);
|
||||||
|
line-height: 20px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
}
|
||||||
|
.search-select-suffixIcon{
|
||||||
|
width: 10px;
|
||||||
|
height: 6px;
|
||||||
|
background-image: url('/public/tender/search_select_icon.png');
|
||||||
|
background-size: 100% 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.item-date-picker{
|
||||||
|
width: 100%;
|
||||||
|
height: 40px;
|
||||||
|
background: #FFFFFF;
|
||||||
|
// box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 6px;
|
||||||
|
border: 1px solid #A9BBD8;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
}
|
||||||
|
.left-content{
|
||||||
|
width: 100%;
|
||||||
|
// margin-right: 124px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.footer{
|
||||||
|
height: 85px;
|
||||||
|
padding-right: 34px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: end;
|
||||||
|
.cancel-button{
|
||||||
|
width: 101px;
|
||||||
|
height: 40px;
|
||||||
|
box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 4px;
|
||||||
|
border: 1px solid #979797;
|
||||||
|
font-family: PingFangSC-Medium;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 16px;
|
||||||
|
color: #222738;
|
||||||
|
line-height: 33px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
margin-right: 24px;
|
||||||
|
}
|
||||||
|
.delete-button{
|
||||||
|
width: 146px;
|
||||||
|
height: 40px;
|
||||||
|
background: #ed6f6f;
|
||||||
|
box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 4px;
|
||||||
|
font-family: PingFangSC-Medium;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 16px;
|
||||||
|
color: #FFFFFF;
|
||||||
|
line-height: 33px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
margin-right: 24px;
|
||||||
|
}
|
||||||
|
.save-button{
|
||||||
|
width: 146px;
|
||||||
|
height: 40px;
|
||||||
|
background: #0081FF;
|
||||||
|
box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 4px;
|
||||||
|
font-family: PingFangSC-Medium;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 16px;
|
||||||
|
color: #FFFFFF;
|
||||||
|
line-height: 33px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
@ -0,0 +1,337 @@
|
||||||
|
<template>
|
||||||
|
|
||||||
|
<div class="title-div">
|
||||||
|
<div class="title-span-div">
|
||||||
|
<div class="title-icon"></div>
|
||||||
|
<div class="title-span">添加企业信息</div>
|
||||||
|
</div>
|
||||||
|
<div class="close-button" @click="emits('changeAddModal',false)"></div>
|
||||||
|
</div>
|
||||||
|
<div class="interval"></div>
|
||||||
|
<a-spin tip="加载中..." :spinning="loading">
|
||||||
|
<div class="modal-content">
|
||||||
|
<div class="left-content">
|
||||||
|
<div class="item-title">企业名称</div>
|
||||||
|
<a-input class="item-input" v-model:value="name" placeholder="请输入企业名称" />
|
||||||
|
<div class="item-title">信用代码</div>
|
||||||
|
<a-input class="item-input" v-model:value="code" placeholder="请输入信用代码" />
|
||||||
|
<div class="item-title">企业法人</div>
|
||||||
|
<a-input class="item-input" v-model:value="legalPerson" placeholder="请输入企业法人" />
|
||||||
|
<div class="item-title">营业执照</div>
|
||||||
|
<a-upload
|
||||||
|
v-model:file-list="licenseList"
|
||||||
|
accept=".zip"
|
||||||
|
:maxCount="1"
|
||||||
|
:custom-request="customRequest"
|
||||||
|
>
|
||||||
|
<a-button>
|
||||||
|
<upload-outlined></upload-outlined>
|
||||||
|
上传营业执照
|
||||||
|
</a-button>
|
||||||
|
<template #itemRender="{ file, actions }">
|
||||||
|
<a-space>
|
||||||
|
<span>{{ file.name }}</span>
|
||||||
|
</a-space>
|
||||||
|
</template>
|
||||||
|
</a-upload>
|
||||||
|
</div>
|
||||||
|
<div class="right-content">
|
||||||
|
<div class="item-title">联系人</div>
|
||||||
|
<a-input class="item-input" v-model:value="contactPerson" placeholder="请输入联系人" />
|
||||||
|
<div class="item-title">联系方式</div>
|
||||||
|
<a-input class="item-input" v-model:value="phone" placeholder="请输入联系方式" />
|
||||||
|
<div class="item-title">账号状态</div>
|
||||||
|
<a-select
|
||||||
|
class="item-select"
|
||||||
|
v-model:value="accountState"
|
||||||
|
:options="accountStateOptions"
|
||||||
|
placeholder="请选择账号状态"
|
||||||
|
>
|
||||||
|
<template #suffixIcon>
|
||||||
|
<div class="search-select-suffixIcon"></div>
|
||||||
|
</template>
|
||||||
|
</a-select>
|
||||||
|
<div class="item-title">企业资质</div>
|
||||||
|
<a-input class="item-input" v-model:value="qualification" placeholder="请输入企业资质" />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="interval"></div>
|
||||||
|
<div class="footer">
|
||||||
|
<a-button class="cancel-button" @click="emits('changeAddModal',false)">取消</a-button>
|
||||||
|
<a-button v-if="props.modalType == 'update'" class="delete-button" type="primary" @click="delData">删除</a-button>
|
||||||
|
<a-button class="save-button" type="primary" @click="submit">确认提交</a-button>
|
||||||
|
</div>
|
||||||
|
</a-spin>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { ref, h, defineEmits, defineProps, onMounted, createVNode } from "vue"
|
||||||
|
import { ExclamationCircleOutlined, PlusOutlined, } from '@ant-design/icons-vue';
|
||||||
|
import { message, Modal } from "ant-design-vue";
|
||||||
|
import { AddBidCompanyInfo, EditBidCompanyInfo, DeleteBidCompanyInfo } from '@/api/demo/enterprise'
|
||||||
|
import { uploadFile } from '@/api/demo/enterprise'
|
||||||
|
import { accountStateOptions } from '@/views/demo/enterpriselist/util'
|
||||||
|
const props = defineProps(['modalType', 'info'])
|
||||||
|
const emits = defineEmits(['changeAddModal', 'query'])
|
||||||
|
onMounted(() => {
|
||||||
|
if(props.modalType == 'update'){
|
||||||
|
id.value = props.info.id
|
||||||
|
name.value = props.info.name
|
||||||
|
code.value = props.info.code
|
||||||
|
legalPerson.value = props.info.legalPerson
|
||||||
|
|
||||||
|
contactPerson.value = props.info.contactPerson
|
||||||
|
phone.value = props.info.phone
|
||||||
|
accountState.value = props.info.accountState
|
||||||
|
qualification.value = props.info.qualification
|
||||||
|
license.value = props.info.license
|
||||||
|
licenseList.value = [{
|
||||||
|
uid: '-1',
|
||||||
|
name: props.info.license,
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
})
|
||||||
|
const id = ref('')
|
||||||
|
const name = ref('')
|
||||||
|
const code = ref('')
|
||||||
|
const legalPerson = ref('')
|
||||||
|
const license = ref('')
|
||||||
|
const licenseList = ref([])
|
||||||
|
const contactPerson = ref('')
|
||||||
|
const phone = ref('')
|
||||||
|
const accountState = ref(0)
|
||||||
|
const qualification = ref('')
|
||||||
|
|
||||||
|
const loading = ref(false)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
const submit = () => {
|
||||||
|
loading.value = true
|
||||||
|
let params = {
|
||||||
|
id: id.value,
|
||||||
|
name: name.value,
|
||||||
|
code: code.value,
|
||||||
|
legalPerson: legalPerson.value,
|
||||||
|
license: license.value,
|
||||||
|
contactPerson: contactPerson.value,
|
||||||
|
phone: phone.value,
|
||||||
|
accountState: accountState.value,
|
||||||
|
qualification: qualification.value,
|
||||||
|
}
|
||||||
|
console.log('params',params)
|
||||||
|
if(props.modalType == 'insert'){
|
||||||
|
AddBidCompanyInfo(params).then(res => {
|
||||||
|
message.success('企业信息添加成功')
|
||||||
|
emits('query')
|
||||||
|
emits('changeAddModal',false)
|
||||||
|
}).finally(() => {
|
||||||
|
loading.value = false
|
||||||
|
})
|
||||||
|
}else{
|
||||||
|
EditBidCompanyInfo(params).then(res => {
|
||||||
|
message.success('企业信息修改成功')
|
||||||
|
emits('query')
|
||||||
|
emits('changeAddModal',false)
|
||||||
|
}).finally(() => {
|
||||||
|
loading.value = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const delData = () => {
|
||||||
|
Modal.confirm({
|
||||||
|
title: `确认删除该企业信息吗?`,
|
||||||
|
icon: createVNode(ExclamationCircleOutlined),
|
||||||
|
okText: '确认',
|
||||||
|
cancelText: '取消',
|
||||||
|
centered: true,
|
||||||
|
onOk() {
|
||||||
|
return DeleteBidCompanyInfo(id.value).then(res => {
|
||||||
|
message.success("删除成功")
|
||||||
|
emits('query')
|
||||||
|
emits('changeAddModal',false)
|
||||||
|
})
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
|
const customRequest = (file) => {
|
||||||
|
const formData = new FormData()
|
||||||
|
formData.append('files', file.file)
|
||||||
|
uploadFile(formData).then(res => {
|
||||||
|
license.value = res[0].filePath
|
||||||
|
console.log('licenseList',licenseList)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.title-div{
|
||||||
|
width: 100%;
|
||||||
|
height: 64px;
|
||||||
|
padding-top: 15px;
|
||||||
|
padding-left: 26px;
|
||||||
|
padding-right: 35px;
|
||||||
|
padding-bottom: 14px;
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
.title-span-div{
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
.title-icon{
|
||||||
|
width: 3px;
|
||||||
|
height: 18px;
|
||||||
|
background: #0B60BD;
|
||||||
|
box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
margin-right: 9px;
|
||||||
|
}
|
||||||
|
.title-span{
|
||||||
|
font-family: PingFangSC-Medium;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 20px;
|
||||||
|
color: #11131B;
|
||||||
|
line-height: 33px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.close-button{
|
||||||
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
|
background-image: url('/public/tender/tender_close_modal_button.png');
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.interval{
|
||||||
|
width: 100%;
|
||||||
|
height: 1px;
|
||||||
|
box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border: 1px solid #DBDBDB;
|
||||||
|
opacity: 0.66;
|
||||||
|
}
|
||||||
|
.modal-content{
|
||||||
|
display: flex;
|
||||||
|
padding-top: 24px;
|
||||||
|
padding-left: 38px;
|
||||||
|
padding-right: 40px;
|
||||||
|
padding-bottom: 27px;
|
||||||
|
.item-title{
|
||||||
|
font-family: PingFangSC-Regular;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 13px;
|
||||||
|
color: #000000;
|
||||||
|
line-height: 20px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
margin-bottom: 7px;
|
||||||
|
}
|
||||||
|
.item-input{
|
||||||
|
width: 286px;
|
||||||
|
height: 40px;
|
||||||
|
background: #FFFFFF;
|
||||||
|
// box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 6px;
|
||||||
|
border: 1px solid #A9BBD8;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
}
|
||||||
|
.item-select{
|
||||||
|
width: 100%;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
:deep(.ant-select-selector){
|
||||||
|
height: 40px;
|
||||||
|
background: #FFFFFF;
|
||||||
|
// box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 6px;
|
||||||
|
border: 1px solid #A9BBD8;
|
||||||
|
}
|
||||||
|
:deep(.ant-select-selection-item){
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
font-family: PingFangSC-Regular;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 13px;
|
||||||
|
color: #000000;
|
||||||
|
line-height: 20px;
|
||||||
|
}
|
||||||
|
:deep(.ant-select-selection-placeholder){
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
font-family: PingFangSC-Regular;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 13px;
|
||||||
|
color: rgba(0, 0, 0, 0.55);
|
||||||
|
line-height: 20px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
}
|
||||||
|
.search-select-suffixIcon{
|
||||||
|
width: 10px;
|
||||||
|
height: 6px;
|
||||||
|
background-image: url('/public/tender/search_select_icon.png');
|
||||||
|
background-size: 100% 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.item-date-picker{
|
||||||
|
width: 100%;
|
||||||
|
height: 40px;
|
||||||
|
background: #FFFFFF;
|
||||||
|
// box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 6px;
|
||||||
|
border: 1px solid #A9BBD8;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
}
|
||||||
|
.left-content{
|
||||||
|
width: 286px;
|
||||||
|
margin-right: 124px;
|
||||||
|
}
|
||||||
|
.right-content{
|
||||||
|
width: 286px;
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.footer{
|
||||||
|
height: 85px;
|
||||||
|
padding-right: 34px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: end;
|
||||||
|
.cancel-button{
|
||||||
|
width: 101px;
|
||||||
|
height: 40px;
|
||||||
|
box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 4px;
|
||||||
|
border: 1px solid #979797;
|
||||||
|
font-family: PingFangSC-Medium;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 16px;
|
||||||
|
color: #222738;
|
||||||
|
line-height: 33px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
margin-right: 24px;
|
||||||
|
}
|
||||||
|
.delete-button{
|
||||||
|
width: 146px;
|
||||||
|
height: 40px;
|
||||||
|
background: #ed6f6f;
|
||||||
|
box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 4px;
|
||||||
|
font-family: PingFangSC-Medium;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 16px;
|
||||||
|
color: #FFFFFF;
|
||||||
|
line-height: 33px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
margin-right: 24px;
|
||||||
|
}
|
||||||
|
.save-button{
|
||||||
|
width: 146px;
|
||||||
|
height: 40px;
|
||||||
|
background: #0081FF;
|
||||||
|
box-shadow: 0px 10px 30px 0px rgba(0,0,6,0.15);
|
||||||
|
border-radius: 4px;
|
||||||
|
font-family: PingFangSC-Medium;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 16px;
|
||||||
|
color: #FFFFFF;
|
||||||
|
line-height: 33px;
|
||||||
|
text-shadow: 0px 10px 30px rgba(0,0,6,0.15);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
@ -21,24 +21,24 @@
|
||||||
<a-input
|
<a-input
|
||||||
style="width: 201px;"
|
style="width: 201px;"
|
||||||
class="search-input"
|
class="search-input"
|
||||||
v-model:value="params.no"
|
v-model:value="params.code"
|
||||||
placeholder="请输入信用代码"
|
placeholder="请输入信用代码"
|
||||||
/>
|
/>
|
||||||
<div class="search-label">企业资质</div>
|
<div class="search-label">企业资质</div>
|
||||||
<a-input
|
<a-input
|
||||||
style="width: 201px;"
|
style="width: 201px;"
|
||||||
class="search-input"
|
class="search-input"
|
||||||
v-model:value="params.no"
|
v-model:value="params.qualification"
|
||||||
placeholder="请输入企业资质"
|
placeholder="请输入企业资质"
|
||||||
/>
|
/>
|
||||||
<a-button class="search-button search" type="primary" >
|
<a-button class="search-button search" type="primary" @click="query()">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<div class="search-icon"></div>
|
<div class="search-icon"></div>
|
||||||
</template>
|
</template>
|
||||||
搜索
|
搜索
|
||||||
</a-button>
|
</a-button>
|
||||||
</div>
|
</div>
|
||||||
<a-button class="search-button add-button" type="primary" >
|
<a-button class="search-button add-button" type="primary" @click="openAddEnterpriseModal('insert', '')">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<PlusOutlined />
|
<PlusOutlined />
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -46,34 +46,35 @@
|
||||||
</a-button>
|
</a-button>
|
||||||
</div>
|
</div>
|
||||||
<div class="content-div" :style="{ height: user == 3?'': '752px' }">
|
<div class="content-div" :style="{ height: user == 3?'': '752px' }">
|
||||||
<a-table
|
<a-table
|
||||||
|
:loading="loading"
|
||||||
class="content-table"
|
class="content-table"
|
||||||
:row-selection="rowSelection"
|
:row-selection="rowSelection"
|
||||||
:columns="getShowColumns()"
|
:columns="getShowColumns()"
|
||||||
:data-source="data"
|
:data-source="showList"
|
||||||
:pagination="false"
|
:pagination="false"
|
||||||
:scroll="{ y: user == 3? 550: 550 }"
|
:scroll="{ y: user == 3? 550: 550 }"
|
||||||
>
|
>
|
||||||
<template #bodyCell="{ column, text }">
|
<template #bodyCell="{ column, text, record }">
|
||||||
<template v-if="
|
<template v-if="
|
||||||
column.dataIndex === 'businesslicense' ||
|
column.dataIndex === 'license' ||
|
||||||
(column.dataIndex === 'usernumber' && user !== 3)
|
(column.dataIndex === 'phone' && user !== 3)
|
||||||
">
|
">
|
||||||
<div class="blue-span">{{ text }}</div>
|
<div class="blue-span">{{ text }}</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="column.dataIndex === 'status'">
|
<template v-if="column.dataIndex === 'accountState'">
|
||||||
<div :class="`status-cell ${text == '正常'? 'success-status': 'error-status'}`">
|
<div :class="`status-cell ${text == 0? 'success-status': 'error-status'}`">
|
||||||
<div class="status-icon"></div>
|
<div class="status-icon"></div>
|
||||||
{{ text }}
|
{{ text == 0? '正常': '停用' }}
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="column.dataIndex === 'operate'">
|
<template v-if="column.dataIndex === 'operate'">
|
||||||
<a-dropdown overlayClassName="operate-dropdown" placement="bottom" :arrow="{ pointAtCenter: true }">
|
<a-dropdown overlayClassName="operate-dropdown" placement="bottom" :arrow="{ pointAtCenter: true }">
|
||||||
<template #overlay>
|
<template #overlay>
|
||||||
<a-menu @click="operateClick">
|
<a-menu @click="operateClick">
|
||||||
<a-menu-item key="1">修改</a-menu-item>
|
<a-menu-item key="1" :disabled="record.isReview" @click="openAddEnterpriseModal('update',record)">修改</a-menu-item>
|
||||||
<a-menu-item key="2" v-if="user == 3">审核</a-menu-item>
|
<a-menu-item key="2" :disabled="record.isReview" @click="review(record)" v-if="user == 3">审核</a-menu-item>
|
||||||
<a-menu-item key="4" v-if="user == 3">账号管理</a-menu-item>
|
<a-menu-item key="4" v-if="user == 3" @click="accountManage(record)">账号管理</a-menu-item>
|
||||||
</a-menu>
|
</a-menu>
|
||||||
</template>
|
</template>
|
||||||
<a-button class="operate-button" type="primary">
|
<a-button class="operate-button" type="primary">
|
||||||
|
|
@ -89,8 +90,9 @@
|
||||||
v-model:current="page"
|
v-model:current="page"
|
||||||
v-model:pageSize="limit"
|
v-model:pageSize="limit"
|
||||||
show-quick-jumper
|
show-quick-jumper
|
||||||
:total="500"
|
:total="total"
|
||||||
@change="paginationChange"
|
@change="paginationChange"
|
||||||
|
:show-total="total => `共 ${total} 条数据`"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -150,30 +152,58 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<a-modal width="775px" v-model:open="insertModalOpen" :footer="null" :closable="false" :destroyOnClose="true" :maskClosable="false" :keyboard="false">
|
||||||
|
<InsertModal
|
||||||
|
:modalType="modalType"
|
||||||
|
:info="showInfo"
|
||||||
|
@changeAddModal="changeAddModal"
|
||||||
|
@query="query"
|
||||||
|
/>
|
||||||
|
</a-modal>
|
||||||
|
<a-modal width="775px" v-model:open="accountManageModal" :footer="null" :closable="false" :destroyOnClose="true" :maskClosable="false" :keyboard="false">
|
||||||
|
<AccountManage
|
||||||
|
:info="enterpriseInfo"
|
||||||
|
@changeManageModal="changeManageModal"
|
||||||
|
@query="query"
|
||||||
|
/>
|
||||||
|
</a-modal>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref } from "vue"
|
import { ref, onMounted } from "vue"
|
||||||
import { yearOptions, proxyColumns, supplierColumns, proprietorColumns, data } from './util'
|
import { yearOptions, proxyColumns, supplierColumns, proprietorColumns, data } from './util'
|
||||||
import { SearchOutlined, PlusOutlined, DownOutlined } from '@ant-design/icons-vue'
|
import { SearchOutlined, PlusOutlined, DownOutlined } from '@ant-design/icons-vue'
|
||||||
|
import { LoadBidCompanyInfo, ReviewBidCompanyInfo } from '@/api/demo/enterprise'
|
||||||
|
import { getUserType } from '@/views/demo/util'
|
||||||
|
import InsertModal from './InsertModal/index.vue'
|
||||||
|
import AccountManage from './AccountManage/index.vue'
|
||||||
|
import { message } from "ant-design-vue"
|
||||||
|
|
||||||
const user = ref(3)
|
onMounted(() => {
|
||||||
|
query()
|
||||||
|
})
|
||||||
|
const user = ref(getUserType())
|
||||||
const params = ref({
|
const params = ref({
|
||||||
type: 0,
|
|
||||||
year: null,
|
|
||||||
name: null,
|
name: null,
|
||||||
no: null,
|
code: null,
|
||||||
genre: null,
|
qualification: null,
|
||||||
form: null,
|
|
||||||
})
|
})
|
||||||
const fromValue = ref({
|
const fromValue = ref({
|
||||||
title:'',
|
title:'',
|
||||||
time: '',
|
time: '',
|
||||||
content: '',
|
content: '',
|
||||||
})
|
})
|
||||||
|
const showList = ref([])
|
||||||
const page = ref(1)
|
const page = ref(1)
|
||||||
const limit = ref(10)
|
const limit = ref(10)
|
||||||
|
const total = ref(0)
|
||||||
|
const loading = ref(false)
|
||||||
|
const insertModalOpen = ref(false)
|
||||||
|
const accountManageModal = ref(false)
|
||||||
|
const modalType = ref('')
|
||||||
|
const showInfo = ref({})
|
||||||
|
const enterpriseInfo = ref({})
|
||||||
|
|
||||||
const rowSelection = {
|
const rowSelection = {
|
||||||
onChange: (selectedRowKeys, selectedRows) => {
|
onChange: (selectedRowKeys, selectedRows) => {
|
||||||
|
|
@ -184,11 +214,9 @@ const rowSelection = {
|
||||||
name: record.name,
|
name: record.name,
|
||||||
}),
|
}),
|
||||||
};
|
};
|
||||||
const changeTabs = (type) => {
|
|
||||||
params.value.type = type
|
|
||||||
}
|
|
||||||
const paginationChange = (a,b) => {
|
const paginationChange = (a,b) => {
|
||||||
console.log(a,b)
|
console.log(a,b)
|
||||||
|
query()
|
||||||
}
|
}
|
||||||
const getShowColumns = () => {
|
const getShowColumns = () => {
|
||||||
switch(user.value){
|
switch(user.value){
|
||||||
|
|
@ -203,6 +231,43 @@ const getShowColumns = () => {
|
||||||
const operateClick = (a,b,c) => {
|
const operateClick = (a,b,c) => {
|
||||||
console.log(a,b,c)
|
console.log(a,b,c)
|
||||||
}
|
}
|
||||||
|
const query = () => {
|
||||||
|
let requestParams = {
|
||||||
|
...params.value,
|
||||||
|
page: page.value,
|
||||||
|
limit: limit.value,
|
||||||
|
}
|
||||||
|
loading.value = true
|
||||||
|
LoadBidCompanyInfo(requestParams, user.value).then(res => {
|
||||||
|
total.value = res.total
|
||||||
|
showList.value = res.items
|
||||||
|
}).finally(() => {
|
||||||
|
loading.value = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
const changeAddModal = (type) => {
|
||||||
|
insertModalOpen.value = type
|
||||||
|
}
|
||||||
|
const changeManageModal = (type) => {
|
||||||
|
accountManageModal.value = type
|
||||||
|
}
|
||||||
|
const openAddEnterpriseModal = (type, item) => {
|
||||||
|
modalType.value = type
|
||||||
|
if(type == 'update'){
|
||||||
|
showInfo.value = item
|
||||||
|
}
|
||||||
|
changeAddModal(true)
|
||||||
|
}
|
||||||
|
const review = (record) => {
|
||||||
|
ReviewBidCompanyInfo(record.id).then(res => {
|
||||||
|
message.success('企业信息审核成功')
|
||||||
|
query()
|
||||||
|
})
|
||||||
|
}
|
||||||
|
const accountManage = (record) => {
|
||||||
|
enterpriseInfo.value = record
|
||||||
|
accountManageModal.value = true
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|
|
||||||
|
|
@ -4,36 +4,28 @@ export const yearOptions = getYearList();
|
||||||
|
|
||||||
export const proxyColumns = [
|
export const proxyColumns = [
|
||||||
{
|
{
|
||||||
title: '项目名称',
|
title: '企业名称',
|
||||||
dataIndex: 'name',
|
dataIndex: 'name',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '项目编号',
|
title: '信用代码',
|
||||||
dataIndex: 'no',
|
dataIndex: 'code',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '招标类型',
|
title: '营业执照',
|
||||||
dataIndex: 'type',
|
dataIndex: 'license',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '招标金额(元)',
|
title: '企业法人',
|
||||||
dataIndex: 'money',
|
dataIndex: 'legalPerson',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '招标形式',
|
title: '联系人',
|
||||||
dataIndex: 'form',
|
dataIndex: 'contactPerson',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '采购人',
|
title: '联系方式',
|
||||||
dataIndex: 'person',
|
dataIndex: 'phone',
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '报名截止',
|
|
||||||
dataIndex: 'endtime',
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '开标时间',
|
|
||||||
dataIndex: 'starttime',
|
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
export const supplierColumns = [
|
export const supplierColumns = [
|
||||||
|
|
@ -43,11 +35,11 @@ export const supplierColumns = [
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '信用代码',
|
title: '信用代码',
|
||||||
dataIndex: 'no',
|
dataIndex: 'code',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '营业执照',
|
title: '营业执照',
|
||||||
dataIndex: 'businesslicense',
|
dataIndex: 'license',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '企业法人',
|
title: '企业法人',
|
||||||
|
|
@ -55,15 +47,15 @@ export const supplierColumns = [
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '联系人',
|
title: '联系人',
|
||||||
dataIndex: 'user',
|
dataIndex: 'contactPerson',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '联系方式',
|
title: '联系方式',
|
||||||
dataIndex: 'usernumber',
|
dataIndex: 'phone',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '企业资质',
|
title: '企业资质',
|
||||||
dataIndex: 'certification',
|
dataIndex: 'qualification',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '操作',
|
title: '操作',
|
||||||
|
|
@ -77,11 +69,11 @@ export const proprietorColumns = [
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '信用代码',
|
title: '信用代码',
|
||||||
dataIndex: 'no',
|
dataIndex: 'code',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '营业执照',
|
title: '营业执照',
|
||||||
dataIndex: 'businesslicense',
|
dataIndex: 'license',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '企业法人',
|
title: '企业法人',
|
||||||
|
|
@ -89,19 +81,19 @@ export const proprietorColumns = [
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '联系人',
|
title: '联系人',
|
||||||
dataIndex: 'user',
|
dataIndex: 'contactPerson',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '联系方式',
|
title: '联系方式',
|
||||||
dataIndex: 'usernumber',
|
dataIndex: 'phone',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '账号状态',
|
title: '账号状态',
|
||||||
dataIndex: 'status',
|
dataIndex: 'accountState',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '企业资质',
|
title: '企业资质',
|
||||||
dataIndex: 'certification',
|
dataIndex: 'qualification',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '操作',
|
title: '操作',
|
||||||
|
|
@ -175,4 +167,9 @@ export const data = [
|
||||||
certification: '材料类/工程类/服务类',
|
certification: '材料类/工程类/服务类',
|
||||||
status: '禁用',
|
status: '禁用',
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
export const accountStateOptions = [
|
||||||
|
{label: '正常', value: 0},
|
||||||
|
{label: '停用', value: 1},
|
||||||
|
]
|
||||||
Loading…
Reference in New Issue