Browse Source

凌云集团更改公司

peiguo 5 years ago
parent
commit
68dc37663b

+ 4 - 4
admin-ui/app/whepi/lingyun/lingyunUser.js

@@ -157,10 +157,10 @@ define(function (require) {
                   [
                     {field: 'userId', title: '用户ID', hidden: true},
                     {field: 'linkman', title: '用户名', maxWidth: 200, align: 'left',},
-                    {field: 'uptownName', title: '小区名称', maxWidth: 200, align: 'left',},
-                    {field: 'phone', title: '电话', maxWidth: 200, align: 'left',},
-                    {field: 'dept', title: '部门', maxWidth: 200, align: 'left',},
-
+                    {field: 'dept', title: '部门名称', maxWidth: 200, align: 'left',},
+                    {field: 'phone', title: '联系电话', maxWidth: 200, align: 'left',},
+                    {field: 'doorplate', title: '工号', maxWidth: 200, align: 'left',},
+                    {field: 'door', title: '病情表述', maxWidth: 200, align: 'left',},
                   ]
                 ]
             }

+ 153 - 0
admin-ui/app/whepi/lingyun/lingyunUser2.js

@@ -0,0 +1,153 @@
+define(function (require) {
+    return function (context) {
+
+      var $grid1, $form;
+
+      // 输入搜索文本后点击回车按钮查询列表
+      function enterQueryGrid1(e) {
+        if (e.keyCode === 13) {
+          var tmp = $(this).val();
+          $form.formSet({queryProperties: tmp});
+          queryGrid1();
+        }
+      }
+
+      // 弹框的方式
+      var widgets = {
+        // 搜索分类检索
+        selectTableUnit: {
+          url: 'app/whepi/home/selectLYbumen.js',
+          bind: {
+            unitId: 'unitId',
+            unit: 'unit',
+          },
+        },
+      };
+
+      // 检索条件查询
+      function queryGrid1() {
+        var queryForm = $form.formGet();
+        $grid1.reload({
+          mtype: 'POST',
+          url: api('/sweepCode/selectLingyunUser'),
+          queryParams: queryForm
+        }, true);
+      }
+
+      var queryToolbar = {
+        xtype: 'toolbar',
+        title: '用户管理',
+        items: [
+          {
+            text: '查询', iconCls: 'fa fa-search', onClick: function () {
+              queryGrid1();
+            }
+          }, {
+            text: '重置', iconCls: 'fa fa-refresh', onClick: function () {
+              $form.formClear();
+              queryGrid1();
+            }
+          }, {
+            text: '关闭', iconCls: 'fa fa-times-circle', onClick: function () {
+              App.closeMe(this);
+            }
+          }
+        ]
+      };
+
+      var queryForm = {
+        onRender: function () {
+          $form = $(this);
+        },
+        xtype: 'form',
+        items: [[
+          {
+            xtype: 'textbox',
+            label: '检索条件',
+            name: 'queryProperties',
+            prompt: "用户名称/电话号码",
+            labelWidth: 'auto',
+            events: {keydown: enterQueryGrid1}, width: 350
+          },
+        ]]
+      };
+
+      return {
+        north: {
+          height: 88,
+          /* split: true,
+           border: false,*///底框是否可变动
+          items: [
+            queryToolbar,
+            queryForm
+          ]
+        },
+        center: {
+          height: '60%',
+          split: true,
+          items:
+            {
+              onRender: function () {
+                $grid1 = $(this);
+                queryGrid1()
+              },
+              xtype: 'grid',
+              toolbar: {
+                xtype: 'toolbar',
+                title: '用户列表',
+                items: [
+                  {
+                    text: '生成健康及旅居申请表', iconCls: 'fa fa-plus-circle fa-lg', onClick: function () {
+                      var row = $grid1.checkedData();
+                      if (row.length == 0) {
+                        $.yvan.msg('请至少选择一行数据');
+                        return;
+                      }
+                      var ids = "";
+                      for (var i = 0; i < row.length; i++) {
+                        ids += row[i].userId + ","
+                      }
+                      ids=ids.substring(0,ids.length-1);
+                      window.open(api('/export/lyReports?userId=' + ids));
+                    }
+                  },
+                  {
+                    text: '生成隔离人员解除隔离审批表', iconCls: 'fa fa-plus-circle fa-lg', onClick: function () {
+                      var row = $grid1.checkedData();
+                      if (row.length == 0) {
+                        $.yvan.msg('请至少选择一行数据');
+                        return;
+                      }
+                      var ids = "";
+                      for (var i = 0; i < row.length; i++) {
+                        ids += row[i].userId + ","
+                      }
+                      ids=ids.substring(0,ids.length-1);
+                      window.open(api('/export/lyApproves?userId=' + ids));
+                    }
+                  }
+
+                ]
+              },
+              multiselect: true, /// 表格多选
+              idField: 'userId',
+              editable: true,
+              editOnSelected: true,
+              autoSizeColumns: true,
+              columns:
+                [
+                  [
+                    {field: 'userId', title: '用户ID', hidden: true},
+                    {field: 'linkman', title: '用户名', maxWidth: 200, align: 'left',},
+                    {field: 'dept', title: '部门名称', maxWidth: 200, align: 'left',},
+                    {field: 'phone', title: '联系电话', maxWidth: 200, align: 'left',},
+                    {field: 'doorplate', title: '工号', maxWidth: 200, align: 'left',},
+                    {field: 'door', title: '病情表述', maxWidth: 200, align: 'left',},
+                  ]
+                ]
+            }
+        }
+      };
+    };
+  }
+);

+ 2 - 2
admin-ui/app/whepi/mock/menu6.json

@@ -4,8 +4,8 @@
   "data": [
     {
       "id": "ENT10001",
-      "text": "资源需求管理",
-      "href": "/app/whepi/tugou/tugou.js",
+      "text": "凌云导出报表",
+      "href": "/app/whepi/lingyun/lingyunUser2.js",
       "iconCls": "icon-blank fa fa-align-justify",
       "state": "close",
       "children": []

+ 6 - 0
whepi-web/src/main/java/com/bofeng/service/SweepCodeService.java

@@ -1,6 +1,7 @@
 package com.bofeng.service;
 
 
+import com.bofeng.JwtHelper;
 import com.bofeng.dao.OutScanEstateMapper;
 import com.bofeng.dao.SweepCodeMapper;
 import com.bofeng.entity.OutScanEstate;
@@ -30,6 +31,11 @@ public class SweepCodeService {
 
 
     public List<SysUptownHouse> selectLingyunUser(PageDb pageDb, Map<String, Object> queryParam) {
+        Long userId = JwtHelper.getUserId();
+        if (userId > 7000 && userId < 8000) {
+            queryParam.put("unitId", userId);
+        }
+        queryParam.put("uptownId", 1238790987234L);
         List<SysUptownHouse> sysUptownHouses = sweepCodeMapper.selectLingyunUser(pageDb,queryParam);
         return sysUptownHouses;
     }

+ 5 - 1
whepi-web/src/main/resources/mapper/SweepCodeMapper.xml

@@ -43,18 +43,22 @@
      b.user_id,
      a.linkman,
      a.phone,
+     c.doorplate,
      e.uptown_name,
      concat(d.ridgepole,d.unit) as dept
      from sys_uptown_home a
      inner join sys_user_role b on a.house_id = b.property_id and b.role_id =1
      inner join sys_uptown_house c on c.house_id = b.property_id
      inner join sys_uptown_unit d on c.unit_id = d.unit_id
-     inner join sys_uptown e on e.uptown_id = d.uptown_id and e.uptown_id = 1238790987234
+     inner join sys_uptown e on e.uptown_id = d.uptown_id
         <where>
          <if test="queryProperties != null and queryProperties != ''">
           (a.linkman like concat('%',#{queryProperties},'%')
           or a.phone like concat('%',#{queryProperties},'%'))
          </if>
+         <if test="uptownId != null and uptownId != ''">
+            and e.uptown_id = #{uptownId}
+         </if>
          <if test="unitId != null and unitId != ''">
             and d.unit_id = #{unitId}
          </if>