cf787f76 by renchao@pashanhoo.com

style: 企业信息备案

1 parent f63c044a
/*
* @Description: 企业银行接口
* @Autor: renchao
* @LastEditTime: 2023-09-07 14:42:19
*/
import request from '@/utils/request'
let SERVER = window.config ? window.config : JSON.parse(localStorage.getItem('ApiUrl'))
/**
* @description: 获取材料目录
* @author: renchao
*/
export function getCompanyMaterialList (bsmCompany) {
return request({
url: SERVER.SERVERAPI + '/rest/sys/company/getCompanyMaterialList',
method: 'get',
params: {
bsmCompany: bsmCompany
}
})
}
\ No newline at end of file
<template>
<el-form ref="ruleForm" :model="ruleForm" label-width="100px" :rules="rules">
<el-row>
<el-col :span="12">
<el-form-item label="企业名称:" prop="qymc">
<el-input v-model="ruleForm.qymc"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="电话:" prop="dh">
<el-input v-model="ruleForm.dh"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="证件种类:">
<el-input v-model="ruleForm.zjzl"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="证件号:" prop="zjh">
<el-input v-model="ruleForm.zjh"></el-input>
</el-form-item>
</el-col>
</el-row>
<div style="height:650px">
<el-tabs v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="企业信息" name="1"></el-tab-pane>
<el-tab-pane label="材料信息" v-if="formData.isAdd==2" name="2"></el-tab-pane>
</el-tabs>
<el-form ref="ruleForm" :model="ruleForm" label-width="100px" style="height:90%" v-if="activeName==1" :rules="rules">
<div style="height:90%">
<el-row>
<el-col :span="12">
<el-form-item label="企业名称:" prop="qymc">
<el-input v-model="ruleForm.qymc"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="电话:" prop="dh">
<el-input v-model="ruleForm.dh"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="证件种类:">
<el-input v-model="ruleForm.zjzl"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="证件号:" prop="zjh">
<el-input v-model="ruleForm.zjh"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="法人名称:" prop="frmc">
<el-input v-model="ruleForm.frmc"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="法人电话:" prop="frdh">
<el-input v-model="ruleForm.frdh"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="单位地址:">
<el-input v-model="ruleForm.dwdz"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="邮编:" prop="yb">
<el-input v-model="ruleForm.yb"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item style="text-align:center">
<el-button @click="closeDialog">取消</el-button>
<el-button type="primary" @click="submitForm">保存</el-button>
</el-form-item>
</el-form>
<el-row>
<el-col :span="12">
<el-form-item label="法人名称:" prop="frmc">
<el-input v-model="ruleForm.frmc"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="法人电话:" prop="frdh">
<el-input v-model="ruleForm.frdh"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="单位地址:">
<el-input v-model="ruleForm.dwdz"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="邮编:" prop="yb">
<el-input v-model="ruleForm.yb"></el-input>
</el-form-item>
</el-col>
</el-row>
</div>
<el-form-item style="text-align:center">
<el-button @click="closeDialog">取消</el-button>
<el-button type="primary" @click="submitForm">保存</el-button>
</el-form-item>
</el-form>
<clxx v-if="activeName==2" :formData="formData" />
</div>
</template>
<script>
import store from '@/store/index.js'
import { addQy } from "@/api/xxba.js"
import clxx from './clxx/index.vue'
export default {
props: {
formData: {
......@@ -66,8 +76,12 @@
default: () => { },
},
},
components: {
clxx
},
data () {
return {
activeName: "1",
DJJGLIST: store.getters.dictData['ywly'],
readOnly: false,
//表单提交数据
......@@ -129,6 +143,7 @@
} else { }
},
methods: {
handleClick () { },
/**
* @description: 表单提交
* @author: renchao
......@@ -173,48 +188,6 @@
})
},
/**
* @description: 印刷序列号处理
* @param {*} item
* @author: renchao
*/
ysxlhDeal (item) {
if (item.ksysxlh && item.jsysxlh) {
if (item.ksysxlh.length == item.jsysxlh.length) {
if (item.ksysxlh.length != 11) {
item.bs = -1;
return;
}
if (item.ksysxlh > item.jsysxlh) {
item.bs = -1;
return;
}
item.bs = item.jsysxlh - item.ksysxlh + 1;
if (item.zslx == 1) {
this.ruleForm.zsstarno = item.ksysxlh;
this.ruleForm.zsendno = item.jsysxlh;
this.ruleForm.zsnum = item.bs
} else if (item.zslx == 2) {
this.ruleForm.zmstarno = item.ksysxlh;
this.ruleForm.zmendno = item.jsysxlh;
this.ruleForm.zmnum = item.bs
}
} else {
item.bs = -1;
}
} else {
item.bs = 0;
if (item.zslx == 1) {
this.ruleForm.zsstarno = '';
this.ruleForm.zsendno = '';
this.ruleForm.zsnum = item.bs
} else if (item.zslx == 2) {
this.ruleForm.zmstarno = '';
this.ruleForm.zmendno = '';
this.ruleForm.zmnum = item.bs
}
}
},
/**
* @description: resetTableFields
* @author: renchao
*/
......
<!--
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-09-07 15:04:46
-->
<template>
<dialogBox title="新建材料信息" width="20%" isMain v-model="myValue" @closeDialog="closeDialog" @submitForm="handleSubmit"
:isFullscreen="false">
<el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="80px">
<el-row>
<el-col :span="24">
<el-form-item label="材料类型" prop="cllx">
<el-select v-model="ruleForm.cllx" class="width100" placeholder="请选择">
<el-option v-for="item in cllxList" :key="item.dcode" :label="item.dname" :value="item.dcode">
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20">
<el-col :span="24">
<el-form-item label="材料名称" prop="clmc">
<el-input v-model="ruleForm.clmc"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
</dialogBox>
</template>
<script>
import store from '@/store/index.js'
export default {
props: {
value: { type: Boolean, default: false },
},
data () {
return {
cllxList: store.getters.dictData['A40'],
myValue: this.value,
ruleForm: {
cllx: "",
clmc: "",
},
rules: {
cllx: [
{ required: true, message: '请选择材料类型', trigger: 'change' }
],
clmc: [
{ required: true, message: '请输入材料名称', trigger: 'blur' }
]
}
}
},
watch: {
value (val) {
this.myValue = val;
},
},
methods: {
/**
* @description: closeDialog
* @author: renchao
*/
closeDialog () {
this.$emit("input", false);
this.ruleForm = {
cllx: "",
clmc: "",
}
},
/**
* @description: handleSubmit
* @author: renchao
*/
handleSubmit () {
this.$refs['ruleForm'].validate((valid) => {
if (valid) {
this.$parent.addSave(this.ruleForm);
this.ruleForm = {
cllx: "",
clmc: "",
}
this.$emit("input", false);
} else {
return false;
}
})
}
}
};
</script>
<style scoped lang="scss">
.submit-button {
text-align: center;
height: 52px;
padding-top: 10px;
background-color: #fff;
}
</style>
<!--
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-08-15 09:43:46
-->
<template>
<div class="clmlmx-box">
<lb-table :column="column" :key="key" :heightNumSetting="true" :calcHeight="600" :pagination="false" :data="tableData">
</lb-table>
<div class="text-center">
<el-button @click="$popupCacel">取消</el-button>
<el-button type="primary" @click="handleSubmit" :loading="loading" v-if="formData.ableOperation && tableData.length>0">保存</el-button>
</div>
</div>
</template>
<script>
import Vue from 'vue'
import store from '@/store/index.js'
import { InitClml, updateClml, deleteSjClml, moveClml } from "@/api/clxx.js";
export default {
props: {
formData: {
type: Object,
default: () => {
return {}
}
}
},
data () {
return {
loading: false,
column: [
{
width: "50",
label: '序号',
type: 'index'
},
{
prop: "isrequired",
label: "是否必选",
width: "80",
render: (h, scope) => {
if (scope.row.isrequired === "1") {
return (
<div>
<span>必选</span>
</div>
);
}
else {
return (
<div>
<span>可选</span>
</div>
)
}
}
},
{
label: "材料名称",
render: (h, scope) => {
return (
(this.formData.ableOperation && scope.row.isrequired != '1') ?
<el-input value={scope.row.sjmc} onInput={(val) => { scope.row.sjmc = val }}></el-input> : <span>{scope.row.sjmc}</span>
)
}
},
{
label: "材料类型",
width: "110",
render: (h, scope) => {
return (
this.formData.ableOperation ?
<el-select value={scope.row.sjlx}
onChange={(val) => { scope.row.sjlx = val }}>
{
store.getters.dictData['A40'].map(option => {
return (
<el-option label={option.dname} value={option.dcode}></el-option>
)
})
}
</el-select> : <span>{this.dicStatus(scope.row.sjlx, "A40")}</span>
)
}
},
{
prop: "sjsl",
label: "份数",
width: "50",
render: (h, scope) => {
return (
<div>
{
scope.row.sjsl ?
<span>{scope.row.sjsl}</span> : 1
}
</div>
)
}
},
{
prop: "smzt",
label: "扫描状态",
width: "80",
render: (h, scope) => {
if (scope.row.children && scope.row.children.length > 0) {
return (
<div>
<span>已扫描</span>
</div>
);
} else {
return (
<div>
<span>未扫描</span>
</div>
);
}
},
},
{
label: "扫描页数",
width: "80",
render: (h, scope) => {
if (scope.row.children && scope.row.children.length > 0) {
return (
<div>
<span>{scope.row.children.length}</span>
</div>
);
} else {
return (
<div>
<span>0</span>
</div>
);
}
},
},
{
label: "操作",
width: "100",
render: (h, scope) => {
return (
<div>
<el-button
type="text"
disabled={scope.$index == 0 || !this.formData.ableOperation}
onClick={() => {
this.moveUpward(scope.$index, scope.row);
}}
>
上移
</el-button>
<el-button
type="text"
disabled={scope.$index + 1 == this.tableData.length || !this.formData.ableOperation}
onClick={() => {
this.moveDown(scope.$index, scope.row);
}}
>
下移
</el-button>
<i v-show={scope.row.isrequired != '1' && this.formData.ableOperation} onClick={() => {
this.handleDelete(scope.$index, scope.row);
}} class="el-icon-delete pointer" style="color:#409EFF;margin-left:5px;position: relative;top: 1px;"></i>
</div >
)
}
}
],
key: 0,
tableData: []
}
},
watch: {
'formData.data': {
handler: function (val, oldVal) {
this.tableData = _.cloneDeep(val)
},
immediate: true,
deep: true
}
},
methods: {
handleSubmit () {
this.loading = true
updateClml(this.tableData).then(res => {
this.loading = false
if (res.code == 200) {
this.$message({
message: '保存成功',
type: 'success'
})
this.$popupCacel()
store.dispatch('user/reWorkFresh', true)
}
}).catch(() => {
this.loading = false
})
},
/**
* @description: 材料目录明细初始化
* @author: renchao
*/
clmlInitList () {
return new Promise(resolve => {
this.unitData = this.$parent.unitData;
var formdata = new FormData();
formdata.append("bsmSlsq", Vue.prototype.$currentRoute.query.bsmSlsq);
if (Vue.prototype.$currentRoute.query.sqywbm == "DJBBL") {
formdata.append("bsmSldy", this.formData.bsmRepair);
formdata.append("clfl", 3);
} else {
formdata.append("bsmSldy", this.formData.unitData[0]?.bsmSldy);
formdata.append("clfl", 2);
}
InitClml(formdata).then((res) => {
if (res.code == 200) {
resolve(res.code)
if (res.result && res.result.length > 0) {
this.tableData = res.result;
} else {
this.tableData = []
}
} else {
this.$message.error(res.message)
}
})
})
},
/**
* @description: 上移
* @param {*} index
* @param {*} row
* @author: renchao
*/
moveUpward (index, row) {
let obj = {
xh: row.xh,
bsmSlsq: row.bsmSlsq,
moveDirection: "UP",
};
// 接口待调
moveClml(obj).then(async (res) => {
if (res.code == 200) {
let res = await this.clmlInitList()
if (res == 200) {
this.$message({
message: '上移成功',
type: 'success'
})
}
} else {
this.$message.error(res.message);
}
})
},
/**
* @description: 下移
* @param {*} index
* @param {*} row
* @author: renchao
*/
moveDown (index, row) {
let obj = {
xh: row.xh,
bsmSlsq: row.bsmSlsq,
moveDirection: "DOWN",
}
// 接口待调
moveClml(obj).then(async (res) => {
if (res.code == 200) {
let res = await this.clmlInitList()
if (res == 200) {
this.$message({
message: '下移成功',
type: 'success'
})
}
} else {
this.$message.error(res.message);
}
})
},
/**
* @description: 材料目录删除
* @param {*} index
* @param {*} row
* @author: renchao
*/
handleDelete (index, row) {
let that = this
this.$confirm('此操作将永久删除该 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteSjClml({ sjBsm: row.bsmSj }).then(async (res) => {
if (res.code == 200) {
let res = await that.clmlInitList()
if (res == 200) {
that.$message({
message: "删除成功",
type: "success"
})
}
}
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消删除'
})
})
},
// 字典
/**
* @description: 字典
* @param {*} val
* @param {*} code
* @author: renchao
*/
dicStatus (val, code) {
let data = store.getters.dictData[code],
name = "暂无";
if (data) {
data.map((item) => {
if (item.dcode == val) {
name = item.dname;
}
});
return name;
}
}
}
}
</script>
<style scoped lang='scss'>
@import "~@/styles/mixin.scss";
.clmlmx-box {
margin: 0 auto;
.title {
text-align: center;
height: 60px;
line-height: 60px;
border: 1px solid #dfe6ec;
font-size: 20px;
background: #81d3f81a;
margin-bottom: -1px;
}
}
</style>
<!--
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-09-07 15:06:42
-->
<template>
<div class="clxx">
<div class="right">
<!-- 材料预览 -->
<div class="clyl-box">
<div class="menu-tree">
<el-button
type="primary"
native-type="submit"
@click="viewDetail"
style="width: 100%; margin-top: 10px" v-if="tableData.length > 0">申请材料目录</el-button>
<div class="item">
材料目录({{ tableData.length }})
<div style="margin-top: 10px">
<div
style="
text-align: center;
line-height: 20px;
color: black;
font-size: 14px;
"
v-if="tableData.length == 0">
暂无数据
</div>
<div
v-for="(item, index) in tableData"
:key="item.bsmSj"
:class="['child', treeCheckId == item.bsmSj ? 'checked' : '']"
@click="treeClick(item, index)">
<span v-if="item.isrequired == 1" class="required">必选</span>
{{ item.sjmc }}
<span class="cl_number" :key="key">({{ item.children ? item.children.length : 0 }})</span>
</div>
</div>
</div>
<el-button
type="primary"
native-type="submit"
style="width: 100%"
@click="handleAdd()">新增</el-button>
</div>
<image-preview
ref="imageRef"
v-if="tableData.length > 0"
:previewImg="previewImg"
@updateList="updateList"
@nextPriview="nextPriview"
@prevPriview="prevPriview" />
</div>
</div>
<clxxAddDialog v-model="isDialog" />
</div>
</template>
<script>
import store from '@/store/index.js'
import clxxAddDialog from "./dialog/clxxAddDialog.vue";
import clxxDetailDialog from "./dialog/clxxDetailDialog.vue";
import imagePreview from "@/views/components/imagePreview.vue";
import { getCompanyMaterialList } from "@/api/company.js";
export default {
components: { clxxAddDialog, imagePreview, clxxDetailDialog },
props: {
formData: {
type: Object,
default: () => {
return {}
}
}
},
data () {
return {
isDialog: false,
iclass: "",
// 材料目录选中
treeCheckIndex: 0,
treeCheckId: "",
key: 0,
tableData: [],
previewImg: {
// 收件标识码
bsmSj: "",
bsmSlsq: this.$parent.bsmSlsq,
index: 0,
selectedIndex: 0,
imgList: [],
},
};
},
created () {
this.clmlInitList();
},
methods: {
/**
* @description: 自动预览
* @author: renchao
*/
nextPriview () {
if (this.treeCheckIndex < this.tableData.length) {
this.treeCheckIndex++;
this.treeCheckId = this.tableData[this.treeCheckIndex].bsmSj;
this.previewImg.index = 0;
this.previewImg.imgList = this.tableData[this.treeCheckIndex].children;
this.previewImg.bsmSj = this.tableData[this.treeCheckIndex].bsmSj;
}
},
/**
* @description: prevPriview
* @author: renchao
*/
prevPriview () {
if (this.treeCheckIndex >= 1) {
this.treeCheckIndex--;
this.treeCheckId = this.tableData[this.treeCheckIndex].bsmSj;
this.previewImg.index = this.previewImg.imgList.length;
this.previewImg.imgList = this.tableData[this.treeCheckIndex].children;
this.previewImg.bsmSj = this.tableData[this.treeCheckIndex].bsmSj;
}
},
/**
* @description: 材料目录明细初始化
* @param {*} type
* @author: renchao
*/
clmlInitList (type) {
// 1:列表初始化 2:新增材料
return new Promise((resolve) => {
getCompanyMaterialList(this.formData.bsmCompany).then((res) => {
if (res.code == 200) {
resolve(res.code);
if (res.result && res.result.length > 0) {
this.tableData = res.result;
if (type == 1) {
this.treeClick(this.tableData[0], 0);
} else {
//新增材料后刷新列表焦点置于新增的对象上
this.treeClick(
this.tableData[this.tableData.length - 1],
this.tableData.length - 1
);
}
}
} else {
this.$message.error(res.message);
}
})
})
},
/**
* @description: setChecked
* @param {*} item
* @author: renchao
*/
setChecked (item) {
this.treeCheckId = item.bsmSj;
this.title = item.sjmc;
this.titleYs = 1;
this.titleNum = item.children.length;
this.previewImg.imgList = item.children;
this.previewImg.bsmSj = item.bsmSj;
},
/**
* @description: updateList
* @param {*} val
* @author: renchao
*/
updateList (val) {
let that = this;
if (val.children.length != 0) {
//删除最后一张图片时 val=null
this.tableData.forEach((item) => {
if (item.bsmSj === val.bsmSj) {
item.children = val.children;
}
});
this.previewImg.imgList = _.cloneDeep(val.children);
if (this.previewImg.index == this.previewImg.imgList.length) {
this.previewImg.index = this.previewImg.index - 1;
}
this.key++
} else {
this.previewImg.imgList = [];
this.tableData.forEach((item, index) => {
if (this.treeCheckId == item.bsmSj) {
item.children = [];
that.treeCheckIndex = index;
}
});
}
},
/**
* @description: 添加材料目录
* @author: renchao
*/
handleAdd () {
this.isDialog = true;
},
/**
* @description: 新增弹窗保存
* @param {*} data
* @author: renchao
*/
addSave (data) {
let obj = {
bsmSlsq: this.$parent.bsmSlsq,
isrequired: "1",
sjmc: data.clmc,
sjsl: 0,
smzt: "",
ys: 0,
sjlx: data.cllx,
sfxjcl: "1", // 是否必选
};
if (this.$route.query.sqywbm == "DJBBL") {
obj.bsmSldy = this.$parent.bsmRepair
}
saveClml(obj).then(async (res) => {
if (res.code == 200) {
let res = await this.clmlInitList(2);
if (res == 200)
this.$message({
message: "新增成功",
type: "success",
});
}
});
},
/**
* @description: 材料目录点击选中
* @param {*} item
* @param {*} index
* @author: renchao
*/
treeClick (item, index) {
this.previewImg.index = 0;
this.treeCheckId = item?.bsmSj;
this.treeCheckIndex = index;
this.previewImg.imgList = item.children ? item.children : [];
this.previewImg.bsmSj = item?.bsmSj;
},
/**
* @description: 小图片点击
* @param {*} item
* @param {*} index
* @author: renchao
*/
imgClick (item, index) {
this.showImg = item;
this.titleYs = index + 1;
},
//查看明细
viewDetail () {
store.dispatch("user/reWorkFresh", false);
this.$popupDialog(
"申请材料目录",
"workflow/components/dialog/clxxDetailDialog",
{
data: this.tableData,
},
"60%",
true
);
},
//设置tableData
setTableData (tableData) {
this.$nextTick((res) => {
this.tableData = tableData;
});
},
},
};
</script>
<style scoped lang="scss">
@import "~@/styles/mixin.scss";
.active {
background: $light-blue !important;
color: #fff;
}
.required {
font-size: 12px;
color: $pink;
float: left;
}
.cl_number {
float: right;
}
.clxx {
width: 100%;
display: flex;
padding-left: 5px;
.left {
display: flex;
flex-direction: column;
justify-content: space-between;
.item {
width: 28px;
height: 49%;
@include flex-center;
background-color: #e4e7ed;
border-bottom-right-radius: 10px;
padding: 5px;
cursor: pointer;
transition: all 0.3s;
&:hover {
@extend .active;
}
}
}
.right {
width: 100%;
height: 100%;
.clmlmx-box {
margin: 0 auto;
.title {
text-align: center;
height: 60px;
line-height: 60px;
border: 1px solid #dfe6ec;
font-size: 20px;
background: #81d3f81a;
margin-bottom: -1px;
}
}
.clyl-box {
width: 100%;
height: 100%;
display: flex;
.menu-tree {
width: 20%;
min-width: 160px;
height: 100%;
margin-right: 10px;
border-right: 1px dotted #d9d9d9;
padding: 0 15px;
.item {
line-height: 30px;
padding-top: 5px;
border-bottom: 1px solid #e8e8e8;
font-size: 16px;
text-align: center;
color: $light-blue;
.itemIcon {
float: right;
line-height: 60px;
cursor: pointer;
}
.child {
line-height: 32px;
border-bottom: 1px solid #e8e8e8;
padding-left: 10px;
color: #6b6b6b;
cursor: pointer;
box-sizing: border-box;
border-radius: 6px;
line-height: 20px;
transition: all 0.3s;
padding: 8px 0;
}
.child:hover {
color: $light-blue;
transform: scale(1.1);
}
.checked {
border: 1px solid $light-blue;
color: $light-blue;
}
}
}
.clyl-img {
width: 75%;
height: 100%;
background: #f3f4f7;
margin: 0 auto;
position: relative;
}
}
}
}
</style>
/*
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-09-06 16:10:25
* @LastEditTime: 2023-09-07 14:49:06
*/
import filter from '@/utils/filter.js'
let vm = null
......@@ -56,12 +56,13 @@ class data extends filter {
},
{
label: '操作',
width: '80',
width: '120',
align: 'center',
render: (h, scope) => {
return (
<div>
<el-button type="text" onClick={() => { vm.handleDelete(scope.row) }}>删除</el-button>
<el-button type="text" icon="el-icon-edit-outline" onClick={() => { vm.handleEdit(scope.row) }}>编辑</el-button>
<el-button type="text" icon="el-icon-delete" onClick={() => { vm.handleDelete(scope.row) }}>删除</el-button>
</div>
)
}
......
<!--
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-09-06 16:08:08
* @LastEditTime: 2023-09-07 14:56:54
-->
<template>
<div class="from-clues">
......@@ -97,7 +97,7 @@
this.queryClick();
},
handleAdd () {
this.$popupDialog("添加企业", "xxba/qyxxba/components/addDialog", {}, "50%")
this.$popupDialog("添加企业", "xxba/components/addDialog", { isAdd: 1, }, "75%")
},
handleDelete () {
this.$confirm('此操作将永久删除该文件, 是否继续?', '提示', {
......@@ -115,6 +115,9 @@
message: '已取消删除'
});
});
},
handleEdit (row) {
this.$popupDialog("编辑企业", "xxba/components/addDialog", { isAdd: 2, ...row }, "75%")
}
}
}
......
<template>
<el-form ref="ruleForm" :model="ruleForm" label-width="100px" :rules="rules">
<el-row>
<el-col :span="12">
<el-form-item label="企业名称:" prop="qymc">
<el-input v-model="ruleForm.qymc"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="电话:" prop="dh">
<el-input v-model="ruleForm.dh"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="证件种类:">
<el-input v-model="ruleForm.zjzl"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="证件号:" prop="zjh">
<el-input v-model="ruleForm.zjh"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="法人名称:" prop="frmc">
<el-input v-model="ruleForm.frmc"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="法人电话:" prop="frdh">
<el-input v-model="ruleForm.frdh"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="单位地址:">
<el-input v-model="ruleForm.dwdz"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="邮编:" prop="yb">
<el-input v-model="ruleForm.yb"></el-input>
</el-form-item>
</el-col>
</el-row>
<el-form-item style="text-align:center">
<el-button type="primary" @click="submitForm">保存</el-button>
<el-button @click="closeDialog">取消</el-button>
</el-form-item>
</el-form>
</template>
<script>
import store from '@/store/index.js'
import { addYh } from "@/api/xxba.js"
export default {
props: {
formData: {
type: Object,
default: () => { },
},
},
data () {
return {
DJJGLIST: store.getters.dictData['ywly'],
readOnly: false,
//表单提交数据
ruleForm: {
batchno: '',
djjg: '',
operator: '超级管理员',
operationtime: '',
bz: '',
zsstarno: '',
zsendno: '',
zsnum: '',
zmstarno: '',
zmendno: '',
zmnum: ''
},
//表格数据
tableForm: [
{
name: '不动产权证书',
ksysxlh: '',
jsysxlh: '',
bs: 0,
zslx: 1
},
{
name: '不动产登记证明',
ksysxlh: '',
jsysxlh: '',
bs: 0,
zslx: 2
}
],
//证书入库业务号参数
ywhQueryForm: {
serialtype: 'zsrkbh',
serialname: '证书入库编号',
serialcode: 'zsrk',
digit: '5'
},
rules: {
batchNo: [
{ required: true, message: '入库编号不能为空', trigger: 'blur' }
],
djjg: [
{ required: true, message: '请选择登记机构', trigger: 'change' }
],
rksj: [
{ required: true, message: '请选择入库时间', trigger: 'change' }
],
},
}
},
mounted () {
if (this.formData.bsmBatch) {
this.tableForm[0].bs = null;
this.tableForm[1].bs = null;
this.getDetailInfo(this.formData.bsmBatch);
}
},
methods: {
/**
* @description: 表单提交
* @author: renchao
*/
submitForm () {
this.tableForm.forEach((item, index) => {
if (item.bs < 0) {
return;
}
})
addYh(this.ruleForm).then(res => {
if (res.code == 200) {
this.$message.success('保存成功')
this.$emit("input", false);
this.$refs['ruleForm'].resetFields();
this.resetTableFields();
this.closeDialog();
//刷新列表
store.dispatch('user/reWorkFresh', true)
} else {
this.$message.error(res.message);
}
})
},
/**
* @description: 获取详情信息
* @param {*} bsmBatch
* @author: renchao
*/
getDetailInfo (bsmBatch) {
getZsglInfo({ "bsmBatch": bsmBatch }).then(res => {
if (res.code == 200) {
this.ruleForm = res.result;
this.readOnly = false;
this.tableForm[0].ksysxlh = res.result.zsstarno;
this.tableForm[0].jsysxlh = res.result.zsendno;
this.tableForm[0].bs = res.result.zsnum;
this.tableForm[1].ksysxlh = res.result.zmstarno;
this.tableForm[1].jsysxlh = res.result.zmendno;
this.tableForm[1].bs = res.result.zmnum;
}
})
},
/**
* @description: 印刷序列号处理
* @param {*} item
* @author: renchao
*/
ysxlhDeal (item) {
if (item.ksysxlh && item.jsysxlh) {
if (item.ksysxlh.length == item.jsysxlh.length) {
if (item.ksysxlh.length != 11) {
item.bs = -1;
return;
}
if (item.ksysxlh > item.jsysxlh) {
item.bs = -1;
return;
}
item.bs = item.jsysxlh - item.ksysxlh + 1;
if (item.zslx == 1) {
this.ruleForm.zsstarno = item.ksysxlh;
this.ruleForm.zsendno = item.jsysxlh;
this.ruleForm.zsnum = item.bs
} else if (item.zslx == 2) {
this.ruleForm.zmstarno = item.ksysxlh;
this.ruleForm.zmendno = item.jsysxlh;
this.ruleForm.zmnum = item.bs
}
} else {
item.bs = -1;
}
} else {
item.bs = 0;
if (item.zslx == 1) {
this.ruleForm.zsstarno = '';
this.ruleForm.zsendno = '';
this.ruleForm.zsnum = item.bs
} else if (item.zslx == 2) {
this.ruleForm.zmstarno = '';
this.ruleForm.zmendno = '';
this.ruleForm.zmnum = item.bs
}
}
},
/**
* @description: resetTableFields
* @author: renchao
*/
resetTableFields () {
this.tableForm = [
{
name: '不动产权证书',
ksysxlh: '',
jsysxlh: '',
bs: 0,
zslx: 1
},
{
name: '不动产权登记证明',
ksysxlh: '',
jsysxlh: '',
bs: 0,
zslx: 2
}
]
},
/**
* @description: closeDialog
* @author: renchao
*/
closeDialog () {
this.$popupCacel()
this.$refs['ruleForm'].resetFields();
this.resetTableFields();
}
}
}
</script>
<style scoped lang="scss">
@import "~@/styles/mixin.scss";
@import "~@/styles/dialogBoxheader.scss";
.font-red {
color: red;
}
.middle-margin-bottom {
margin-top: 20px;
}
</style>
/*
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-09-06 16:12:16
* @LastEditTime: 2023-09-07 14:52:10
*/
import filter from '@/utils/filter.js'
let vm = null
......@@ -56,12 +56,13 @@ class data extends filter {
},
{
label: '操作',
width: '80',
width: '120',
align: 'center',
render: (h, scope) => {
return (
<div>
<el-button type="text" onClick={() => { vm.handleDelete(scope.row) }}>删除</el-button>
<el-button type="text" icon="el-icon-edit-outline" onClick={() => { vm.handleEdit(scope.row) }}>编辑</el-button>
<el-button type="text" icon="el-icon-delete" onClick={() => { vm.handleDelete(scope.row) }}>删除</el-button>
</div>
)
}
......
<!--
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-09-06 16:08:32
* @LastEditTime: 2023-09-07 14:30:50
-->
<template>
<div class="from-clues">
......@@ -97,7 +97,7 @@
this.queryClick();
},
handleAdd () {
this.$popupDialog("添加企业", "xxba/yhjgba/components/addDialog", {}, "50%")
this.$popupDialog("添加企业", "xxba/components/addDialog", {}, "75%")
},
handleDelete () {
this.$confirm('此操作将永久删除该文件, 是否继续?', '提示', {
......
......@@ -61,7 +61,7 @@
type="index"
width="50"
align="center">
<template scope="scope">
<template slot-scope="scope">
{{ scope.$index + (pageData.currentPage - 1) * pageData.pageSize + 1 }}
</template>
</el-table-column>
......
/*
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-09-07 09:50:26
* @LastEditTime: 2023-09-07 13:59:44
*/
import filter from '@/utils/filter.js'
let vm = null
......@@ -91,8 +91,15 @@ class data extends filter {
}
},
{
prop: "ywrmc",
label: "抵押人",
minWidth: '100',
render: (h, scope) => {
return (
<el-tooltip effect="dark" content={scope.row.ywrmc} placement="top" popper-class="tooltip-width ">
<span class="ellipsis-table"> {scope.row.ywrmc}</span>
</el-tooltip>
)
}
},
{
label: "抵押人证件号",
......