保安服务企业管理项目备份
guanqb
2023-12-28 274b98cd885886b76cd90acd388f3352a0479d46
上岗证样式修改
2 files modified
387 ■■■■ changed files
src/views/securityGuard/baoanz.vue 117 ●●●●● patch | view | raw | blame | history
src/views/securityGuard/securityGuardDetail.vue 270 ●●●● patch | view | raw | blame | history
src/views/securityGuard/baoanz.vue
@@ -1,25 +1,24 @@
<template>
    <div class="baoanzheng-1"
         id="baoanzheng-1">
        <div class="baz-main-1"
             ref="baoanzheng1">
            <img class="baz-main-img1"
                 :src="data.avatar"
                 alt="" />
            <div class="baz-main-img1-2"
                 v-if='permission.securityGuard_workLicense'>
                <img class="baz-main-img1-2-i"
                     :src="erweima"
                     alt="" />
            </div>
            <div class="b-m-ups-1">
                {{ data.realName }}
    <div class="baoanzheng-1" id="baoanzheng-1">
        <div class="baz-main-1" ref="baoanzheng1">
            <img class="baz-main-img1" :src="data.avatar" alt="" />
            <div class="baz-main-img1-2" v-if='permission.securityGuard_workLicense'>
                <img class="baz-main-img1-2-i" :src="erweima" alt="" />
            </div>
            <div class="b-m-ups-1">
                {{ data.$sex }}
            </div>
            <div class="b-m-ups-1 securitynumber-1">
            <div class="b-m-ups-1">
                {{ data.securitynumber }}
            </div>
            <div class="b-m-ups-1 b-m-ups-2">
                {{ data.birthdayData || "---" }}
            </div>
            <div class="b-m-ups-1 b-m-ups-3">
                {{ data.cardid }}
            </div>
            <div class="b-m-ups-1">
                {{ data.registered || "---" }}
            </div>
            <div class="b-m-ups-1 b-m-ups-2">
                <!-- {{ data.securitynumber }} -->晋城市公安局
@@ -27,16 +26,14 @@
            <div class="b-m-ups-1 b-m-ups-2">
                {{ data.paperTime || "---" }}
            </div>
            <div class="b-m-ups-1 realName">
                {{ data.realName || "---" }}
            </div>
        </div>
        <span slot="footer"
              class="dialog-footer no-print PrintBut">
        <span slot="footer" class="dialog-footer no-print PrintBut">
            <!-- v-show="closePrint != 1" -->
            <el-button v-show='false'
                       type="primary"
                       @click="Print">打 印</el-button>
            <el-button type="primary"
                       @click="closeME"
                       v-show="close == 1">返 回</el-button>
            <el-button v-show='false' type="primary" @click="Print">打 印</el-button>
            <el-button type="primary" @click="closeME" v-show="close == 1">返 回</el-button>
        </span>
    </div>
</template>
@@ -51,14 +48,14 @@
//         }
//     })
// }
import { mapGetters } from "vuex";
import { getER } from "@/api/performance/performance";
import { mapGetters } from "vuex"
import { getER } from "@/api/performance/performance"
export default {
    props: ["data", "close", "closePrint"],
    data () {
        return {
            erweima: "",
        };
        }
    },
    computed: {
        ...mapGetters(["userInfo", "permission"]),
@@ -69,28 +66,28 @@
    mounted () {
        getER(this.data.securitynumber).then((res) => {
            this.erweima = res.data;
            this.erweima = res.data
            // console.log(res.data);
        });
        })
    },
    methods: {
        Print () {
            var printDom = document.getElementById("baoanzheng-1");
            printDom.style.position = "fixed";
            printDom.style.left = "-10%";
            printDom.style.width = "120%";
            printDom.style.height = "100%";
            this.$Print(this.$refs.baoanzheng1);
            printDom.style.position = "relative";
            printDom.style.left = "0";
            printDom.style.width = "100%";
            printDom.style.height = "calc(100% - 100px)";
            var printDom = document.getElementById("baoanzheng-1")
            printDom.style.position = "fixed"
            printDom.style.left = "-10%"
            printDom.style.width = "120%"
            printDom.style.height = "100%"
            this.$Print(this.$refs.baoanzheng1)
            printDom.style.position = "relative"
            printDom.style.left = "0"
            printDom.style.width = "100%"
            printDom.style.height = "calc(100% - 100px)"
        },
        closeME () {
            this.$emit("close");
            this.$emit("close")
        },
    },
};
}
</script>
<style lang="scss" scoped>
@@ -102,20 +99,23 @@
    align-items: center;
    justify-content: center;
    flex-direction: column;
    .baz-main-1 {
        background-image: url('/img/register/bazbj2.png');
        background-image: url('/img/register/bazbj3.png');
        background-size: 100% 100%;
        width: calc(1274px * 0.5) !important;
        height: calc(828px * 0.5) !important;
        position: relative;
        margin-bottom: 10px;
        .baz-main-img1 {
            width: 170px;
            width: 150px;
            position: absolute;
            left: 51px;
            top: 57px;
            height: 237px;
            left: 44px;
            top: 120px;
            height: 220px;
        }
        .baz-main-img1-2 {
            width: 91px;
            position: absolute;
@@ -124,6 +124,7 @@
            top: 78px;
            height: 93px;
            overflow: hidden;
            .baz-main-img1-2-i {
                width: 115px;
                height: 115px;
@@ -132,22 +133,34 @@
                left: -11px;
            }
        }
        .b-m-ups-1 {
            width: 50%;
            height: 30px;
            font-size: 22px;
            height: 13px;
            font-size: 21px;
            font-weight: 400;
            position: relative;
            top: 91px;
            left: 320px;
            margin-bottom: 21px;
            top: 108px;
            left: 270px;
            margin-bottom: 22px;
        }
        // .securitynumber-1 {
        //   font-size: 22px;
        //   margin-bottom: 18px;
        // }
        .b-m-ups-2 {
            left: 358px;
            left: 304px;
        }
        .b-m-ups-3 {
            left: 356px;
        }
        .realName {
            left: 92px;
            top: 94px;
            font-size: 16px;
        }
    }
}
src/views/securityGuard/securityGuardDetail.vue
@@ -1,36 +1,19 @@
<template>
    <div class="dispatch">
        <avue-tabs :option="optionTABS"
                   @change="handleChangeTABS"></avue-tabs>
        <avue-tabs :option="optionTABS" @change="handleChangeTABS"></avue-tabs>
        <span v-if="typeTABS.prop === 'tab1'">
            <avue-form ref="form"
                       v-model="obj0"
                       :option="option0"> </avue-form>
            <avue-form ref="form" v-model="obj0" :option="option0"> </avue-form>
        </span>
        <span v-else-if="typeTABS.prop === 'tab2'">
            <avue-crud :option="option1"
                       :data="data1"
                       :page.sync="page1"
                       :table-loading="loading1"
                       @row-save="rowSave1"
                       @row-update="rowUpdate1"
                       @row-del="rowDel1"
                       @current-change="CurrentChange1"
                       @refresh-change="refreshchange1"
                       @size-change="SizeChange1">
            <avue-crud :option="option1" :data="data1" :page.sync="page1" :table-loading="loading1" @row-save="rowSave1"
                @row-update="rowUpdate1" @row-del="rowDel1" @current-change="CurrentChange1"
                @refresh-change="refreshchange1" @size-change="SizeChange1">
            </avue-crud>
        </span>
        <span v-else-if="typeTABS.prop === 'tab3'">
            <avue-crud :option="option2"
                       :data="data2"
                       :page.sync="page2"
                       @row-save="rowSave2"
                       @row-update="rowUpdate2"
                       @row-del="rowDel2"
                       :table-loading="loading2"
                       @current-change="CurrentChange2"
                       @size-change="SizeChange2"
                       @refresh-change="refreshchange2">
            <avue-crud :option="option2" :data="data2" :page.sync="page2" @row-save="rowSave2" @row-update="rowUpdate2"
                @row-del="rowDel2" :table-loading="loading2" @current-change="CurrentChange2" @size-change="SizeChange2"
                @refresh-change="refreshchange2">
            </avue-crud>
        </span>
        <span v-else-if="typeTABS.prop === 'tab4'">
@@ -71,18 +54,14 @@
          </span>
        </div>
      </div> -->
            <baoanz :data="obj0"
                    v-if="hold == 1 || hold == 3"></baoanz>
            <div v-else
                 style="width: 100%; text-align: center; padding-top: 20px">
            <baoanz :data="obj0" v-if="hold == 1 || hold == 3"></baoanz>
            <div v-else style="width: 100%; text-align: center; padding-top: 20px">
                无上岗证
            </div>
        </span>
        <span v-else-if="typeTABS.prop === 'tab5'">
            <securityCertificate :data="obj0"
                                 v-if="hold == 1 || hold == 3"></securityCertificate>
            <div v-else
                 style="width: 100%; text-align: center; padding-top: 20px">
            <securityCertificate :data="obj0" v-if="hold == 1 || hold == 3"></securityCertificate>
            <div v-else style="width: 100%; text-align: center; padding-top: 20px">
                无保安员证
            </div>
        </span>
@@ -94,13 +73,13 @@
    securityBaseInfoColumn,
    practitionersColumn,
    trackRecordColumn,
} from "./data";
} from "./data"
import {
    addExperience,
    updateExperience,
    experienceRemove,
    getExperienceList,
} from "@/api/experience/experience";
} from "@/api/experience/experience"
import {
    add,
@@ -108,11 +87,11 @@
    getpage,
    remove,
    getER,
} from "@/api/performance/performance";
} from "@/api/performance/performance"
// import vueQr from "vue-qr";
import securityCertificate from "./securityCertificate.vue";
import baoanz from "./baoanz.vue";
import securityCertificate from "./securityCertificate.vue"
import baoanz from "./baoanz.vue"
export default {
    components: {
@@ -217,18 +196,18 @@
            },
            erweima: "",
            hold: "",
        };
        }
    },
    // components: {
    //   vueQr,
    // },
    computed: {
        ids1 () {
            let ids1 = [];
            let ids1 = []
            this.selectionList1.forEach((ele) => {
                ids1.push(ele.id);
            });
            return ids1.join(",");
                ids1.push(ele.id)
            })
            return ids1.join(",")
        },
        // goToUrl() {
        //   var url =
@@ -239,82 +218,82 @@
    },
    methods: {
        Print () {
            var printDom = document.getElementById("baoanzheng");
            printDom.style.position = "fixed";
            printDom.style.left = "-10%";
            printDom.style.width = "120%";
            printDom.style.height = "100%";
            this.$Print(this.$refs.baoanzheng);
            printDom.style.position = "relative";
            printDom.style.left = "0";
            printDom.style.width = "100%";
            printDom.style.height = "calc(100% - 100px)";
            var printDom = document.getElementById("baoanzheng")
            printDom.style.position = "fixed"
            printDom.style.left = "-10%"
            printDom.style.width = "120%"
            printDom.style.height = "100%"
            this.$Print(this.$refs.baoanzheng)
            printDom.style.position = "relative"
            printDom.style.left = "0"
            printDom.style.width = "100%"
            printDom.style.height = "calc(100% - 100px)"
        },
        handleChangeTABS (column) {
            this.typeTABS = column;
            this.typeTABS = column
            if (column.prop == "tab1") {
                this.loading1 = false;
                this.loading1 = false
            } else if (column.prop == "tab2") {
                //查询当前保安员的从业记录信息
                this.getPractitionersPageInfo(this.page1);
                this.loading1 = false;
                this.getPractitionersPageInfo(this.page1)
                this.loading1 = false
            } else if (column.prop == "tab3") {
                //查询当前保安员的现实表现记录
                this.getPerformancePageInfo(this.page2);
                this.loading2 = false;
                this.getPerformancePageInfo(this.page2)
                this.loading2 = false
            } else if (column.prop == "tab4") {
                getER(this.obj0.securitynumber).then((res) => {
                    this.erweima = res.data;
                    this.erweima = res.data
                    // console.log(res.data);
                });
                })
            }
        },
        refreshchange1 () {
            this.getPractitionersPageInfo(this.page1, this.query1);
            this.getPractitionersPageInfo(this.page1, this.query1)
        },
        //查询当前保安员的从业记录信息
        getPractitionersPageInfo (page, param = {}) {
            param["securityid"] = this.id;
            param["securityid"] = this.id
            //获取用户从业信息
            // console.log(this.id, "cid");
            getExperienceList(page.currentPage, page.pageSize, param).then((res1) => {
                const data = res1.data.data;
                this.page1.total = data.total;
                this.data1 = data.records;
                this.loading1 = false;
            });
                const data = res1.data.data
                this.page1.total = data.total
                this.data1 = data.records
                this.loading1 = false
            })
        },
        refreshchange2 () {
            this.getPerformancePageInfo(this.page2, this.query2);
            this.getPerformancePageInfo(this.page2, this.query2)
        },
        //查询当前保安员的现实表现记录信息
        getPerformancePageInfo (page, param = {}) {
            //获取现实表现信息
            param["securityid"] = this.id;
            param["securityid"] = this.id
            getpage(page.currentPage, page.pageSize, param).then((res2) => {
                const data = res2.data.data;
                this.page2.total = data.total;
                this.data2 = data.records;
                console.log(this.data2, 1);
                this.loading2 = false;
            });
                const data = res2.data.data
                this.page2.total = data.total
                this.data2 = data.records
                console.log(this.data2, 1)
                this.loading2 = false
            })
        },
        CurrentChange1 (currentPage) {
            this.page1.currentPage = currentPage;
            this.refreshchange1();
            this.page1.currentPage = currentPage
            this.refreshchange1()
        },
        SizeChange1 (pageSize) {
            this.page1.pageSize = pageSize;
            this.refreshchange1();
            this.page1.pageSize = pageSize
            this.refreshchange1()
        },
        CurrentChange2 (currentPage) {
            this.page2.currentPage = currentPage;
            this.refreshchange2();
            this.page2.currentPage = currentPage
            this.refreshchange2()
        },
        SizeChange2 (pageSize) {
            this.page2.pageSize = pageSize;
            this.refreshchange2();
            this.page2.pageSize = pageSize
            this.refreshchange2()
        },
        // refreshChange1() {
        //   this.getPractitionersPageInfo();
@@ -324,75 +303,75 @@
        // },
        rowSave2 (form, done, loading) {
            form.securityid = this.id;
            form.securityid = this.id
            add(form).then(
                (res) => {
                    this.getPerformancePageInfo(this.page2);
                    this.getPerformancePageInfo(this.page2)
                    this.$message({
                        type: "success",
                        message: "操作成功!",
                    });
                    done();
                    })
                    done()
                },
                (error) => {
                    window.console.log(error);
                    loading();
                    window.console.log(error)
                    loading()
                }
            );
            )
            // }
        },
        //从业记录新增
        rowSave1 (form, done, loading) {
            form.securityid = this.id;
            form.securityid = this.id
            addExperience(form).then(
                (res) => {
                    this.getPractitionersPageInfo(this.page1);
                    this.getPractitionersPageInfo(this.page1)
                    this.$message({
                        type: "success",
                        message: "操作成功!",
                    });
                    done();
                    })
                    done()
                },
                (error) => {
                    window.console.log(error);
                    loading();
                    window.console.log(error)
                    loading()
                }
            );
            )
            // }
        },
        rowUpdate2 (row, index, done, loading) {
            row.securityid = this.id;
            row.securityid = this.id
            update(row).then(
                () => {
                    this.getPerformancePageInfo(this.page2);
                    this.getPerformancePageInfo(this.page2)
                    this.$message({
                        type: "success",
                        message: "操作成功!",
                    });
                    done();
                    })
                    done()
                },
                (error) => {
                    window.console.log(error);
                    loading();
                    window.console.log(error)
                    loading()
                }
            );
            )
        },
        rowUpdate1 (row, index, done, loading) {
            row.securityid = this.id;
            row.securityid = this.id
            updateExperience(row).then(
                () => {
                    this.getPractitionersPageInfo(this.page1);
                    this.getPractitionersPageInfo(this.page1)
                    this.$message({
                        type: "success",
                        message: "操作成功!",
                    });
                    done();
                    })
                    done()
                },
                (error) => {
                    window.console.log(error);
                    loading();
                    window.console.log(error)
                    loading()
                }
            );
            )
        },
        rowDel2 (row) {
            this.$confirm("确定将选择数据删除?", {
@@ -401,15 +380,15 @@
                type: "warning",
            })
                .then(() => {
                    return remove(row.id);
                    return remove(row.id)
                })
                .then(() => {
                    this.getPerformancePageInfo(this.page2);
                    this.getPerformancePageInfo(this.page2)
                    this.$message({
                        type: "success",
                        message: "操作成功!",
                    });
                });
                    })
                })
        },
        rowDel1 (row) {
            this.$confirm("确定将选择数据删除?", {
@@ -418,53 +397,57 @@
                type: "warning",
            })
                .then(() => {
                    return experienceRemove(row.id);
                    return experienceRemove(row.id)
                })
                .then(() => {
                    this.getPractitionersPageInfo(this.page1);
                    this.getPractitionersPageInfo(this.page1)
                    this.$message({
                        type: "success",
                        message: "操作成功!",
                    });
                });
                    })
                })
        },
    },
    mounted () {
        this.typeTABS = this.optionTABS.column[0];
        var data = JSON.parse(this.$route.query.row);
        this.typeTABS = this.optionTABS.column[0]
        var data = JSON.parse(this.$route.query.row)
        // console.log(data);
        if (data) {
            var row = data;
            var row = data
            // var row = this.$route.query.row;
            for (var k in row) {
                this.obj0[k] = row[k];
                this.obj0[k] = row[k]
            }
            this.obj0.title = "";
            this.cardid = row.id;
            this.name = row.name;
            this.dispatcherCompany = row.dispatcherCompany;
            this.id = row.id;
            this.hold = row.hold;
            console.log(this.obj0);
            this.obj0.title = ""
            this.cardid = row.id
            this.name = row.name
            this.dispatcherCompany = row.dispatcherCompany
            this.id = row.id
            this.hold = row.hold
            let year = row.cardid.slice(6, 10)
            let mouth = row.cardid.slice(10, 12)
            let day = row.cardid.slice(12, 14)
            this.obj0.birthdayData = year + '-' + mouth + '-' + day
            console.log(this.obj0)
        }
        var flag = false,
            i = 0,
            ind = null;
            ind = null
        this.$store.state.tags.tagList.forEach((item, index) => {
            if (item.label == "保安员详情") {
                if (flag == false) {
                    ind = index;
                    flag = true;
                    ind = index
                    flag = true
                }
                i++;
                i++
            }
        });
        })
        if (i > 1) {
            this.$store.state.tags.tagList.splice(ind, 1);
            this.$store.state.tags.tagList.splice(ind, 1)
        }
    },
};
}
</script>
<style lang="scss">
@@ -474,6 +457,7 @@
    //   border: 1px solid #000;
    box-sizing: border-box;
}
// .el-card__body {
//   padding-bottom: 5px !important;
// }
@@ -500,6 +484,7 @@
    align-items: center;
    justify-content: center;
}
.baz-main {
    position: relative;
    top: 15px;
@@ -514,11 +499,13 @@
    justify-content: center;
    flex-direction: column;
}
.baz-m-body {
    width: 750px;
    height: 550px;
    background-image: url('/img/register/bazbj1.png');
    background-size: 100% 100%;
    .bmb-heard {
        font-size: 4rem;
        width: 100%;
@@ -529,6 +516,7 @@
        position: relative;
        top: 20px;
    }
    .img {
        width: 358px;
        height: 441px;
@@ -540,11 +528,13 @@
        display: flex;
        align-items: center;
        justify-content: center;
        img {
            width: 100%;
            height: 100%;
        }
    }
    .imgs {
        width: 110px;
        height: 110px;
@@ -556,11 +546,13 @@
        display: flex;
        align-items: center;
        justify-content: center;
        img {
            width: 100%;
            height: 100%;
        }
    }
    .bmb-b {
        padding-left: 20px;
        box-sizing: border-box;
@@ -569,6 +561,7 @@
        width: 100%;
        font-size: 2rem;
        font-weight: 300;
        .bmb-b-s {
            display: inline-block;
            width: 20rem;
@@ -577,6 +570,7 @@
        }
    }
}
.PrintBut {
    margin-top: 15px;
}