10 changed files with 2723 additions and 0 deletions
File diff suppressed because it is too large
@ -0,0 +1,676 @@ |
|||
<template> |
|||
<div class="app-container"> |
|||
<!-- 企业基本信息 --> |
|||
<div class="listTitle" style="margin-top: 0"> |
|||
<span>企业基本信息</span> |
|||
</div> |
|||
<el-row :gutter="15"> |
|||
<el-form |
|||
ref="form" |
|||
:model="form" |
|||
:rules="rules" |
|||
label-width="80px" |
|||
label-position="top" |
|||
> |
|||
<el-col :span="8"> |
|||
<el-form-item label="企业名称" prop="enterpriseName"> |
|||
<el-input |
|||
v-model="form.enterpriseName" |
|||
placeholder="请输入企业名称" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="投资组成" prop="investmentComposition"> |
|||
<el-input |
|||
v-model="form.investmentComposition" |
|||
placeholder="请输入投资组成" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="企业所属区划" prop="adcd"> |
|||
<el-cascader |
|||
:options="areasOptions" |
|||
v-model="form.adcd" |
|||
:props="areasOptionProps" |
|||
placeholder="请选择企业所属区划" |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
> |
|||
</el-cascader> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="成立日期" prop="establishmentDate"> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.establishmentDate" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择成立日期" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="法定代表人" prop="legalRepresentative"> |
|||
<el-input |
|||
v-model="form.legalRepresentative" |
|||
placeholder="请输入法定代表人" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="法人身份证号" prop="corporateIdNumber"> |
|||
<el-input |
|||
v-model="form.corporateIdNumber" |
|||
placeholder="请输入法人身份证号" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="注册资本金" prop="registeredCapital"> |
|||
<el-input |
|||
v-model="form.registeredCapital" |
|||
placeholder="请输入注册资本金" |
|||
> |
|||
<template slot="append">万元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="实缴注册资本" prop="paidRegisteredCapital"> |
|||
<el-input |
|||
v-model="form.paidRegisteredCapital" |
|||
placeholder="请输入实缴注册资本" |
|||
> |
|||
<template slot="append">万元</template> |
|||
</el-input> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="单位社保编号" prop="unitSecurityNumber"> |
|||
<el-input |
|||
v-model="form.unitSecurityNumber" |
|||
placeholder="请输入单位社保编号" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="统一社会信用代码" prop="unifiedSocialCreditCode"> |
|||
<el-input |
|||
v-model="form.unifiedSocialCreditCode" |
|||
placeholder="请输入统一社会信用代码" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
|
|||
<el-col :span="8"> |
|||
<el-form-item |
|||
label="信用代码发证机关" |
|||
prop="creditCodeIssuingAuthority" |
|||
> |
|||
<el-input |
|||
v-model="form.creditCodeIssuingAuthority" |
|||
placeholder="请输入信用代码发证机关" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="注册地址" prop="registeredAddress"> |
|||
<el-input |
|||
v-model="form.registeredAddress" |
|||
placeholder="请输入注册地址" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="安全生产许可证" prop="safetyProductionLicense"> |
|||
<el-input |
|||
v-model="form.safetyProductionLicense" |
|||
placeholder="请输入安全生产许可证" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
|
|||
<el-col :span="8"> |
|||
<el-form-item label="许可证发证机关" prop="licenseIssuingAuthority"> |
|||
<el-input |
|||
v-model="form.licenseIssuingAuthority" |
|||
placeholder="请输入许可证发证机关" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="办公电话" prop="officePhone"> |
|||
<el-input v-model="form.officePhone" placeholder="请输入办公电话" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="联系人" prop="contacts"> |
|||
<el-input v-model="form.contacts" placeholder="请输入联系人" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="联系人电话" prop="contactsPhone"> |
|||
<el-input |
|||
v-model="form.contactsPhone" |
|||
placeholder="请输入联系人电话" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="传真" prop="fax"> |
|||
<el-input v-model="form.fax" placeholder="请输入传真" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="企业网址" prop="enterpriseWebsite"> |
|||
<el-input |
|||
v-model="form.enterpriseWebsite" |
|||
placeholder="请输入企业网址" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="邮政编码" prop="postalCode"> |
|||
<el-input v-model="form.postalCode" placeholder="请输入邮政编码" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="电子邮箱" prop="email"> |
|||
<el-input v-model="form.email" placeholder="请输入电子邮箱" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="备注" prop="remark"> |
|||
<el-input v-model="form.remark" placeholder="请输入备注" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="经营范围" prop="businessScope"> |
|||
<el-input |
|||
v-model="form.businessScope" |
|||
placeholder="请输入经营范围" |
|||
/> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<el-form-item label="信用分数" prop="score"> |
|||
<el-input v-model="form.score" placeholder="请输入信用分数" /> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="统一社会信用代码证" |
|||
prop="socialCreditCodeAttachment" |
|||
> |
|||
<el-upload |
|||
class="upload-demo" |
|||
action="thinking/common/upload" |
|||
:headers="headers" |
|||
:on-preview="handleOpinionPreview" |
|||
:on-remove="(file) => handleOpinionRemove(file, 'fileList1')" |
|||
:before-remove="beforeOpinionRemove" |
|||
multiple |
|||
:on-exceed="handleOpinionExceed" |
|||
:on-success=" |
|||
(_, fileList) => submitOpinionUpload(fileList, 'fileList1') |
|||
" |
|||
:file-list="fileList1" |
|||
> |
|||
<el-button size="small" type="primary" plain> |
|||
<i class="el-icon-upload el-icon--right"></i> |
|||
点击上传 |
|||
</el-button> |
|||
<div slot="tip" class="el-upload__tip"> |
|||
支持jpg/png/pdf/word/excel文件等,不超过100M |
|||
</div> |
|||
</el-upload> |
|||
</el-form-item> |
|||
</el-col> |
|||
<el-col :span="12"> |
|||
<el-form-item |
|||
label="安全生产许可证附件" |
|||
prop="safetyProductionAttachment" |
|||
> |
|||
<el-upload |
|||
class="upload-demo" |
|||
action="thinking/common/upload" |
|||
:headers="headers" |
|||
:on-preview="handleOpinionPreview" |
|||
:on-remove="(file) => handleOpinionRemove(file, 'fileList2')" |
|||
:before-remove="beforeOpinionRemove" |
|||
multiple |
|||
:on-exceed="handleOpinionExceed" |
|||
:on-success=" |
|||
(_, fileList) => submitOpinionUpload(fileList, 'fileList2') |
|||
" |
|||
:file-list="fileList2" |
|||
> |
|||
<el-button size="small" type="primary" plain> |
|||
<i class="el-icon-upload el-icon--right"></i> |
|||
点击上传 |
|||
</el-button> |
|||
<div slot="tip" class="el-upload__tip"> |
|||
支持jpg/png/pdf/word/excel文件等,不超过100M |
|||
</div> |
|||
</el-upload> |
|||
</el-form-item> |
|||
</el-col> |
|||
</el-form> |
|||
</el-row> |
|||
<div class="btnList"> |
|||
<el-button type="primary" @click="submitForm">保 存</el-button> |
|||
<el-button @click="cancel">取 消</el-button> |
|||
</div> |
|||
<!-- 管理体系信息 --> |
|||
<div class="listTitle"> |
|||
<span>管理体系信息</span> |
|||
<span class="addBtn" @click="handleAdd('0')"> |
|||
<i class="el-icon-plus"></i> |
|||
添加 |
|||
</span> |
|||
</div> |
|||
<managementSystem ref="managementSystem" :enterpriseId="form.id" /> |
|||
<!-- 分公司信息 --> |
|||
<div class="listTitle"> |
|||
<span>分公司信息</span> |
|||
<span class="addBtn" @click="handleAdd('1')"> |
|||
<i class="el-icon-plus"></i> |
|||
添加 |
|||
</span> |
|||
</div> |
|||
<SubCompany ref="SubCompany" :enterpriseId="form.id" /> |
|||
</div> |
|||
</template> |
|||
|
|||
<script> |
|||
import { |
|||
listEnterpriseInfo, |
|||
getEnterpriseInfo, |
|||
delEnterpriseInfo, |
|||
addEnterpriseInfo, |
|||
updateEnterpriseInfo, |
|||
exportEnterpriseInfo, |
|||
} from "@/api/enterprise/enterpriseInfo"; |
|||
import { getAreasData } from "@/api/areas/index"; |
|||
import { regionData, codeToText, TextToCode } from "element-china-area-data"; |
|||
import { getToken } from "@/utils/auth"; |
|||
import { getFileStream } from "@/api/system/upload"; |
|||
import managementSystem from "./components/managementSystem.vue"; |
|||
import SubCompany from "./components/SubCompany.vue"; |
|||
export default { |
|||
name: "EnterpriseInfo", |
|||
components: { |
|||
managementSystem, |
|||
SubCompany, |
|||
}, |
|||
data() { |
|||
return { |
|||
areasOptionProps: { |
|||
emitPath: false, //value返回最后一级的 |
|||
checkStrictly: true, //选择任意一级 |
|||
}, |
|||
areasOptions: [], |
|||
// 查询参数 |
|||
queryParams: { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
ids: null, |
|||
data: { |
|||
enterpriseName: null, |
|||
adcd: null, |
|||
}, |
|||
// 排序方式 |
|||
params: { |
|||
// 按哪个字段排序 |
|||
orderBy: "create_time", |
|||
// desc降序,升序asc |
|||
sort: "desc", |
|||
}, |
|||
}, |
|||
// 表单参数 |
|||
form: {}, |
|||
// 表单校验 |
|||
rules: { |
|||
enterpriseName: [ |
|||
{ required: true, message: "请输入企业名称", trigger: "blur" }, |
|||
], |
|||
registeredCapital: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
paidRegisteredCapital: [ |
|||
{ |
|||
pattern: |
|||
/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/, |
|||
message: "请输入数字,可保留两位小数", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
officePhone: [ |
|||
{ |
|||
pattern: |
|||
/^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\d{8}$/, |
|||
message: "请输入正确的手机号", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
contactsPhone: [ |
|||
{ |
|||
pattern: |
|||
/^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\d{8}$/, |
|||
message: "请输入正确的手机号", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
enterpriseWebsite: [ |
|||
{ |
|||
pattern: |
|||
/^(https|http|ftp)\:\/\/[a-zA-Z0-9\-\.]+\.[a-zA-Z]{2,}(:[0-9]{1,5})?(\/[\S]*)?$/, |
|||
message: "请输入正确的网址", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
postalCode: [ |
|||
{ |
|||
pattern: /^[1-9]\d{5}$/, |
|||
message: "请输入正确的6位数字(1-9开头)邮政编码", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
email: [ |
|||
{ |
|||
pattern: /^[a-zA-Z0-9_-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/, |
|||
message: "请输入正确的邮箱", |
|||
trigger: "blur", |
|||
}, |
|||
], |
|||
}, |
|||
// 面包屑,路由信息 |
|||
routeList: [ |
|||
{ |
|||
path: "/marketSupervision/enterpriseInformation", |
|||
routeName: "企业信息管理", |
|||
}, |
|||
], |
|||
// 请求头 |
|||
headers: { |
|||
jianwei: "jwtech " + getToken(), |
|||
}, |
|||
fileList1: [], |
|||
fileList2: [], |
|||
}; |
|||
}, |
|||
created() { |
|||
this.getTreeData(); |
|||
this.getList(); |
|||
}, |
|||
methods: { |
|||
handleAdd(key) { |
|||
if (key == 0) this.$refs.managementSystem.handleAdd(); |
|||
if (key == 1) this.$refs.SubCompany.handleAdd(); |
|||
}, |
|||
formatAdcd(row) { |
|||
if (row.adcd) { |
|||
let provinceCode = row.adcd.slice(0, 2); |
|||
let cityCode = row.adcd.slice(2, 4); |
|||
let areaCode = row.adcd.slice(4, 6); |
|||
if (areaCode != "00") { |
|||
return ( |
|||
codeToText[provinceCode] + |
|||
"-" + |
|||
codeToText[provinceCode + cityCode] + |
|||
"-" + |
|||
codeToText[provinceCode + cityCode + areaCode] |
|||
); |
|||
} else if (cityCode != "00") { |
|||
return ( |
|||
codeToText[provinceCode] + "-" + codeToText[provinceCode + cityCode] |
|||
); |
|||
} else { |
|||
return codeToText[provinceCode]; |
|||
} |
|||
} |
|||
}, |
|||
getTreeData() { |
|||
getAreasData().then((items) => { |
|||
// console.log("getAreasData", items.data); |
|||
let res = []; |
|||
let getChildren = (res, pid) => { |
|||
for (const i of items.data) { |
|||
if (i.parentid === pid) { |
|||
const newItem = { |
|||
label: i.name, |
|||
value: i.id, |
|||
}; |
|||
if (i.layer != 3) newItem.children = []; |
|||
res.push(newItem); |
|||
getChildren(newItem.children, newItem.value); |
|||
} |
|||
} |
|||
}; |
|||
getChildren(res, items.data[0].parentid); |
|||
console.log("areasOptions", res); |
|||
this.areasOptions = res; |
|||
// 当不是admin时,默认行政区域 |
|||
// if (this.$userProfile.createUid != "admin") { |
|||
// this.queryParams.data.adcd = this.areasOptions[0].value; |
|||
// } |
|||
// return res; |
|||
}); |
|||
}, |
|||
/** 查询企业基本信息列表 */ |
|||
getList() { |
|||
getEnterpriseInfo(this.$route.query.baseDataId).then((response) => { |
|||
this.form = response.data; |
|||
if (this.form.socialCreditCodeAttachment) { |
|||
this.fileList1 = JSON.parse(this.form.socialCreditCodeAttachment); |
|||
} |
|||
if (this.form.safetyProductionAttachment) { |
|||
this.fileList2 = JSON.parse(this.form.safetyProductionAttachment); |
|||
} |
|||
}); |
|||
}, |
|||
// 取消按钮 |
|||
cancel() { |
|||
this.$router.back(); |
|||
this.reset(); |
|||
}, |
|||
// 表单重置 |
|||
reset() { |
|||
this.form = { |
|||
id: null, |
|||
enterpriseName: null, |
|||
investmentComposition: null, |
|||
adcd: null, |
|||
establishmentDate: null, |
|||
legalRepresentative: null, |
|||
corporateIdNumber: null, |
|||
registeredCapital: null, |
|||
paidRegisteredCapital: null, |
|||
unitSecurityNumber: null, |
|||
unifiedSocialCreditCode: null, |
|||
socialCreditCodeAttachment: null, |
|||
creditCodeIssuingAuthority: null, |
|||
registeredAddress: null, |
|||
safetyProductionLicense: null, |
|||
safetyProductionAttachment: null, |
|||
licenseIssuingAuthority: null, |
|||
officePhone: null, |
|||
contacts: null, |
|||
contactsPhone: null, |
|||
fax: null, |
|||
enterpriseWebsite: null, |
|||
postalCode: null, |
|||
email: null, |
|||
remark: null, |
|||
businessScope: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
owerDept: null, |
|||
score: null, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
// 查询表单重置 |
|||
resetQueryForm() { |
|||
this.queryParams = { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
data: { |
|||
id: null, |
|||
enterpriseName: null, |
|||
investmentComposition: null, |
|||
adcd: null, |
|||
establishmentDate: null, |
|||
legalRepresentative: null, |
|||
corporateIdNumber: null, |
|||
registeredCapital: null, |
|||
paidRegisteredCapital: null, |
|||
unitSecurityNumber: null, |
|||
unifiedSocialCreditCode: null, |
|||
socialCreditCodeAttachment: null, |
|||
creditCodeIssuingAuthority: null, |
|||
registeredAddress: null, |
|||
safetyProductionLicense: null, |
|||
safetyProductionAttachment: null, |
|||
licenseIssuingAuthority: null, |
|||
officePhone: null, |
|||
contacts: null, |
|||
contactsPhone: null, |
|||
fax: null, |
|||
enterpriseWebsite: null, |
|||
postalCode: null, |
|||
email: null, |
|||
remark: null, |
|||
businessScope: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
owerDept: null, |
|||
score: null, |
|||
}, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
|
|||
/** 提交按钮 */ |
|||
submitForm() { |
|||
this.$refs["form"].validate((valid) => { |
|||
if (valid) { |
|||
this.form.socialCreditCodeAttachment = JSON.stringify(this.fileList1); |
|||
this.form.safetyProductionAttachment = JSON.stringify(this.fileList2); |
|||
if (this.form.id != null) { |
|||
updateEnterpriseInfo(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("修改成功"); |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} else { |
|||
addEnterpriseInfo(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("新增成功"); |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} |
|||
} |
|||
}); |
|||
}, |
|||
|
|||
// 上传意见附件 |
|||
submitOpinionUpload(fileList, name) { |
|||
console.log(name, fileList); |
|||
this[name].push({ |
|||
name: fileList.name, |
|||
fileName: fileList.response.fileName, |
|||
url: fileList.response.url, |
|||
uid: fileList.uid, |
|||
}); |
|||
console.log(name, this[name]); |
|||
}, |
|||
handleOpinionRemove(file, name) { |
|||
// console.log(file, fileList1); |
|||
let index = this[name].findIndex((item) => item.uid === file.uid); |
|||
// 删除文件 |
|||
this[name].splice(index, 1); |
|||
}, |
|||
|
|||
// 点击预览的文件进行下载 |
|||
handleOpinionPreview(file) { |
|||
// console.log(file); |
|||
getFileStream({ fileName: file.fileName }).then((res) => { |
|||
const blob = new Blob([res], { |
|||
// type类型后端返回来的数据中会有,根据自己实际进行修改 |
|||
// 表格下载为 application/xlsx,压缩包为 application/zip等, |
|||
type: "application/xlsx", |
|||
}); //excel,pdf等 |
|||
const href = URL.createObjectURL(blob); //创建新的URL表示指定的blob对象 |
|||
const a = document.createElement("a"); //创建a标签 |
|||
a.style.display = "none"; |
|||
a.href = href; // 指定下载链接 |
|||
a.download = file.name; //指定下载文件名 |
|||
a.click(); //触发下载 |
|||
URL.revokeObjectURL(a.href); //释放URL对象 |
|||
}); |
|||
}, |
|||
handleOpinionExceed(files, fileList) { |
|||
this.$message.warning( |
|||
`当前限制选择 3 个文件,本次选择了 ${files.length} 个文件,共选择了 ${ |
|||
files.length + fileList.length |
|||
} 个文件` |
|||
); |
|||
}, |
|||
beforeOpinionRemove(file, fileList) { |
|||
return this.$confirm(`确定移除 ${file.name}?`); |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
|||
<style lang="scss" scoped> |
|||
@import "@/assets/css/dialog.scss"; |
|||
::v-deep { |
|||
.el-dialog { |
|||
margin-top: 2vh !important; |
|||
} |
|||
} |
|||
// .btnList { |
|||
// position: fixed; |
|||
// bottom: 20px; |
|||
// right: 20px; |
|||
// z-index: 1; |
|||
// } |
|||
.listTitle { |
|||
font-size: 14px; |
|||
padding-left: 10px; |
|||
padding-right: 30px; |
|||
margin: 20px 0; |
|||
border-left: 2px solid #36b29e; |
|||
display: flex; |
|||
justify-content: space-between; |
|||
span:nth-child(1) { |
|||
font-weight: bold; |
|||
} |
|||
.addBtn { |
|||
color: #36b29e; |
|||
cursor: pointer; |
|||
} |
|||
.addBtn:hover { |
|||
color: #31a08e; |
|||
} |
|||
} |
|||
</style> |
@ -0,0 +1,3 @@ |
|||
<template> |
|||
<div>市场行为与信用</div> |
|||
</template> |
@ -0,0 +1,403 @@ |
|||
<template> |
|||
<div class="app-container"> |
|||
<el-table |
|||
v-loading="loading" |
|||
:data="officeList" |
|||
@selection-change="handleSelectionChange" |
|||
> |
|||
<el-table-column type="selection" width="55" align="center" fixed /> |
|||
<el-table-column |
|||
label="序号" |
|||
type="index" |
|||
width="50" |
|||
align="center" |
|||
fixed |
|||
/> |
|||
<!-- <el-table-column |
|||
label="企业id" |
|||
align="center" |
|||
prop="enterpriseId" |
|||
min-width="120" |
|||
/> --> |
|||
<el-table-column |
|||
label="分公司名称" |
|||
align="center" |
|||
prop="branchOfficeName" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="公司类型" |
|||
align="center" |
|||
prop="companyType" |
|||
:formatter="companyTypeFormat" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="统一社会信用代码" |
|||
align="center" |
|||
prop="unifiedSocialCreditCode" |
|||
min-width="150" |
|||
/> |
|||
<el-table-column |
|||
label="统一社会信用代码证" |
|||
align="center" |
|||
prop="socialCreditCodeAttachment" |
|||
min-width="150" |
|||
/> |
|||
<el-table-column |
|||
label="注册资本金" |
|||
align="center" |
|||
prop="registeredCapital" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="法人代表" |
|||
align="center" |
|||
prop="legalRepresentative" |
|||
min-width="120" |
|||
/> |
|||
|
|||
<el-table-column |
|||
label="注册地址" |
|||
align="center" |
|||
prop="registeredAddress" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="操作" |
|||
align="center" |
|||
class-name="small-padding fixed-width" |
|||
width="180" |
|||
fixed="right" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-edit" |
|||
@click="handleUpdate(scope.row)" |
|||
v-hasPermi="['enterprise:office:edit']" |
|||
>修改</el-button |
|||
> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-delete" |
|||
@click="handleDelete(scope.row)" |
|||
v-hasPermi="['enterprise:office:remove']" |
|||
>删除</el-button |
|||
> |
|||
</template> |
|||
</el-table-column> |
|||
</el-table> |
|||
|
|||
<pagination |
|||
v-show="total > 0" |
|||
:total="total" |
|||
:page.sync="queryParams.pageNum" |
|||
:limit.sync="queryParams.pageSize" |
|||
@pagination="getList" |
|||
/> |
|||
|
|||
<!-- 添加或修改分公司信息对话框 --> |
|||
<el-dialog |
|||
:title="title" |
|||
:visible.sync="open" |
|||
width="1200px" |
|||
append-to-body |
|||
:close-on-click-modal="false" |
|||
> |
|||
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> |
|||
<el-form-item label="分公司名称" prop="branchOfficeName"> |
|||
<el-input |
|||
v-model="form.branchOfficeName" |
|||
placeholder="请输入分公司名称" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="公司类型" prop="companyType"> |
|||
<el-select |
|||
v-model="form.companyType" |
|||
placeholder="请选择公司类型" |
|||
style="width: 100%" |
|||
> |
|||
<el-option |
|||
v-for="dict in companyTypeOptions" |
|||
:key="dict.dictValue" |
|||
:label="dict.dictLabel" |
|||
:value="dict.dictValue" |
|||
></el-option> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item label="统一社会信用代码" prop="unifiedSocialCreditCode"> |
|||
<el-input |
|||
v-model="form.unifiedSocialCreditCode" |
|||
placeholder="请输入统一社会信用代码" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item |
|||
label="统一社会信用代码证" |
|||
prop="socialCreditCodeAttachment" |
|||
> |
|||
<el-input |
|||
v-model="form.socialCreditCodeAttachment" |
|||
placeholder="请输入统一社会信用代码证" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="注册资本金" prop="registeredCapital"> |
|||
<el-input |
|||
v-model="form.registeredCapital" |
|||
placeholder="请输入注册资本金" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="法人代表" prop="legalRepresentative"> |
|||
<el-input |
|||
v-model="form.legalRepresentative" |
|||
placeholder="请输入法人代表" |
|||
/> |
|||
</el-form-item> |
|||
|
|||
<el-form-item label="注册地址" prop="registeredAddress"> |
|||
<el-input |
|||
v-model="form.registeredAddress" |
|||
placeholder="请输入注册地址" |
|||
/> |
|||
</el-form-item> |
|||
<!-- <el-form-item label="企业id" prop="enterpriseId"> |
|||
<el-input v-model="form.enterpriseId" placeholder="请输入企业id" /> |
|||
</el-form-item> --> |
|||
</el-form> |
|||
<div slot="footer" class="dialog-footer"> |
|||
<el-button type="primary" @click="submitForm">确 定</el-button> |
|||
<el-button @click="cancel">取 消</el-button> |
|||
</div> |
|||
</el-dialog> |
|||
</div> |
|||
</template> |
|||
|
|||
<script> |
|||
import { |
|||
listOffice, |
|||
getOffice, |
|||
delOffice, |
|||
addOffice, |
|||
updateOffice, |
|||
exportOffice, |
|||
} from "@/api/enterprise/office"; |
|||
|
|||
export default { |
|||
name: "Office", |
|||
props: ["enterpriseId"], |
|||
data() { |
|||
return { |
|||
// 遮罩层 |
|||
loading: true, |
|||
// 选中数组 |
|||
ids: [], |
|||
// 非单个禁用 |
|||
single: true, |
|||
// 非多个禁用 |
|||
multiple: true, |
|||
// 显示搜索条件 |
|||
showSearch: true, |
|||
// 总条数 |
|||
total: 0, |
|||
// 分公司信息表格数据 |
|||
officeList: [], |
|||
// 弹出层标题 |
|||
title: "", |
|||
// 是否显示弹出层 |
|||
open: false, |
|||
// 公司类型字典 |
|||
companyTypeOptions: [], |
|||
// 查询参数 |
|||
queryParams: { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
ids: null, |
|||
data: { |
|||
branchOfficeName: null, |
|||
unifiedSocialCreditCode: null, |
|||
socialCreditCodeAttachment: null, |
|||
registeredCapital: null, |
|||
legalRepresentative: null, |
|||
companyType: null, |
|||
registeredAddress: null, |
|||
enterpriseId: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
owerDept: null, |
|||
}, |
|||
// 排序方式 |
|||
params: { |
|||
// 按哪个字段排序 |
|||
orderBy: "create_time", |
|||
// desc降序,升序asc |
|||
sort: "desc", |
|||
}, |
|||
}, |
|||
// 表单参数 |
|||
form: {}, |
|||
// 表单校验 |
|||
rules: {}, |
|||
}; |
|||
}, |
|||
created() { |
|||
this.getList(); |
|||
this.getDicts("company_type").then((response) => { |
|||
this.companyTypeOptions = response.data; |
|||
}); |
|||
}, |
|||
methods: { |
|||
/** 查询分公司信息列表 */ |
|||
getList() { |
|||
this.loading = true; |
|||
listOffice(this.queryParams).then((response) => { |
|||
this.officeList = response.records; |
|||
this.total = response.total; |
|||
this.loading = false; |
|||
}); |
|||
}, |
|||
// 公司类型字典翻译 |
|||
companyTypeFormat(row, column) { |
|||
return this.selectDictLabel(this.companyTypeOptions, row.companyType); |
|||
}, |
|||
// 取消按钮 |
|||
cancel() { |
|||
this.open = false; |
|||
this.reset(); |
|||
}, |
|||
// 表单重置 |
|||
reset() { |
|||
this.form = { |
|||
id: null, |
|||
branchOfficeName: null, |
|||
unifiedSocialCreditCode: null, |
|||
socialCreditCodeAttachment: null, |
|||
registeredCapital: null, |
|||
legalRepresentative: null, |
|||
companyType: null, |
|||
registeredAddress: null, |
|||
enterpriseId: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
remark: null, |
|||
owerDept: null, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
// 查询表单重置 |
|||
resetQueryForm() { |
|||
this.queryParams = { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
data: { |
|||
id: null, |
|||
branchOfficeName: null, |
|||
unifiedSocialCreditCode: null, |
|||
socialCreditCodeAttachment: null, |
|||
registeredCapital: null, |
|||
legalRepresentative: null, |
|||
companyType: null, |
|||
registeredAddress: null, |
|||
enterpriseId: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
remark: null, |
|||
owerDept: null, |
|||
}, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
/** 搜索按钮操作 */ |
|||
handleQuery() { |
|||
this.queryParams.pageNum = 1; |
|||
this.getList(); |
|||
}, |
|||
/** 重置按钮操作 */ |
|||
resetQuery() { |
|||
this.resetQueryForm(); |
|||
this.handleQuery(); |
|||
}, |
|||
// 多选框选中数据 |
|||
handleSelectionChange(selection) { |
|||
this.ids = selection.map((item) => item.id); |
|||
this.single = selection.length !== 1; |
|||
this.multiple = !selection.length; |
|||
}, |
|||
/** 新增按钮操作 */ |
|||
handleAdd() { |
|||
this.reset(); |
|||
this.open = true; |
|||
this.title = "添加分公司信息"; |
|||
}, |
|||
/** 修改按钮操作 */ |
|||
handleUpdate(row) { |
|||
this.reset(); |
|||
const id = row.id || this.ids; |
|||
getOffice(id).then((response) => { |
|||
this.form = response.data; |
|||
this.open = true; |
|||
this.title = "修改分公司信息"; |
|||
}); |
|||
}, |
|||
/** 提交按钮 */ |
|||
submitForm() { |
|||
this.$refs["form"].validate((valid) => { |
|||
if (valid) { |
|||
this.form.enterpriseId = this.enterpriseId; |
|||
if (this.form.id != null) { |
|||
updateOffice(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("修改成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} else { |
|||
addOffice(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("新增成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} |
|||
} |
|||
}); |
|||
}, |
|||
/** 删除按钮操作 */ |
|||
handleDelete(row) { |
|||
const ids = row.id || this.ids; |
|||
if (ids) { |
|||
this.$confirm("是否删除选中的数据?", "警告", { |
|||
confirmButtonText: "确定", |
|||
cancelButtonText: "取消", |
|||
type: "warning", |
|||
}) |
|||
.then(function () { |
|||
return delOffice(ids); |
|||
}) |
|||
.then(() => { |
|||
this.getList(); |
|||
this.msgSuccess("删除成功"); |
|||
}) |
|||
.catch(function () {}); |
|||
} else { |
|||
this.$message.warning("请选择要删除的数据!!"); |
|||
} |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
|||
<style lang="scss" scoped> |
|||
@import "@/assets/css/dialog.scss"; |
|||
//::v-deep { |
|||
// .el-dialog { |
|||
// margin-top: 10vh !important; |
|||
// } |
|||
//} |
|||
</style> |
@ -0,0 +1,453 @@ |
|||
<template> |
|||
<div class="app-container"> |
|||
<el-table |
|||
v-loading="loading" |
|||
:data="systemList" |
|||
@selection-change="handleSelectionChange" |
|||
> |
|||
<el-table-column type="selection" width="55" align="center" fixed /> |
|||
<el-table-column |
|||
label="序号" |
|||
type="index" |
|||
width="50" |
|||
align="center" |
|||
fixed |
|||
/> |
|||
<!-- <el-table-column |
|||
label="企业id" |
|||
align="center" |
|||
prop="enterpriseId" |
|||
min-width="120" |
|||
/> --> |
|||
<el-table-column |
|||
label="体系名称" |
|||
align="center" |
|||
prop="systemName" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="有效期至" |
|||
align="center" |
|||
prop="validityPeriod" |
|||
min-width="120" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<span>{{ parseTime(scope.row.validityPeriod, "{y}-{m}-{d}") }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column |
|||
label="发证机关" |
|||
align="center" |
|||
prop="licenceIssuingAuthority" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="认证范围" |
|||
align="center" |
|||
prop="certificationScope" |
|||
min-width="120" |
|||
/> |
|||
<el-table-column |
|||
label="标准规范" |
|||
align="center" |
|||
prop="standardSpecification" |
|||
min-width="120" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<div |
|||
v-for="(item, index) in JSON.parse(scope.row.standardSpecification)" |
|||
:key="item + index" |
|||
> |
|||
<i class="el-icon-document"></i> |
|||
{{ item.name }} |
|||
<i |
|||
class="el-icon-download" |
|||
@click="downloadFile(scope, index)" |
|||
style="cursor: pointer" |
|||
></i> |
|||
</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column |
|||
label="操作" |
|||
align="center" |
|||
class-name="small-padding fixed-width" |
|||
width="180" |
|||
fixed="right" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-edit" |
|||
@click="handleUpdate(scope.row)" |
|||
v-hasPermi="['enterprise:system:edit']" |
|||
>修改</el-button |
|||
> |
|||
<el-button |
|||
size="mini" |
|||
type="text" |
|||
icon="el-icon-delete" |
|||
@click="handleDelete(scope.row)" |
|||
v-hasPermi="['enterprise:system:remove']" |
|||
>删除</el-button |
|||
> |
|||
</template> |
|||
</el-table-column> |
|||
</el-table> |
|||
|
|||
<pagination |
|||
v-show="total > 0" |
|||
:total="total" |
|||
:page.sync="queryParams.pageNum" |
|||
:limit.sync="queryParams.pageSize" |
|||
@pagination="getList" |
|||
/> |
|||
|
|||
<!-- 添加或修改管理体系信息对话框 --> |
|||
<el-dialog |
|||
:title="title" |
|||
:visible.sync="open" |
|||
width="1200px" |
|||
append-to-body |
|||
:close-on-click-modal="false" |
|||
> |
|||
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> |
|||
<!-- <el-form-item label="企业id" prop="enterpriseId"> |
|||
<el-input v-model="form.enterpriseId" placeholder="请输入企业id" /> |
|||
</el-form-item> --> |
|||
<el-form-item label="体系名称" prop="systemName"> |
|||
<el-input v-model="form.systemName" placeholder="请输入体系名称" /> |
|||
</el-form-item> |
|||
<el-form-item label="有效期至" prop="validityPeriod"> |
|||
<el-date-picker |
|||
clearable |
|||
size="small" |
|||
style="width: 100%" |
|||
v-model="form.validityPeriod" |
|||
type="date" |
|||
value-format="yyyy-MM-dd" |
|||
placeholder="选择有效期至" |
|||
> |
|||
</el-date-picker> |
|||
</el-form-item> |
|||
<el-form-item label="发证机关" prop="licenceIssuingAuthority"> |
|||
<el-input |
|||
v-model="form.licenceIssuingAuthority" |
|||
placeholder="请输入发证机关" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="认证范围" prop="certificationScope"> |
|||
<el-input |
|||
v-model="form.certificationScope" |
|||
placeholder="请输入认证范围" |
|||
/> |
|||
</el-form-item> |
|||
<el-form-item label="标准规范" prop="standardSpecification"> |
|||
<!-- <el-input |
|||
v-model="form.standardSpecification" |
|||
placeholder="请输入标准规范" |
|||
/> --> |
|||
<el-upload |
|||
class="upload-demo" |
|||
action="thinking/common/upload" |
|||
:headers="headers" |
|||
:on-preview="handlePreview" |
|||
:on-remove="(file) => handleRemove(file, 'fileList')" |
|||
:before-remove="beforeRemove" |
|||
multiple |
|||
:on-exceed="handleExceed" |
|||
:on-success="(_, fileList) => submitUpload(fileList, 'fileList')" |
|||
:file-list="fileList" |
|||
> |
|||
<el-button size="small" type="primary" plain> |
|||
<i class="el-icon-upload el-icon--right"></i> |
|||
点击上传 |
|||
</el-button> |
|||
<div slot="tip" class="el-upload__tip"> |
|||
支持jpg/png/pdf/word/excel文件等,不超过100M |
|||
</div> |
|||
</el-upload> |
|||
</el-form-item> |
|||
</el-form> |
|||
<div slot="footer" class="dialog-footer"> |
|||
<el-button type="primary" @click="submitForm">确 定</el-button> |
|||
<el-button @click="cancel">取 消</el-button> |
|||
</div> |
|||
</el-dialog> |
|||
</div> |
|||
</template> |
|||
|
|||
<script> |
|||
import { |
|||
listSystem, |
|||
getSystem, |
|||
delSystem, |
|||
addSystem, |
|||
updateSystem, |
|||
exportSystem, |
|||
} from "@/api/enterprise/system"; |
|||
import { getToken } from "@/utils/auth"; |
|||
import { getFileStream } from "@/api/system/upload"; |
|||
|
|||
export default { |
|||
name: "System", |
|||
props: ["enterpriseId"], |
|||
data() { |
|||
return { |
|||
// 遮罩层 |
|||
loading: true, |
|||
// 选中数组 |
|||
ids: [], |
|||
// 非单个禁用 |
|||
single: true, |
|||
// 非多个禁用 |
|||
multiple: true, |
|||
// 显示搜索条件 |
|||
showSearch: true, |
|||
// 总条数 |
|||
total: 0, |
|||
// 管理体系信息表格数据 |
|||
systemList: [], |
|||
// 弹出层标题 |
|||
title: "", |
|||
// 是否显示弹出层 |
|||
open: false, |
|||
// 查询参数 |
|||
queryParams: { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
ids: null, |
|||
data: { |
|||
enterpriseId: null, |
|||
systemName: null, |
|||
validityPeriod: null, |
|||
licenceIssuingAuthority: null, |
|||
certificationScope: null, |
|||
standardSpecification: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
owerDept: null, |
|||
}, |
|||
// 排序方式 |
|||
params: { |
|||
// 按哪个字段排序 |
|||
orderBy: "create_time", |
|||
// desc降序,升序asc |
|||
sort: "desc", |
|||
}, |
|||
}, |
|||
// 表单参数 |
|||
form: {}, |
|||
// 表单校验 |
|||
rules: {}, |
|||
// 请求头 |
|||
headers: { |
|||
jianwei: "jwtech " + getToken(), |
|||
}, |
|||
fileList: [], |
|||
}; |
|||
}, |
|||
created() { |
|||
this.getList(); |
|||
}, |
|||
methods: { |
|||
/** 查询管理体系信息列表 */ |
|||
getList() { |
|||
this.loading = true; |
|||
listSystem(this.queryParams).then((response) => { |
|||
this.systemList = response.records; |
|||
this.total = response.total; |
|||
this.loading = false; |
|||
}); |
|||
}, |
|||
// 取消按钮 |
|||
cancel() { |
|||
this.open = false; |
|||
this.reset(); |
|||
}, |
|||
// 表单重置 |
|||
reset() { |
|||
this.form = { |
|||
id: null, |
|||
enterpriseId: null, |
|||
systemName: null, |
|||
validityPeriod: null, |
|||
licenceIssuingAuthority: null, |
|||
certificationScope: null, |
|||
standardSpecification: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
remark: null, |
|||
owerDept: null, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
// 查询表单重置 |
|||
resetQueryForm() { |
|||
this.queryParams = { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
data: { |
|||
id: null, |
|||
enterpriseId: null, |
|||
systemName: null, |
|||
validityPeriod: null, |
|||
licenceIssuingAuthority: null, |
|||
certificationScope: null, |
|||
standardSpecification: null, |
|||
createUid: null, |
|||
updateUid: null, |
|||
createTime: null, |
|||
updateTime: null, |
|||
remark: null, |
|||
owerDept: null, |
|||
}, |
|||
}; |
|||
this.resetForm("form"); |
|||
}, |
|||
/** 搜索按钮操作 */ |
|||
handleQuery() { |
|||
this.queryParams.pageNum = 1; |
|||
this.getList(); |
|||
}, |
|||
/** 重置按钮操作 */ |
|||
resetQuery() { |
|||
this.resetQueryForm(); |
|||
this.handleQuery(); |
|||
}, |
|||
// 多选框选中数据 |
|||
handleSelectionChange(selection) { |
|||
this.ids = selection.map((item) => item.id); |
|||
this.single = selection.length !== 1; |
|||
this.multiple = !selection.length; |
|||
}, |
|||
/** 新增按钮操作 */ |
|||
handleAdd() { |
|||
this.reset(); |
|||
this.open = true; |
|||
this.title = "添加管理体系信息"; |
|||
}, |
|||
/** 修改按钮操作 */ |
|||
handleUpdate(row) { |
|||
this.reset(); |
|||
const id = row.id || this.ids; |
|||
getSystem(id).then((response) => { |
|||
this.form = response.data; |
|||
if (this.form.standardSpecification) { |
|||
this.fileList = JSON.parse(this.form.standardSpecification); |
|||
} |
|||
this.open = true; |
|||
this.title = "修改管理体系信息"; |
|||
}); |
|||
}, |
|||
/** 提交按钮 */ |
|||
submitForm() { |
|||
this.$refs["form"].validate((valid) => { |
|||
if (valid) { |
|||
this.form.enterpriseId = this.enterpriseId; |
|||
this.form.standardSpecification = JSON.stringify(this.fileList); |
|||
if (this.form.id != null) { |
|||
updateSystem(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("修改成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} else { |
|||
addSystem(this.form).then((response) => { |
|||
if (response.code === 200) { |
|||
this.msgSuccess("新增成功"); |
|||
this.open = false; |
|||
this.getList(); |
|||
} |
|||
}); |
|||
} |
|||
} |
|||
}); |
|||
}, |
|||
/** 删除按钮操作 */ |
|||
handleDelete(row) { |
|||
const ids = row.id || this.ids; |
|||
if (ids) { |
|||
this.$confirm("是否删除选中的数据?", "警告", { |
|||
confirmButtonText: "确定", |
|||
cancelButtonText: "取消", |
|||
type: "warning", |
|||
}) |
|||
.then(function () { |
|||
return delSystem(ids); |
|||
}) |
|||
.then(() => { |
|||
this.getList(); |
|||
this.msgSuccess("删除成功"); |
|||
}) |
|||
.catch(function () {}); |
|||
} else { |
|||
this.$message.warning("请选择要删除的数据!!"); |
|||
} |
|||
}, |
|||
submitOpinionUpload(fileList, name) { |
|||
console.log(name, fileList); |
|||
this[name].push({ |
|||
name: fileList.name, |
|||
fileName: fileList.response.fileName, |
|||
url: fileList.response.url, |
|||
uid: fileList.uid, |
|||
}); |
|||
console.log(name, this[name]); |
|||
}, |
|||
handleRemove(file, name) { |
|||
// console.log(file, fileList1); |
|||
let index = this[name].findIndex((item) => item.uid === file.uid); |
|||
// 删除文件 |
|||
this[name].splice(index, 1); |
|||
}, |
|||
downloadFile(scope, index) { |
|||
// console.log(scope); |
|||
let file = JSON.parse(scope.row.standardSpecification)[index]; |
|||
this.handlePreview(file); |
|||
}, |
|||
|
|||
// 点击预览的文件进行下载 |
|||
handlePreview(file) { |
|||
// console.log(file); |
|||
getFileStream({ fileName: file.fileName }).then((res) => { |
|||
const blob = new Blob([res], { |
|||
// type类型后端返回来的数据中会有,根据自己实际进行修改 |
|||
// 表格下载为 application/xlsx,压缩包为 application/zip等, |
|||
type: "application/xlsx", |
|||
}); //excel,pdf等 |
|||
const href = URL.createObjectURL(blob); //创建新的URL表示指定的blob对象 |
|||
const a = document.createElement("a"); //创建a标签 |
|||
a.style.display = "none"; |
|||
a.href = href; // 指定下载链接 |
|||
a.download = file.name; //指定下载文件名 |
|||
a.click(); //触发下载 |
|||
URL.revokeObjectURL(a.href); //释放URL对象 |
|||
}); |
|||
}, |
|||
handleExceed(files, fileList) { |
|||
this.$message.warning( |
|||
`当前限制选择 3 个文件,本次选择了 ${files.length} 个文件,共选择了 ${ |
|||
files.length + fileList.length |
|||
} 个文件` |
|||
); |
|||
}, |
|||
beforeRemove(file, fileList) { |
|||
return this.$confirm(`确定移除 ${file.name}?`); |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
|||
<style lang="scss" scoped> |
|||
@import "@/assets/css/dialog.scss"; |
|||
//::v-deep { |
|||
// .el-dialog { |
|||
// margin-top: 10vh !important; |
|||
// } |
|||
//} |
|||
</style> |
@ -0,0 +1,3 @@ |
|||
<template> |
|||
<div>动态信用</div> |
|||
</template> |
@ -0,0 +1,149 @@ |
|||
<template> |
|||
<div class="app-container"> |
|||
<!-- 面包屑 --> |
|||
<el-breadcrumb separator="/" style="margin-bottom: 20px"> |
|||
<el-breadcrumb-item |
|||
v-for="(item, index) in routeList" |
|||
:key="item + index" |
|||
:to="routeList.length !== index + 1 ? { path: item.path } : undefined" |
|||
>{{ item.routeName }}</el-breadcrumb-item |
|||
> |
|||
</el-breadcrumb> |
|||
|
|||
<el-page-header |
|||
@back="goBack" |
|||
:content="routeList[1].routeName" |
|||
style="margin-bottom: 15px" |
|||
> |
|||
</el-page-header> |
|||
|
|||
<el-tabs |
|||
v-model="activeName" |
|||
@tab-click="handleClick" |
|||
style="margin-bottom: 20px" |
|||
> |
|||
<el-tab-pane label="企业基础情况" name="basePage" :lazy="true"> |
|||
<basePage ref="basePage" /> |
|||
</el-tab-pane> |
|||
<el-tab-pane |
|||
label="企业资质" |
|||
name="qualification" |
|||
:disabled="!routeList[1].isEdit" |
|||
:lazy="true" |
|||
> |
|||
<qualification /> |
|||
</el-tab-pane> |
|||
<el-tab-pane |
|||
label="人力资源档案" |
|||
name=" resourcesArchives" |
|||
:disabled="!routeList[1].isEdit" |
|||
:lazy="true" |
|||
> |
|||
<resourcesArchives /> |
|||
</el-tab-pane> |
|||
<el-tab-pane |
|||
label="工程业绩记录" |
|||
name=" performanceRecord" |
|||
:disabled="!routeList[1].isEdit" |
|||
:lazy="true" |
|||
> |
|||
<performanceRecord /> |
|||
</el-tab-pane> |
|||
<el-tab-pane |
|||
label="市场行为与信用" |
|||
name=" behaviorAndCredit" |
|||
:disabled="!routeList[1].isEdit" |
|||
:lazy="true" |
|||
> |
|||
<behaviorAndCredit /> |
|||
</el-tab-pane> |
|||
<el-tab-pane |
|||
label="动态信用" |
|||
name=" dynamicCredit" |
|||
:disabled="!routeList[1].isEdit" |
|||
:lazy="true" |
|||
> |
|||
<dynamicCredit /> |
|||
</el-tab-pane> |
|||
</el-tabs> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import basePage from "./basePage.vue"; |
|||
import qualification from "./qualification.vue"; |
|||
import resourcesArchives from "./resourcesArchives.vue"; |
|||
import performanceRecord from "./performanceRecord.vue"; |
|||
import behaviorAndCredit from "./behaviorAndCredit.vue"; |
|||
import dynamicCredit from "./dynamicCredit.vue"; |
|||
|
|||
// import { |
|||
// listProjectinfo, |
|||
// getProjectinfo, |
|||
// delProjectinfo, |
|||
// addProjectinfo, |
|||
// updateProjectinfo, |
|||
// exportProjectinfo, |
|||
// } from "@/api/earlyStage/projectinfo"; |
|||
|
|||
export default { |
|||
components: { |
|||
basePage, |
|||
qualification, |
|||
resourcesArchives, |
|||
performanceRecord, |
|||
behaviorAndCredit, |
|||
dynamicCredit, |
|||
}, |
|||
data() { |
|||
return { |
|||
activeName: "basePage", |
|||
routeList: [], |
|||
formData: {}, |
|||
// 查询参数 |
|||
queryParams: { |
|||
pageNum: 1, |
|||
pageSize: 10, |
|||
ids: null, |
|||
data: { |
|||
projectName: null, |
|||
projectType: null, |
|||
}, |
|||
// 排序方式 |
|||
params: { |
|||
// 按哪个字段排序 |
|||
orderBy: "create_time", |
|||
// desc降序,升序asc |
|||
sort: "desc", |
|||
}, |
|||
}, |
|||
}; |
|||
}, |
|||
created() { |
|||
this.routeList = JSON.parse(this.$store.state.basePageData.routeList); |
|||
// if (this.routeList[1].isEdit) { |
|||
// // this.formData = JSON.parse(this.$store.state.basePageData.baseFormData); |
|||
// this.formData = JSON.parse(this.$store.state.basePageData.baseFormData); |
|||
// } |
|||
this.getList(); |
|||
}, |
|||
methods: { |
|||
goBack() { |
|||
this.$router.back(); |
|||
}, |
|||
/** 查询专题项目前期背景信息列表 */ |
|||
getList() { |
|||
this.queryParams.data.id = this.$route.query.baseDataId; |
|||
// listProjectinfo(this.queryParams).then((response) => { |
|||
// this.formData = response.records[0]; |
|||
// }); |
|||
}, |
|||
|
|||
// 切换标签页 |
|||
handleClick(tab, event) { |
|||
// console.log("切换标签页", tab, event); |
|||
// console.log("切换标签页", this.routeList[1].routeName); |
|||
this.routeList[1].routeName = tab.label; |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
@ -0,0 +1,3 @@ |
|||
<template> |
|||
<div>工程业绩记录</div> |
|||
</template> |
@ -0,0 +1,3 @@ |
|||
<template> |
|||
<div>企业资质</div> |
|||
</template> |
@ -0,0 +1,3 @@ |
|||
<template> |
|||
<div>人力资源档案</div> |
|||
</template> |
Loading…
Reference in new issue