Administrator
2021-08-31 616ff36b461cf7bb0e9aaab348cd826ac003893b
设备修改
5 files modified
129 ■■■■■ changed files
public/papers.html 99 ●●●● patch | view | raw | blame | history
src/views/securityEquipment/equipments.vue 4 ●●● patch | view | raw | blame | history
src/views/securityGuard/data.js 17 ●●●●● patch | view | raw | blame | history
src/views/securityGuard/securityGuard.vue 5 ●●●●● patch | view | raw | blame | history
src/views/securityUnitChild/index.vue 4 ●●● patch | view | raw | blame | history
public/papers.html
@@ -18,9 +18,9 @@
        } */
        
        .print {
            position: absolute;
            position: relative;
            left: 47%;
            top: 58%;
            margin-top: 30px;
            width: 7%;
            height: 30px;
            border: 0px;
@@ -68,9 +68,7 @@
<body>
    <div>
        <div class="print-header">
            <button onclick="preview(1)" class="print">打印</button>
        </div>
        <!--startprint-->
        <div id="table">
            <!-- <span class="title">准考证信息</span>
@@ -122,26 +120,30 @@
                    <td></td>
                </tr>
            </table>
        </div> -->
            <!--endprint-->
            </table>-->
        </div>
        <script>
            var getData = function(name) {
                var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
                var r = window.location.search.substr(1).match(reg);
                if (r != null) return unescape(r[2]);
                return null;
            };
            var id = JSON.parse(getData("data")).id;
            var examType = JSON.parse(getData("data")).examType;
            // console.log(JSON.parse(getData("data")), 111);
        <!--endprint-->
            axios.get('http://223.82.109.183:2080/api/apply/getApplyInfo?id=' + id + "&applyExamType=" + examType).then(function(res) {
                // axios.get('http://localhost:81/apply/getApplyInfo?id=' + id + "&applyExamType=" + examType).then(function(res) {
                var data = res.data.data;
                var str = `<span class="title">${data.examName}</span>
        <div class="print-header">
            <button onclick="preview(1)" class="print">打印</button>
        </div>
    </div>
    <script>
        var getData = function(name) {
            var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
            var r = window.location.search.substr(1).match(reg);
            if (r != null) return unescape(r[2]);
            return null;
        };
        var id = JSON.parse(getData("data")).id;
        var examType = JSON.parse(getData("data")).examType;
        // console.log(JSON.parse(getData("data")), 111);
        axios.get('http://223.82.109.183:2080/api/apply/getApplyInfo?id=' + id + "&applyExamType=" + examType).then(function(res) {
            // axios.get('http://localhost:81/apply/getApplyInfo?id=' + id + "&applyExamType=" + examType).then(function(res) {
            var data = res.data.data;
            var str = `<span class="title">${data.examName}</span>
                    <span class="title">准考证信息</span>
                    <table class="user-info-table" border="1px" align="center" cellspacing="0" cellpadding="10">
                        <tr class="user-info-tr">
@@ -191,35 +193,34 @@
                            <td></td>
                        </tr>
                    </table>
                </div>`
                    </table>`
                var dom = $('#table');
                dom.empty();
                dom.append(str);
            })
            var dom = $('#table');
            dom.empty();
            dom.append(str);
        })
            function preview(oper) {
                if (oper < 10) {
                    bdhtml = window.document.body.innerHTML;
                    // 打印开始的标志
                    sprnstr = "<!--startprint-->";
                    // 打印结束的标志
                    eprnstr = "<!--endprint-->";
                    // 从打印开始的位置截取到末尾
                    prnhtml = bdhtml.substr(bdhtml.indexOf(sprnstr));
                    // 从开始截取到打印结束的位置
                    prnhtml = prnhtml.substring(0, prnhtml.indexOf(eprnstr));
                    // 替换html
                    window.document.body.innerHTML = prnhtml;
                    // 打印
                    window.print();
                    window.document.body.innerHTML = bdhtml;
                } else {
                    window.print();
                }
        function preview(oper) {
            if (oper < 10) {
                bdhtml = window.document.body.innerHTML;
                // 打印开始的标志
                sprnstr = "<!--startprint-->";
                // 打印结束的标志
                eprnstr = "<!--endprint-->";
                // 从打印开始的位置截取到末尾
                prnhtml = bdhtml.substr(bdhtml.indexOf(sprnstr));
                // 从开始截取到打印结束的位置
                prnhtml = prnhtml.substring(0, prnhtml.indexOf(eprnstr));
                // 替换html
                window.document.body.innerHTML = prnhtml;
                // 打印
                window.print();
                window.document.body.innerHTML = bdhtml;
            } else {
                window.print();
            }
        </script>
        }
    </script>
</body>
</html>
src/views/securityEquipment/equipments.vue
@@ -263,12 +263,14 @@
      // console.log(params.deptId);
      if (this.fromDeptId != undefined) {
        params["deptId"] = this.fromDeptId;
        this.option.column[4].search = false;
        this.option.column[6].search = false;
        this.option.column[6].hide = true;
        this.option.column[6].addDisplay = false;
        this.option.column[6].editDisplay = false;
      } else {
        this.option.column[6].search = true;
        this.option.column[4].search = true;
          this.option.column[6].search = true;
        this.option.column[6].hide = false;
        this.option.column[6].addDisplay = true;
        this.option.column[6].editDisplay = true;
src/views/securityGuard/data.js
@@ -483,12 +483,29 @@
            label: "title",
            value: "id",
        },
        // hide: true,
        slot: true,
        searchSpan: 5,
        display: false,
        search: true,
        minWidth: 260
    },
    // {
    //     label: "所属保安公司",
    //     searchLabelWidth: "110",
    //     prop: "deptName",
    //     // type: "tree",
    //     // dicUrl: "/api/blade-system/dept/security_lazy-tree?parentId=1413470343230877697",
    //     // props: {
    //     //     label: "title",
    //     //     value: "id",
    //     // },
    //     // slot: true,
    //     // searchSpan: 5,
    //     display: false,
    //     // search: true,
    //     minWidth: 260
    // },
    {
        label: "性别",
        prop: "sex",
src/views/securityGuard/securityGuard.vue
@@ -144,7 +144,7 @@
              class="rowClickSelf"
              title="点击查看所属公司情况"
              @click="rowClickSelf(row.deptId)"
              >{{ row.$deptId }}</el-tag
              >{{ row.deptName }}</el-tag
            >
          </template>
          <template slot-scope="{ row }" slot="tenantName">
@@ -1193,8 +1193,7 @@
          var roleAlias = res.data.data.roleAlias;
          if (
            roleAlias == "保安公司管理员" ||
            roleAlias == "保安" ||
            roleAlias == "未持证保安"
            roleAlias == "保安"
          ) {
            //去除保安公司查询
            const column = that.findObject(that.option.column, "deptId");
src/views/securityUnitChild/index.vue
@@ -622,6 +622,7 @@
      this.loading1 = true;
      console.log(page, params, 3435434);
      params["creditcode"] = this.creditcode;
      params["deptId"] = this.departmentid;
      getdataOnce1(
        page.currentPage,
        page.pageSize,
@@ -768,6 +769,7 @@
      // console.log(page);
      // getdata2(
      params["creditcode"] = this.creditcode;
      params["deptId"] = this.departmentid;
      getdataOnce2(
        page.currentPage,
        page.pageSize,
@@ -796,7 +798,7 @@
        if (that.readLock("danweidata") != null) {
          row = JSON.parse(that.readLock("danweidata"));
          // that.obj0.title = row.enterprisename;
          console.log(row, "row");
          console.log(row, "rowneibu");
          that.departmentid = row.departmentid;
          for (var k in row) {
            that.obj0[k] = row[k];