Commit 7c0ea8d1 by xue_wengang

重点人员,组件子集处理

parent ad1dbbcb
......@@ -3,7 +3,7 @@
<div class="formContent" style="margin-top: 20px">
<div style="margin: 0px auto; border-radius: 8px">
<div class="groupTitleBox">
<span class="groupTitle">{{ propFormField[0].title }}</span>
<span class="groupTitle">{{ propTitle }}</span>
</div>
<el-form
ref="formLabelAlign"
......@@ -18,6 +18,10 @@
:key="groupItem.index"
>
<div>
<div class="subTitle">
<div>{{ groupItem.title }}</div>
<!-- <div class="bottomLine"></div> -->
</div>
<div class="zdyLine">
<el-form-item
:rules="rules[item.id]"
......@@ -339,10 +343,8 @@
v-for="(item2, index2) in item.childrenAsAdd"
:key="index2"
>
<div v-if="item2.flag" id="childrenAsAdd">
<div v-if="!item2.flag2">
<div v-if="item2.flag">
<div v-for="(item3, ind) in item2.list" :key="ind">
<div>
<div
v-for="(reakData, realIndex) in formLabelAlign[
item2.id
......@@ -352,38 +354,30 @@
>
<span class="addName"
>{{
item2.name.substring(
0,
item2.name.length - 1
)
item2.name.substring(0, item2.name.length - 1)
}}{{ realIndex + 1 }}:</span
>
<span class="addContent">
<i
<!-- <i
:class="'zdyicon ' + item2.iconClass"
@click="deleteObj(reakData)"
v-if="realIndex != 0"
></i>
v-if="!type2"
@click="deleteObj(reakData, item2)"
></i> -->
<el-form-item
v-for="item4 in item3.name"
:label="item4.name"
v-show="!item4.hidden"
:prop="`${item2.id}[${realIndex}].${item4.id}`"
:key="item4.id"
:ref="`${item2.id}[${realIndex}].${item4.id}`"
:class="[
'item' + item4.col,
item4.prop == 'checkEmpty'
? redColor
: '',
'item' + item4.col
]"
:rules="
rules[
`${item2.id}${realIndex}.${item4.id}`
]
rules[`${item2.id}${realIndex}.${item4.id}`]
"
:style="{
height:
item4.id == 'ryzp' ? '185px' : '36px',
height: item4.id == 'ryzp' ? '185px' : '36px',
}"
>
<!--输入框-->
......@@ -403,10 +397,7 @@
slot="suffix"
class="el-input__icon"
:class="item4.icon"
style="
cursor: pointer;
color: #3670ff;
"
style="cursor: pointer; color: #3670ff"
title="被害人信息提取"
></i>
<i
......@@ -415,10 +406,7 @@
slot="suffix"
class="el-input__icon"
:class="item4.icon"
style="
cursor: pointer;
color: #3670ff;
"
style="cursor: pointer; color: #3670ff"
title="犯罪嫌疑人信息提取"
></i>
</el-input>
......@@ -487,9 +475,7 @@
<!--字典弹框懒加载 @emitValue="getLbValue"-->
<div
class="zdyInputW"
v-else-if="
item4.type == 'lazyCodeTreeDialog'
"
v-else-if="item4.type == 'lazyCodeTreeDialog'"
>
<lazy-select-tree-dialog
:placeholder="'请选择' + item4.name"
......@@ -499,6 +485,31 @@
:currentItem="item4"
/>
</div>
<!--字典框 @emitValue="getLbValue"-->
<div
class="zdyInputW"
v-else-if="item4.type == 'code'"
>
<select-tree
v-model="reakData[item4.id]"
:placeholder="'请选择' + item4.name"
:options="item4.codeOptions"
:sendId="item4.id"
/>
</div>
<!--字典弹框 @emitValue="getLbValue"-->
<div
class="zdyInputW"
v-else-if="item4.type == 'codeTree'"
>
<select-tree-dialog
:placeholder="'请选择' + item4.name"
:sendId="item4.id"
:formData="reakData"
:currentItem="item4"
v-model="reakData[item4.id]"
/>
</div>
<div
class="zdyInputW"
v-else-if="item4.type == 'checkboxBotton'"
......@@ -548,7 +559,6 @@
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
@change="dateChange(reakData[item4.id])"
value-format="yyyy-MM-dd HH:mm:ss"
v-else-if="item4.type == 'datearea'"
>
......@@ -569,7 +579,6 @@
action="#"
ref="uploadFile"
:accept="item4.acceptType"
:auto-upload="false"
:before-upload="
normalPictureBeforeAvatarUpload
"
......@@ -603,6 +612,7 @@
realIndex
)
"
:auto-upload="false"
:http-request="httpRequest"
:on-preview="
(flie, fileList) =>
......@@ -617,9 +627,7 @@
:file-list="
fileLists[item2.id] &&
fileLists[item2.id][realIndex]
? fileLists[item2.id][realIndex][
item4.id
]
? fileLists[item2.id][realIndex][item4.id]
: []
"
v-model="reakData[item4.id + '1']"
......@@ -693,7 +701,6 @@
class="avatar2"
/>
</div>
<el-upload
v-else
class="avatar-uploader"
......@@ -718,9 +725,7 @@
>
<div slot="file" slot-scope="{ file }">
<img
class="
el-upload-list__item-thumbnail
"
class="el-upload-list__item-thumbnail"
:src="file.url"
alt=""
/>
......@@ -728,17 +733,13 @@
<img
v-if="reakData.src"
:src="
'data:image/gif;base64,' +
reakData.src
'data:image/gif;base64,' + reakData.src
"
class="avatar"
/>
<i
v-else
class="
el-icon-plus
avatar-uploader-icon
"
class="el-icon-plus avatar-uploader-icon"
></i>
</el-upload>
</div>
......@@ -763,9 +764,7 @@
>
<div
class="shadow"
@click="
deleteZp('fzxyr', realIndex, 1)
"
@click="deleteZp('fzxyr', realIndex, 1)"
></div>
<img
:src="
......@@ -841,9 +840,7 @@
>
<div
class="shadow"
@click="
deleteZp('fzxyr', realIndex, 2)
"
@click="deleteZp('fzxyr', realIndex, 2)"
></div>
<img
:src="
......@@ -919,9 +916,7 @@
>
<div
class="shadow"
@click="
deleteZp('fzxyr', realIndex, 3)
"
@click="deleteZp('fzxyr', realIndex, 3)"
></div>
<img
:src="
......@@ -990,29 +985,7 @@
</span>
</div>
</div>
</div>
</div>
<div v-else style="position: absolute; top: -25px">
<span class="addName"
>{{
item2.name.substring(0, item2.name.length - 1)
}}:</span
>
<span style="display: inline-block">
<i
class="iconfont icontiqu"
style="
cursor: pointer;
font-size: 20px;
position: absolute;
top: 34px;
right: -25px;
"
title="提取"
></i>
</span>
</div>
<div class="addChildBtn" v-show="item2.noshowMoreBtn">
<div class="addChildBtn">
<el-button type="primary" @click="handelFrom(item2)">
<i class="el-icon-plus"></i><span>添加</span>
</el-button>
......@@ -1062,6 +1035,7 @@ export default {
type: Object,
default: () => {},
},
propTitle: String,
},
data() {
return {
......@@ -1188,14 +1162,8 @@ export default {
//1.1二级字典处理
if (item.type == "lazyCodeTree" || item.type == "codeTree") {
if (item.multiple) {
// self.formLabelAlign[item.id].forEach((subitmes) => {
// params.append(objStr + item.id, subitmes);
// });
let str = `#${self.formLabelAlign[item.id].join('#')}`
params.append(
objStr + item.id,
str
);
let str = `#${self.formLabelAlign[item.id].join("#")}`;
params.append(objStr + item.id, str);
} else {
params.append(
objStr + item.id,
......@@ -1212,11 +1180,8 @@ export default {
}
} else if (item.type == "setValue") {
if (item.multiple) {
let str = `#${self.formLabelAlign[item.id].join('#')}`
params.append(
objStr + item.id,
str
);
let str = `#${self.formLabelAlign[item.id].join("#")}`;
params.append(objStr + item.id, str);
} else {
if (item.id == "jsrXm") {
let arr = item.codeOptions.filter(
......@@ -1420,8 +1385,9 @@ export default {
}
//2.有childrenAsAdd表单数据处理
if (item.childrenAsAdd) {
debugger
item.childrenAsAdd.forEach((subItem) => {
if (subItem.flag == self.formLabelAlign[item.id]) {
debugger
//如果遍历到的编号和所选择的编号一致
self.formLabelAlign[subItem.id].forEach((val5, index) => {
//遍历每一个数组的值
......@@ -1493,7 +1459,6 @@ export default {
}
}
});
}
});
}
});
......@@ -1552,6 +1517,50 @@ export default {
debugger;
},
httpRequest() {},
//新增表单数据
handelFrom(obj) {
let self = this,
addObj;
if (obj.flag2) {
obj.flag2 = false;
} else {
self.propFormField.forEach((groupItem) => {
groupItem.data.forEach((val) => {
if (val.childrenAsAdd) {
val.childrenAsAdd.forEach((val2, index2) => {
//遍历list数组
if (val2 == obj) {
//通过比较两个对象是否相等 将formLabelAlign里绑定的数据复制了一份
addObj = JSON.parse(
JSON.stringify(self.formLabelAlign[val2.id][0])
);
//实现深拷贝赋值
for (var val3 in addObj) {
addObj[val3] = "";
}
self.$set(
self.formLabelAlign[val2.id],
self.formLabelAlign[val2.id].length,
addObj
);
for (var f = 0; f < val2.list[0].name.length; f++) {
if (val2.list[0].name[f].type == "file") {
self.fileLists[val2.id][
self.formLabelAlign[val2.id].length - 1
] = {};
self.fileLists[val2.id][
self.formLabelAlign[val2.id].length - 1
][val2.list[0].name[f].id] == [];
}
}
this.$message.success("新增成功");
}
});
}
});
});
}
},
},
mounted() {
var self = this;
......@@ -1629,6 +1638,17 @@ $-header-fontSize: 18px;
}
#formCommonPage {
width: 100% !important;
.subTitle {
div {
font-size: 14px;
font-family: Source Han Sans CN;
font-weight: 600;
line-height: 48px;
height: 48px;
color: #363636;
opacity: 1;
}
}
.sjjcShadow {
width: 100%;
height: 100vh;
......@@ -1680,7 +1700,7 @@ $-header-fontSize: 18px;
background: #fdfdfd !important;
}
/deep/.el-input__inner {
height: 29px;
height: 32px;
}
/deep/.el-checkbox-button,
/deep/.el-checkbox-button__inner {
......@@ -1711,7 +1731,6 @@ $-header-fontSize: 18px;
height: 48px;
font-size: 16px;
font-family: Microsoft YaHei;
border-bottom: 1px solid #e4e4e4;
font-weight: bold;
line-height: 48px;
color: #363636;
......@@ -1724,9 +1743,13 @@ $-header-fontSize: 18px;
//分块组级卡片
.paneGroupDiv {
background: #ffffff;
padding: 0 40px;
padding-bottom: 20px;
// 表单元素的真实容器
.zdyLine {
padding: 0px 20px 20px 20px;
padding-bottom: 20px;
border-bottom: 1px solid #e4e4e4;
/deep/.el-form-item {
margin-bottom: 0px !important;
.el-form-item__label {
......@@ -1747,7 +1770,7 @@ $-header-fontSize: 18px;
margin-bottom: 10px;
}
.el-input__inner {
border-radius: 2px;
border-radius: 4px;
}
.codeTree {
.el-select {
......
......@@ -422,9 +422,13 @@
</div>
<div
v-else-if="
((pageBs != 'rwbd' && pageBs != 'rwbdjs') && (columnTitle.prop == 'xxzjbh' || columnTitle.prop == 'asjbh' || columnTitle.prop == 'xm' )) ||
((pageBs == 'rwbd' || pageBs == 'rwbdjs') && columnTitle.prop == 'rwmc')
(pageBs != 'rwbd' &&
pageBs != 'rwbdjs' &&
(columnTitle.prop == 'xxzjbh' ||
columnTitle.prop == 'asjbh' ||
columnTitle.prop == 'xm')) ||
((pageBs == 'rwbd' || pageBs == 'rwbdjs') &&
columnTitle.prop == 'rwmc')
"
>
<!-- 暂时修改成这样 -->
......@@ -474,6 +478,22 @@
}}
</el-tag>
</div>
<div
v-else-if="columnTitle.prop == 'zjhm'"
style="font-size: 13px !important"
>
<span
style="border: 1px solid rgb(64, 158, 255); padding: 0px 4px"
>{{
columnTitle["gradeLev"] == 10
? "一般"
: columnTitle["gradeLev"] == 20
? "危险"
: "高危"
}}</span
>
{{ scope.row[columnTitle.prop] }}
</div>
<div v-else v-html="scope.row[columnTitle.prop]">
{{ columnTitle.prop }}
</div>
......@@ -500,7 +520,12 @@
class="edit"
style="margin-right: 16px"
v-if="
!(pageBs == 'rySp' || pageBs == 'yhkxsGl' || pageBs == 'rwbd'|| pageBs == 'rwbdjs')
!(
pageBs == 'rySp' ||
pageBs == 'yhkxsGl' ||
pageBs == 'rwbd' ||
pageBs == 'rwbdjs'
)
"
>修改</span
>
......
......@@ -18,6 +18,7 @@ import zdryRoutes from "./modules/zdry";
import rlqbxsRoutes from "./modules/rlqbxs";
import xsjsdbRoutes from "./modules/xsjsdb";
import zjclRoutes from "./modules/zjcl";
import userAuthRoutes from "./modules/userAuth";
const originalPush = VueRouter.prototype.push;
......@@ -49,6 +50,7 @@ const mainRouters = [
rlqbxsRoutes,
xsjsdbRoutes,
zjclRoutes,
userAuthRoutes,
{
path: "*",
name: "error",
......
import menuLayout from "@/layout/menuLayout.vue";
const menuLayouts = [
{
path: "/queryUser",
name: "queryUser",
meta: {
isAdd: true,
title: '用户管理'
},
component: () => import("@/views/userAuth/queryUser.vue")
}
];
export default {
path: "/right",
component: menuLayout,
children: [...menuLayouts]
};
\ No newline at end of file
......@@ -4,6 +4,7 @@
:formField="formField"
:formLabelAligns="formLabelAlign"
@submit="submit"
:propTitle="title"
>
</form-compontent>
</div>
......@@ -20,16 +21,43 @@ export default {
},
data() {
return {
title: "可疑线索管理",
formField: [
//基本信息
{
title: "可疑线索管理",
title: "可疑线索",
id: 1,
objStr: "",
index: 0,
data: kysscj,
},
{
title: "可疑线索0000",
id: 10,
objStr: "",
index: 20,
data: [
{
name: "测试:",
col: "1",
noshowMoreBtn: false, //是否显示添加按钮
childrenAsAdd: [
{
name: "测试:",
id: "test",
flag: true,
list: [
{
name: kysscj,
},
],
iconClass: "el-icon-close",
},
],
},
],
},
{
title: "线索提供者",
id: 2,
objStr: "",
......
<template>
<div class="Content">
<right-content
:pageBs="pageBs"
:header="header"
:cxFormData="cxFormData"
:cxQueryField="cxQueryField"
:cxDefaultFormThead="cxDefaultFormThead"
:cxUrl="cxUrl"
@add="add"
></right-content>
</div>
</template>
<script>
import rightContent from "@c/ptCxForm_components.vue";
export default {
name: "jdcxsGl",
components: {
rightContent
},
data() {
return {
header: "用户管理",
pageBs: "queryUser",
cxFormData: {
username: "",
limit: 10,
page: 1,
policemanid:""
},
cxQueryField: [
{
name: "用户名",
id: "username",
type: "text",
value: "",
placeholder: "",
col: "3",
},
{
name: "警号",
id: "policemanid",
type: "text",
value: "",
placeholder: "",
col: "3",
},
],
cxDefaultFormThead: [
{
label: "登录名",
prop: "username",
},
{
label: "用户姓名",
prop: "trueName",
},
{
label: "用户单位",
prop: "unitname"
},
{
label: "警号",
prop: "policemanid",
},
{
label: "用户状态",
prop: "openFlag",
},
],
cxUrl: "/sysuser/selectUserNewList",
Menu: [
{
id: "queryUser",
label: "用户管理",
index: "queryUser",
auth: "M0101",
className: "iconfont iconrizhi",
disabled: false,
},
],
};
},
created() {
this.$store.commit("user/SET_Menu", this.Menu);
// debugger
},
methods: {
add() {
this.$router.pushToTab("addJdcxs");
},
},
};
</script>
<style>
.el-dialog__body {
padding: 10px 15px !important;
}
.rightContent .el-input__inner,
#formCommonPage .el-input__inner {
height: 32px;
line-height: 32px;
font-family: inherit;
}
.el-table__header-wrapper th,
.el-table__header-wrapper tr {
background: #f4f6f7;
}
.rightContent .el-input__icon,
#formCommonPage .el-input__icon,
.el-input__suffix-inner {
line-height: 36px;
}
.rightContent .el-range-separator {
position: relative;
top: -4px;
}
.rightContent .el-textarea__inner,
#formCommonPage .el-textarea__inner {
width: 100%;
font-family: inherit;
}
.rightContent .el-range-input,
#formCommonPage .el-range-input {
vertical-align: top;
}
.rightContent .el-date-editor .el-range__close-icon {
margin-top: -4px;
}
.rightContent .el-form-item__error {
left: calc(66% - 27px);
top: 12px;
}
.success-row {
background-color: #fbf9f4 !important;
}
.Content .el-input,
.Content .el-date-editor--daterange.el-input__inner {
width: 100% !important;
}
</style>
<style scoped lang="scss">
@import "@/assets/styles/rightContent.scss";
</style>
......@@ -181,6 +181,7 @@ export default {
{
label: "身份证号",
prop: "zjhm",
width: '230px'
},
{
label: "作案年龄",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment