Browse Source

修改权限管理中权限树查询异常

shilin 3 years ago
parent
commit
973743ffc5
56 changed files with 2745 additions and 794 deletions
  1. 0 184
      web/health-hb/target/classes/templates/admin/province/sysProvince/edit.html
  2. 14 11
      web/monitor-web-sxjn/src/main/java/com/gyee/SpringbootStart.java
  3. 0 4
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/common/interceptor/MyInterceptor.java
  4. 12 11
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/common/log/LogAspect.java
  5. 12 5
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/controller/AdminController.java
  6. 213 0
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/controller/admin/SysCompanyController.java
  7. 9 13
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/controller/admin/SysDepartmentController.java
  8. 11 21
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/controller/admin/UserController.java
  9. 0 96
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/auto/EarlywarningmainMapper.java.1
  10. 0 96
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/auto/EarlywarningmainMapper.java.2
  11. 32 0
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/auto/SysCompanyMapper.java
  12. 3 2
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/auto/SysDepartmentMapper.java
  13. 2 1
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/auto/TsysUserMapper.java
  14. 2 1
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/custom/TsysUserDao.java
  15. 121 0
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/SysCompany.java
  16. 602 0
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/SysCompanyExample.java
  17. 5 6
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/SysDepartment.java
  18. 12 12
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/SysDepartmentExample.java
  19. 33 16
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/TsysUser.java
  20. 71 10
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/TsysUserExample.java
  21. 37 3
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/TvueUser.java
  22. 124 62
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/TvueUserExample.java
  23. 192 0
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/SysCompanyService.java
  24. 6 12
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/SysDepartmentService.java
  25. 8 13
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/SysNoticeService.java
  26. 10 15
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/SysUserService.java
  27. 2 3
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/WindPowerstationTestingPoint2Service.java
  28. 29 23
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/initialpoint/InitialPointEdosService.java
  29. 1 1
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/websocket/GenreSetPushService.java
  30. 2 2
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/websocket/WpInfoPushService.java
  31. 1 1
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/websocket/WtWarnPushService.java
  32. 5 3
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/websocket/task/V2Task.java
  33. 15 3
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/shiro/config/ShiroService.java
  34. 3 3
      web/monitor-web-sxjn/src/main/java/com/gyee/frame/shiro/service/MyShiroRealm.java
  35. 16 17
      web/monitor-web-sxjn/src/main/resources/application-dev.yml
  36. 49 49
      web/monitor-web-sxjn/src/main/resources/application.yml
  37. 11 4
      web/monitor-web-sxjn/src/main/resources/mybatis-generator.xml
  38. 257 0
      web/monitor-web-sxjn/src/main/resources/mybatis/auto/SysCompanyMapper.xml
  39. 3 3
      web/monitor-web-sxjn/src/main/resources/mybatis/auto/SysDepartmentMapper.xml
  40. 26 7
      web/monitor-web-sxjn/src/main/resources/mybatis/auto/TsysUserMapper.xml
  41. 20 5
      web/monitor-web-sxjn/src/main/resources/mybatis/auto/TvueUserMapper.xml
  42. 6 3
      web/monitor-web-sxjn/src/main/resources/mybatis/custom/TsysUserMapper.xml
  43. 3 4
      web/monitor-web-sxjn/src/main/resources/mybatis/custom/TvuePremissionMapper.xml
  44. 6 3
      web/monitor-web-sxjn/src/main/resources/mybatis/custom/TvueUserMapper.xml
  45. BIN
      web/monitor-web-sxjn/src/main/resources/static/syz.7z
  46. 174 0
      web/monitor-web-sxjn/src/main/resources/templates/admin/sysCompany/add.html
  47. 21 59
      web/analysis-hb/target/classes/templates/admin/province/sysProvince/edit.html
  48. 314 0
      web/monitor-web-sxjn/src/main/resources/templates/admin/sysCompany/list.html
  49. 190 0
      web/monitor-web-sxjn/src/main/resources/templates/admin/sysCompany/tree.html
  50. 2 3
      web/monitor-web-sxjn/src/main/resources/templates/admin/sysDepartment/list.html
  51. 12 1
      web/monitor-web-sxjn/src/main/resources/templates/admin/user/add.html
  52. 14 1
      web/monitor-web-sxjn/src/main/resources/templates/admin/user/edit.html
  53. 4 0
      web/monitor-web-sxjn/src/main/resources/templates/admin/user/list.html
  54. 11 1
      web/monitor-web-sxjn/src/main/resources/templates/admin/uservue/add.html
  55. 13 1
      web/monitor-web-sxjn/src/main/resources/templates/admin/uservue/edit.html
  56. 4 0
      web/monitor-web-sxjn/src/main/resources/templates/admin/uservue/list.html

+ 0 - 184
web/health-hb/target/classes/templates/admin/province/sysProvince/edit.html

@@ -1,184 +0,0 @@
-<!DOCTYPE html>
-<html xmlns:th="http://www.thymeleaf.org" 
-      xmlns:sec="http://www.pollix.at/thymeleaf/shiro">
-<head th:replace="admin/common/html/tableHead :: tableHead(~{::title},~{::link},~{::style})">
-
-<title th:text=${title}></title>
-<!-- 这儿引用单独的css link -->
-<!-- Ladda for Bootstrap 3按钮加载进度插件 -->
-<link rel="stylesheet" th:href="@{/static/admin/assets/js/button/ladda/ladda.min.css}">
-<!-- bootstrap-table表单样式 -->
-<link th:href="@{/static/admin/assets/js/bootstrap/css/bootstrap-table/bootstrap-table.min.css}" rel="stylesheet"/>
-
-<!-- 用户界面自定义css -->
-<link th:href="@{/static/admin/user/css/user-add.css}" rel="stylesheet"/>
-<style type="text/css"></style>
-
-</head>
-
-<body>
-      	   	      	      	      	      	      	      	      	      	      	      	      
-<div class="content-wrap">
-	<div class="row">
-		<div class="col-sm-12">
-			<div class="nest" id="elementClose">
-				<div class="">
-				</div>
-				<div class="body-nest" id="element">
-					<div class="panel-body">
-						<form  class="form-horizontal m" id="form-edit" th:object="${SysProvince}">
-							<input id="id" name="id" type="hidden" th:field="*{id}"/>
-						
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">省份代码:</label>
-										<div class="col-sm-8">
-											<input class="form-control" type="text" id="provinceCode" name="provinceCode" th:value="*{provinceCode}"/>
-										</div>
-									</div>
-
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">省份名称:</label>
-										<div class="col-sm-8">
-											<input class="form-control" type="text" id="provinceName" name="provinceName" th:value="*{provinceName}"/>
-										</div>
-									</div>
-
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">简称:</label>
-										<div class="col-sm-8">
-											<input class="form-control" type="text" id="shortName" name="shortName" th:value="*{shortName}"/>
-										</div>
-									</div>
-
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">经度:</label>
-										<div class="col-sm-8">
-											<input class="form-control" type="text" id="lng" name="lng" th:value="*{lng}"/>
-										</div>
-									</div>
-
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">纬度:</label>
-										<div class="col-sm-8">
-											<input class="form-control" type="text" id="lat" name="lat" th:value="*{lat}"/>
-										</div>
-									</div>
-
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">排序:</label>
-										<div class="col-sm-8">
-											<input class="form-control" type="number" id="sort" name="sort" th:value="*{sort}"/>
-										</div>
-									</div>
-
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">创建时间:</label>
-										<div class="col-sm-8">
-											<input class="form-control MyDate" type="text" id="gmtCreate" name="gmtCreate" th:value="*{#dates.format(gmtCreate,'yyyy-MM-dd HH:mm:ss')}"/>
-										</div>
-									</div>
-									
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">修改时间:</label>
-										<div class="col-sm-8">
-											<input class="form-control MyDate" type="text" id="gmtModified" name="gmtModified" th:value="*{#dates.format(gmtModified,'yyyy-MM-dd HH:mm:ss')}"/>
-										</div>
-									</div>
-									
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">备注:</label>
-										<div class="col-sm-8">
-											<input class="form-control" type="text" id="memo" name="memo" th:value="*{memo}"/>
-										</div>
-									</div>
-
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">状态:</label>
-										<div class="col-sm-8">
-											<select name="dataState" id="dataState"  class="form-control m-b" th:with="type=${@dict.getType('sys_province_state')}" th:field="*{dataState}">
-												<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
-											</select>
-										</div>
-									</div>
-
-			
-									<div class="form-group">
-										<div class="form-control-static col-sm-offset-9">
-											<button type="submit" class="btn btn-primary">提交</button>
-											<button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>
-										</div>
-									</div>
-						</form>
-					</div>
-				</div>
-			</div>
-		</div>
-	</div>
-</div>
-
-<!-- 通用js -->
-<div th:include="admin/common/html/js :: onload_js">
-   
-</div>
-<!-- bootstarp 表格 -->
-<script th:src="@{/static/admin/assets/js/bootstrap/js/bootstrap-table/bootstrap-table.min.js}" type="text/javascript"></script>
-<script th:src="@{/static/admin/assets/js/bootstrap/js/bootstrap-table/locale/bootstrap-table-zh-CN.min.js}" type="text/javascript"></script>
-<script th:src="@{/static/admin/assets/js/bootstrap/js/base_list.js}" type="text/javascript"></script>
-
-
-<!-- 弹窗 -->
-<script th:src="@{/static/admin/assets/js/layer/layer.js}" type="text/javascript"></script>
-<!-- 遮罩层 -->
-<script th:src="@{/static/admin/assets/js/blockUI/jquery.blockUI.js}" type="text/javascript"></script>
-<script type="text/javascript">
-$(function(){
-	 $(".MyDate").datetimepicker({
-		 	format: "yyyy-mm-dd hh:00:00",
-	        startDate: new Date(),
-	        autoclose: true,
-	        todayBtn: true,
-	        language: 'zh-CN',
-	        initialDate:new Date(),
-	        minView: 1      
-	    });
-	
-})
-
-
-$("#form-edit").validate({
-	submitHandler : function(form) {
-		edit();
-	}
-});
-
-function edit() {
-	var dataFormJson = $("#form-edit").serialize();
-	$.ajax({
-		cache : true,
-		type : "POST",
-		url : rootPath + "/SysProvinceController/edit",
-		data : dataFormJson,
-		async : false,
-		error : function(request) {
-			$.modal.alertError("系统错误");
-		},
-		success : function(data) {
-			$.operate.saveSuccess(data);
-		}
-	});
-}
-</script>
-
-</body>
-
-
-</html>

+ 14 - 11
web/monitor-web-sxjn/src/main/java/com/gyee/SpringbootStart.java

@@ -1,7 +1,5 @@
 package com.gyee;
 
-import com.gyee.frame.common.spring.SpringUtils;
-import com.gyee.frame.service.initialpoint.InitialPointEdosService;
 import org.springframework.boot.SpringApplication;
 import org.springframework.boot.autoconfigure.SpringBootApplication;
 import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
@@ -26,18 +24,23 @@ public class SpringbootStart {
 
 
 
-        InitialPointEdosService initialPointEdosService= SpringUtils.getBean("initialPointEdosService");
+//        InitialPointEdosService initialPointEdosService= SpringUtils.getBean("initialPointEdosService");
+//
+//        System.out.println("开始导出风机测点。。。。。。");
+//        initialPointEdosService.initalFj();
+//        System.out.println("结束导出风机测点。。。。。。");
+//
+//        System.out.println("开始导出风场测点。。。。。。");
+//        initialPointEdosService.initalFc(false);
+//        System.out.println("结束导出风场测点。。。。。。");
+//
+//        System.out.println("开始导出风功率测点。。。。。。");
+//        initialPointEdosService.initalFgl();
+//        System.out.println("结束导出风功率测点。。。。。。");
 
 
+        System.out.println("初始化结束!");
 
-//        InitialRedis initialRedis=new InitialRedis();
-//        System.out.println("初始化开始!");
-//        initialRedis.intialWindturbinepowercurvefitting();
-////        initialRedis.intialWpScatter();
-////        initialRedis.intialPjScatter();
-////        initialRedis.intialLnScatter();
-////        initialRedis.intialWtScatter();
-        System.out.println("初始化完成!");
 
 
     }

+ 0 - 4
web/monitor-web-sxjn/src/main/java/com/gyee/frame/common/interceptor/MyInterceptor.java

@@ -5,10 +5,6 @@ import java.util.List;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 
-import com.gyee.frame.model.auto.TsysUser;
-import org.apache.shiro.SecurityUtils;
-import org.apache.shiro.authc.UsernamePasswordToken;
-import org.apache.shiro.subject.Subject;
 import org.springframework.web.servlet.HandlerInterceptor;
 import org.springframework.web.servlet.ModelAndView;
 import com.gyee.frame.common.conf.V2Config;

+ 12 - 11
web/monitor-web-sxjn/src/main/java/com/gyee/frame/common/log/LogAspect.java

@@ -1,8 +1,12 @@
 package com.gyee.frame.common.log;
 
-import java.lang.reflect.Method;
-import java.util.Date;
-import java.util.Map;
+import com.google.gson.Gson;
+import com.gyee.frame.model.auto.TsysOperLog;
+import com.gyee.frame.model.auto.TsysUser;
+import com.gyee.frame.service.SysOperLogService;
+import com.gyee.frame.shiro.util.ShiroUtils;
+import com.gyee.frame.util.ServletUtils;
+import com.gyee.frame.util.StringUtils;
 import org.aspectj.lang.JoinPoint;
 import org.aspectj.lang.Signature;
 import org.aspectj.lang.annotation.AfterReturning;
@@ -12,17 +16,14 @@ import org.aspectj.lang.annotation.Pointcut;
 import org.aspectj.lang.reflect.MethodSignature;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
-import javax.annotation.Resource;
 import org.springframework.scheduling.annotation.Async;
 import org.springframework.scheduling.annotation.EnableAsync;
 import org.springframework.stereotype.Component;
-import com.gyee.frame.model.auto.TsysOperLog;
-import com.gyee.frame.model.auto.TsysUser;
-import com.gyee.frame.service.SysOperLogService;
-import com.gyee.frame.shiro.util.ShiroUtils;
-import com.gyee.frame.util.ServletUtils;
-import com.gyee.frame.util.StringUtils;
-import com.google.gson.Gson;
+
+import javax.annotation.Resource;
+import java.lang.reflect.Method;
+import java.util.Date;
+import java.util.Map;
 
 /**
  * 操作日志记录处理

+ 12 - 5
web/monitor-web-sxjn/src/main/java/com/gyee/frame/controller/AdminController.java

@@ -8,6 +8,7 @@ import com.gyee.frame.common.domain.AjaxResult;
 import com.gyee.frame.common.websocket.WebSocketLoginOutEvent;
 import com.gyee.frame.model.auto.SysNotice;
 import com.gyee.frame.model.auto.TsysUser;
+import com.gyee.frame.model.auto.TvuePermission;
 import com.gyee.frame.model.custom.BootstrapTree;
 import com.gyee.frame.model.custom.ElementNode;
 import com.gyee.frame.model.custom.TitleVo;
@@ -31,10 +32,7 @@ import org.springframework.web.servlet.mvc.support.RedirectAttributes;
 import javax.annotation.Resource;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
+import java.util.*;
 
 /**
  * 后台方法
@@ -193,7 +191,7 @@ public class AdminController extends BaseController {
 	@PostMapping("/loginvue")
 	@ResponseBody
 	public AjaxResult loginvue(TsysUser user,
-							HttpServletRequest request) {
+                               HttpServletRequest request) {
 		// ModelAndView view =new ModelAndView();
 
 			String userName = user.getUsername();
@@ -224,6 +222,15 @@ public class AdminController extends BaseController {
 							Map<String, Object> result = new HashMap<>();
 							result.put(AUTHTOKEN, customtoken);
 							result.put("user", customuser);
+
+                            if(StringUtils.notEmp(customuser))
+                            {
+                                List<TvuePermission> list= vuePermissionService.getall(customuser.getLaborNum());
+                                result.put("prmissionlist", list);
+                            }else
+                            {
+                                result.put("prmissionlist", new ArrayList<>());
+                            }
 							return AjaxResult.successData(AjaxStatus.success.code, result);
 						}
 

+ 213 - 0
web/monitor-web-sxjn/src/main/java/com/gyee/frame/controller/admin/SysCompanyController.java

@@ -0,0 +1,213 @@
+package com.gyee.frame.controller.admin;
+
+import com.github.pagehelper.PageInfo;
+import com.gyee.frame.common.base.BaseController;
+import com.gyee.frame.common.domain.AjaxResult;
+import com.gyee.frame.model.auto.SysCompany;
+import com.gyee.frame.model.custom.TableSplitResult;
+import com.gyee.frame.model.custom.Tablepar;
+import com.gyee.frame.model.custom.TitleVo;
+import com.gyee.frame.service.SysCompanyService;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.stereotype.Controller;
+import org.springframework.ui.ModelMap;
+import org.springframework.web.bind.annotation.*;
+
+import javax.annotation.Resource;
+import java.util.List;
+
+@Api(value = "公司表")
+@Controller
+@RequestMapping("/SysCompanyController")
+public class SysCompanyController extends BaseController{
+	
+	private String prefix = "admin/sysCompany";
+	@Resource
+	private SysCompanyService sysCompanyService;
+	
+	/**
+	 * 分页跳转
+	 * @param model
+	 * @return
+	 * @author gyee
+	 * @Date 2020年4月18日 下午11:48:55
+	 */
+	@ApiOperation(value = "分页跳转", notes = "分页跳转")
+	@GetMapping("/view")
+	@RequiresPermissions("gen:sysCompany:view")
+    public String view(ModelMap model)
+    {	
+		String str="公司表";
+		setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false));
+        return prefix + "/list";
+    }
+	
+	/**
+	 * 分页查询
+	 * @param tablepar
+	 * @param searchText
+	 * @return
+	 * @author gyee
+	 * @Date 2020年4月18日 下午11:48:34
+	 */
+	//@Log(title = "公司表集合查询", action = "111")
+	@ApiOperation(value = "分页查询", notes = "分页查询")
+	@PostMapping("/list")
+	@RequiresPermissions("gen:sysCompany:list")
+	@ResponseBody
+	public Object list(Tablepar tablepar,String searchText){
+		PageInfo<SysCompany> page=sysCompanyService.list(tablepar,searchText) ; 
+		TableSplitResult<SysCompany> result=new TableSplitResult<SysCompany>(page.getPageNum(), page.getTotal(), page.getList()); 
+		return  result;
+	}
+	
+	@ApiOperation(value = "分页查询2", notes = "分页查询2")
+	@PostMapping("/list2")
+	@ResponseBody
+	public Object list2(Tablepar tablepar,String searchText){
+		List<SysCompany> page= sysCompanyService.list2(searchText) ;
+		return  page;
+	}
+	
+	/**
+     * 新增
+     */
+	@ApiOperation(value = "新增跳转", notes = "新增跳转")
+    @GetMapping("/add")
+    public String add(ModelMap modelMap)
+    {
+        return prefix + "/add";
+    }
+	
+    /**
+     * 新增
+     * @param sysCompany
+     * @return
+     * @author gyee
+     * @Date 2020年4月18日 下午11:47:51
+     */
+	//@Log(title = "公司表新增", action = "111")
+    @ApiOperation(value = "新增", notes = "新增")
+	@PostMapping("/add")
+	@RequiresPermissions("gen:sysCompany:add")
+	@ResponseBody
+	public AjaxResult add(SysCompany sysCompany){
+		int b=sysCompanyService.insertSelective(sysCompany);
+		if(b>0){
+			return success();
+		}else{
+			return error();
+		}
+	}
+	
+	/**
+	 * 删除
+	 * @param ids
+	 * @return
+	 */
+	//@Log(title = "公司表删除", action = "111")
+	@ApiOperation(value = "删除", notes = "删除")
+	@PostMapping("/remove")
+	@RequiresPermissions("gen:sysCompany:remove")
+	@ResponseBody
+	public AjaxResult remove(String ids){
+		int b=sysCompanyService.deleteByPrimaryKey(ids);
+		if(b>0){
+			return success();
+		}else{
+			return error();
+		}
+	}
+	
+	/**
+	 * 检查公司
+	 * @return
+	 */
+	@ApiOperation(value = "检查Name唯一", notes = "检查Name唯一")
+	@PostMapping("/checkNameUnique")
+	@ResponseBody
+	public int checkNameUnique(SysCompany sysCompany){
+		int b=sysCompanyService.checkNameUnique(sysCompany);
+		if(b>0){
+			return 1;
+		}else{
+			return 0;
+		}
+	}
+	
+	
+	/**
+	 * 修改跳转
+	 * @param id
+	 * @param mmap
+	 * @return
+	 */
+	@ApiOperation(value = "修改跳转", notes = "修改跳转")
+	@GetMapping("/edit/{id}")
+    public String edit(@PathVariable("id") String id, ModelMap mmap)
+    {
+		//获取自己的权限信息
+		SysCompany mytsysPermission = sysCompanyService.selectByPrimaryKey(id);
+		//获取父权限信息
+		SysCompany department = sysCompanyService.selectByPrimaryKey(mytsysPermission.getParentId());
+		if(department==null) {
+			department=new SysCompany("1", "0", "顶级菜单",  0, 1, 1);
+		}
+        mmap.put("SysCompany", mytsysPermission);
+        mmap.put("perSysCompany", department);
+        return prefix + "/edit";
+    }
+	
+	/**
+     * 修改保存
+     */
+    //@Log(title = "公司表修改", action = "111")
+	@ApiOperation(value = "修改保存", notes = "修改保存")
+    @RequiresPermissions("gen:sysCompany:edit")
+    @PostMapping("/edit")
+    @ResponseBody
+    public AjaxResult editSave(SysCompany record)
+    {
+        return toAjax(sysCompanyService.updateByPrimaryKeySelective(record));
+    }
+
+    
+    /**
+   	 * 根据主键查询
+   	 * 
+   	 * @param id
+   	 * @return
+   	 */
+   	@PostMapping("/get/{id}")
+   	@ApiOperation(value = "根据id查询唯一", notes = "根据id查询唯一")
+   	public SysCompany edit(@PathVariable("id") String id) {
+   		return sysCompanyService.selectByPrimaryKey(id);
+   	}
+    
+   	
+   	/**
+     * 跳转到菜单树页面
+     * @return
+     */
+   	@ApiOperation(value = "跳转到菜单树页面", notes = "跳转到菜单树页面")
+    @GetMapping("/tree")
+    public String Tree(){
+    	 return prefix + "/tree";
+    }
+    
+    /**
+     * 获取菜单树
+     * @param pid 父id【没用到】
+     * @return
+     */
+    @ApiOperation(value = "获取菜单树", notes = "获取菜单树")
+    @PostMapping("/tree/{pid}")
+    @ResponseBody
+    public AjaxResult Tree(@PathVariable("pid") String pid){
+    	return retobject(200, sysCompanyService.getbooBootstrapTreePerm());
+    }
+
+	
+}

+ 9 - 13
web/monitor-web-sxjn/src/main/java/com/gyee/frame/controller/admin/SysDepartmentController.java

@@ -1,15 +1,5 @@
 package com.gyee.frame.controller.admin;
 
-import java.util.List;
-import org.apache.shiro.authz.annotation.RequiresPermissions;
-import javax.annotation.Resource;
-import org.springframework.stereotype.Controller;
-import org.springframework.ui.ModelMap;
-import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.PathVariable;
-import org.springframework.web.bind.annotation.PostMapping;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.ResponseBody;
 import com.github.pagehelper.PageInfo;
 import com.gyee.frame.common.base.BaseController;
 import com.gyee.frame.common.domain.AjaxResult;
@@ -20,6 +10,13 @@ import com.gyee.frame.model.custom.TitleVo;
 import com.gyee.frame.service.SysDepartmentService;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.stereotype.Controller;
+import org.springframework.ui.ModelMap;
+import org.springframework.web.bind.annotation.*;
+
+import javax.annotation.Resource;
+import java.util.List;
 
 @Api(value = "部门表")
 @Controller
@@ -126,7 +123,6 @@ public class SysDepartmentController extends BaseController{
 	
 	/**
 	 * 检查用户
-	 * @param tsysUser
 	 * @return
 	 */
 	@ApiOperation(value = "检查Name唯一", notes = "检查Name唯一")
@@ -157,7 +153,7 @@ public class SysDepartmentController extends BaseController{
 		//获取父权限信息
 		SysDepartment department = sysDepartmentService.selectByPrimaryKey(mytsysPermission.getParentId());
 		if(department==null) {
-			department=new SysDepartment(1, "", "顶级菜单", "", "", "", 0, 1, 1);
+			department=new SysDepartment("1", "", "顶级菜单", "", "", "", 0, 1, 1);
 		}
         mmap.put("SysDepartment", mytsysPermission);
         mmap.put("perSysDepartment", department);
@@ -182,7 +178,7 @@ public class SysDepartmentController extends BaseController{
    	 * 根据主键查询
    	 * 
    	 * @param id
-   	 * @param mmap
+
    	 * @return
    	 */
    	@PostMapping("/get/{id}")

+ 11 - 21
web/monitor-web-sxjn/src/main/java/com/gyee/frame/controller/admin/UserController.java

@@ -1,36 +1,26 @@
 package com.gyee.frame.controller.admin;
 
-import java.util.List;
-import org.apache.shiro.authz.annotation.RequiresPermissions;
-import javax.annotation.Resource;
-import org.springframework.stereotype.Controller;
-import org.springframework.ui.Model;
-import org.springframework.ui.ModelMap;
-import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.PathVariable;
-import org.springframework.web.bind.annotation.PostMapping;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RequestParam;
-import org.springframework.web.bind.annotation.ResponseBody;
+import com.github.pagehelper.PageInfo;
 import com.gyee.frame.common.base.BaseController;
 import com.gyee.frame.common.domain.AjaxResult;
 import com.gyee.frame.common.log.Log;
-import com.gyee.frame.model.auto.SysDepartment;
-import com.gyee.frame.model.auto.SysDepartmentExample;
-import com.gyee.frame.model.auto.SysPosition;
-import com.gyee.frame.model.auto.SysPositionExample;
-import com.gyee.frame.model.auto.TsysRole;
-import com.gyee.frame.model.auto.TsysUser;
+import com.gyee.frame.model.auto.*;
 import com.gyee.frame.model.custom.RoleVo;
 import com.gyee.frame.model.custom.TableSplitResult;
 import com.gyee.frame.model.custom.Tablepar;
 import com.gyee.frame.model.custom.TitleVo;
 import com.gyee.frame.service.SysDepartmentService;
 import com.gyee.frame.service.SysPositionService;
-import com.github.pagehelper.PageInfo;
-
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.stereotype.Controller;
+import org.springframework.ui.Model;
+import org.springframework.ui.ModelMap;
+import org.springframework.web.bind.annotation.*;
+
+import javax.annotation.Resource;
+import java.util.List;
 
 /**
  * 用户Controller
@@ -83,7 +73,7 @@ public class UserController extends BaseController{
 	@RequiresPermissions("system:user:list")
 	@ResponseBody
 	public Object list(Tablepar tablepar,String searchText){
-		PageInfo<TsysUser> page=sysUserService.list(tablepar,searchText) ; 
+		PageInfo<TsysUser> page=sysUserService.list(tablepar,searchText) ;
 		TableSplitResult<TsysUser> result=new TableSplitResult<TsysUser>(page.getPageNum(), page.getTotal(), page.getList()); 
 		return  result;
 	}

+ 0 - 96
web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/auto/EarlywarningmainMapper.java.1

@@ -1,96 +0,0 @@
-package com.gyee.frame.mapper.auto;
-
-import com.gyee.frame.model.auto.Earlywarningmain;
-import com.gyee.frame.model.auto.EarlywarningmainExample;
-import java.util.List;
-import org.apache.ibatis.annotations.Param;
-
-public interface EarlywarningmainMapper {
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    long countByExample(EarlywarningmainExample example);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    int deleteByExample(EarlywarningmainExample example);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    int deleteByPrimaryKey(Short id);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    int insert(Earlywarningmain record);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    int insertSelective(Earlywarningmain record);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    List<Earlywarningmain> selectByExample(EarlywarningmainExample example);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    Earlywarningmain selectByPrimaryKey(Short id);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    int updateByExampleSelective(@Param("record") Earlywarningmain record, @Param("example") EarlywarningmainExample example);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    int updateByExample(@Param("record") Earlywarningmain record, @Param("example") EarlywarningmainExample example);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    int updateByPrimaryKeySelective(Earlywarningmain record);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table FAILURESTATISTICSMAIN
-     *
-     * @mbg.generated
-     */
-    int updateByPrimaryKey(Earlywarningmain record);
-}

+ 0 - 96
web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/auto/EarlywarningmainMapper.java.2

@@ -1,96 +0,0 @@
-package com.gyee.frame.mapper.auto;
-
-import com.gyee.frame.model.auto.Earlywarningmain;
-import com.gyee.frame.model.auto.EarlywarningmainExample;
-import java.util.List;
-import org.apache.ibatis.annotations.Param;
-
-public interface EarlywarningmainMapper {
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    long countByExample(EarlywarningmainExample example);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    int deleteByExample(EarlywarningmainExample example);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    int deleteByPrimaryKey(Short id);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    int insert(Earlywarningmain record);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    int insertSelective(Earlywarningmain record);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    List<Earlywarningmain> selectByExample(EarlywarningmainExample example);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    Earlywarningmain selectByPrimaryKey(Short id);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    int updateByExampleSelective(@Param("record") Earlywarningmain record, @Param("example") EarlywarningmainExample example);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    int updateByExample(@Param("record") Earlywarningmain record, @Param("example") EarlywarningmainExample example);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    int updateByPrimaryKeySelective(Earlywarningmain record);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table EARLYWARNINGMAIN
-     *
-     * @mbg.generated
-     */
-    int updateByPrimaryKey(Earlywarningmain record);
-}

+ 32 - 0
web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/auto/SysCompanyMapper.java

@@ -0,0 +1,32 @@
+package com.gyee.frame.mapper.auto;
+
+import com.gyee.frame.model.auto.SysCompany;
+import com.gyee.frame.model.auto.SysCompanyExample;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+public interface SysCompanyMapper {
+    
+    long countByExample(SysCompanyExample example);
+
+    int deleteByExample(SysCompanyExample example);
+
+    int deleteByPrimaryKey(Integer id);
+
+    int insert(SysCompany record);
+
+    int insertSelective(SysCompany record);
+
+    List<SysCompany> selectByExample(SysCompanyExample example);
+
+    SysCompany selectByPrimaryKey(String id);
+
+    int updateByExampleSelective(@Param("record") SysCompany record, @Param("example") SysCompanyExample example);
+
+    int updateByExample(@Param("record") SysCompany record, @Param("example") SysCompanyExample example);
+
+    int updateByPrimaryKeySelective(SysCompany record);
+
+    int updateByPrimaryKey(SysCompany record);
+}

+ 3 - 2
web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/auto/SysDepartmentMapper.java

@@ -2,9 +2,10 @@ package com.gyee.frame.mapper.auto;
 
 import com.gyee.frame.model.auto.SysDepartment;
 import com.gyee.frame.model.auto.SysDepartmentExample;
-import java.util.List;
 import org.apache.ibatis.annotations.Param;
 
+import java.util.List;
+
 /**
  * 部门表 SysDepartmentMapper
  * @author fuce_自动生成
@@ -25,7 +26,7 @@ public interface SysDepartmentMapper {
 
     List<SysDepartment> selectByExample(SysDepartmentExample example);
 		
-    SysDepartment selectByPrimaryKey(Integer id);
+    SysDepartment selectByPrimaryKey(String id);
 		
     int updateByExampleSelective(@Param("record") SysDepartment record, @Param("example") SysDepartmentExample example);
 

+ 2 - 1
web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/auto/TsysUserMapper.java

@@ -2,9 +2,10 @@ package com.gyee.frame.mapper.auto;
 
 import com.gyee.frame.model.auto.TsysUser;
 import com.gyee.frame.model.auto.TsysUserExample;
-import java.util.List;
 import org.apache.ibatis.annotations.Param;
 
+import java.util.List;
+
 public interface TsysUserMapper {
     long countByExample(TsysUserExample example);
 

+ 2 - 1
web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/custom/TsysUserDao.java

@@ -1,8 +1,9 @@
 package com.gyee.frame.mapper.custom;
 
-import java.util.List;
 import com.gyee.frame.model.auto.TsysUser;
 
+import java.util.List;
+
 /**
  * @ClassName: TsysUserDao
  * @author gyee

+ 121 - 0
web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/SysCompany.java

@@ -0,0 +1,121 @@
+package com.gyee.frame.model.auto;
+
+import java.io.Serializable;
+
+public class SysCompany implements Serializable {
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column T_SYS_COMPANY.ID
+     *
+     * @mbg.generated
+     */
+    private String id;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column T_SYS_COMPANY.PARENT_ID
+     *
+     * @mbg.generated
+     */
+    private String parentId;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column T_SYS_COMPANY.COMPANY_NAME
+     *
+     * @mbg.generated
+     */
+    private String companyName;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column T_SYS_COMPANY.STATUS
+     *
+     * @mbg.generated
+     */
+    private Integer status;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column T_SYS_COMPANY.ORDER_NUM
+     *
+     * @mbg.generated
+     */
+    private Integer orderNum;
+    private Integer childCount;
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    private static final long serialVersionUID = 1L;
+
+
+    public String getId() {
+        return id;
+    }
+
+    public void setId(String id) {
+        this.id = id;
+    }
+
+    public String getParentId() {
+        return parentId;
+    }
+
+    public void setParentId(String parentId) {
+        this.parentId = parentId;
+    }
+
+    public String getCompanyName() {
+        return companyName;
+    }
+
+    public void setCompanyName(String companyName) {
+        this.companyName = companyName;
+    }
+
+    public Integer getStatus() {
+        return status;
+    }
+
+    public void setStatus(Integer status) {
+        this.status = status;
+    }
+
+    public Integer getOrderNum() {
+        return orderNum;
+    }
+
+    public void setOrderNum(Integer orderNum) {
+        this.orderNum = orderNum;
+    }
+
+    public Integer getChildCount() {
+        return childCount;
+    }
+
+    public void setChildCount(Integer childCount) {
+        this.childCount = childCount;
+    }
+
+    public SysCompany() {
+        super();
+    }
+    public SysCompany(String id, String parentId, String companyName,
+                         Integer status, Integer orderNum, Integer childCount) {
+        this.id = id;
+        this.parentId = parentId;
+        this.companyName = companyName;
+        this.status = status;
+        this.orderNum = orderNum;
+        this.childCount = childCount;
+
+    }
+}

+ 602 - 0
web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/SysCompanyExample.java

@@ -0,0 +1,602 @@
+package com.gyee.frame.model.auto;
+
+import java.util.ArrayList;
+import java.util.List;
+
+public class SysCompanyExample {
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    protected String orderByClause;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    protected boolean distinct;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    protected List<Criteria> oredCriteria;
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public SysCompanyExample() {
+        oredCriteria = new ArrayList<Criteria>();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public void setOrderByClause(String orderByClause) {
+        this.orderByClause = orderByClause;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public String getOrderByClause() {
+        return orderByClause;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public void setDistinct(boolean distinct) {
+        this.distinct = distinct;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public boolean isDistinct() {
+        return distinct;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public List<Criteria> getOredCriteria() {
+        return oredCriteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public void or(Criteria criteria) {
+        oredCriteria.add(criteria);
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public Criteria or() {
+        Criteria criteria = createCriteriaInternal();
+        oredCriteria.add(criteria);
+        return criteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public Criteria createCriteria() {
+        Criteria criteria = createCriteriaInternal();
+        if (oredCriteria.size() == 0) {
+            oredCriteria.add(criteria);
+        }
+        return criteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    protected Criteria createCriteriaInternal() {
+        Criteria criteria = new Criteria();
+        return criteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public void clear() {
+        oredCriteria.clear();
+        orderByClause = null;
+        distinct = false;
+    }
+
+    /**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    protected abstract static class GeneratedCriteria {
+        protected List<Criterion> criteria;
+
+        protected GeneratedCriteria() {
+            super();
+            criteria = new ArrayList<Criterion>();
+        }
+
+        public boolean isValid() {
+            return criteria.size() > 0;
+        }
+
+        public List<Criterion> getAllCriteria() {
+            return criteria;
+        }
+
+        public List<Criterion> getCriteria() {
+            return criteria;
+        }
+
+        protected void addCriterion(String condition) {
+            if (condition == null) {
+                throw new RuntimeException("Value for condition cannot be null");
+            }
+            criteria.add(new Criterion(condition));
+        }
+
+        protected void addCriterion(String condition, Object value, String property) {
+            if (value == null) {
+                throw new RuntimeException("Value for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value));
+        }
+
+        protected void addCriterion(String condition, Object value1, Object value2, String property) {
+            if (value1 == null || value2 == null) {
+                throw new RuntimeException("Between values for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value1, value2));
+        }
+
+        public Criteria andIdIsNull() {
+            addCriterion("ID is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIsNotNull() {
+            addCriterion("ID is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdEqualTo(String value) {
+            addCriterion("ID =", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotEqualTo(String value) {
+            addCriterion("ID <>", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThan(String value) {
+            addCriterion("ID >", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThanOrEqualTo(String value) {
+            addCriterion("ID >=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThan(String value) {
+            addCriterion("ID <", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThanOrEqualTo(String value) {
+            addCriterion("ID <=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIn(List<String> values) {
+            addCriterion("ID in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotIn(List<String> values) {
+            addCriterion("ID not in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdBetween(String value1, String value2) {
+            addCriterion("ID between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotBetween(String value1, String value2) {
+            addCriterion("ID not between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdIsNull() {
+            addCriterion("PARENT_ID is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdIsNotNull() {
+            addCriterion("PARENT_ID is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdEqualTo(Object value) {
+            addCriterion("PARENT_ID =", value, "parentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdNotEqualTo(Object value) {
+            addCriterion("PARENT_ID <>", value, "parentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdGreaterThan(Object value) {
+            addCriterion("PARENT_ID >", value, "parentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdGreaterThanOrEqualTo(Object value) {
+            addCriterion("PARENT_ID >=", value, "parentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdLessThan(Object value) {
+            addCriterion("PARENT_ID <", value, "parentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdLessThanOrEqualTo(Object value) {
+            addCriterion("PARENT_ID <=", value, "parentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdIn(List<Object> values) {
+            addCriterion("PARENT_ID in", values, "parentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdNotIn(List<Object> values) {
+            addCriterion("PARENT_ID not in", values, "parentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdBetween(Object value1, Object value2) {
+            addCriterion("PARENT_ID between", value1, value2, "parentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andParentIdNotBetween(Object value1, Object value2) {
+            addCriterion("PARENT_ID not between", value1, value2, "parentId");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameIsNull() {
+            addCriterion("COMPANY_NAME is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameIsNotNull() {
+            addCriterion("COMPANY_NAME is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameEqualTo(Object value) {
+            addCriterion("COMPANY_NAME =", value, "companyName");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameNotEqualTo(Object value) {
+            addCriterion("COMPANY_NAME <>", value, "companyName");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameGreaterThan(Object value) {
+            addCriterion("COMPANY_NAME >", value, "companyName");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameGreaterThanOrEqualTo(Object value) {
+            addCriterion("COMPANY_NAME >=", value, "companyName");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameLessThan(Object value) {
+            addCriterion("COMPANY_NAME <", value, "companyName");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameLessThanOrEqualTo(Object value) {
+            addCriterion("COMPANY_NAME <=", value, "companyName");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameIn(List<Object> values) {
+            addCriterion("COMPANY_NAME in", values, "companyName");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameNotIn(List<Object> values) {
+            addCriterion("COMPANY_NAME not in", values, "companyName");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameBetween(Object value1, Object value2) {
+            addCriterion("COMPANY_NAME between", value1, value2, "companyName");
+            return (Criteria) this;
+        }
+
+        public Criteria andCompanyNameNotBetween(Object value1, Object value2) {
+            addCriterion("COMPANY_NAME not between", value1, value2, "companyName");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusIsNull() {
+            addCriterion("STATUS is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusIsNotNull() {
+            addCriterion("STATUS is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusEqualTo(Integer value) {
+            addCriterion("STATUS =", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusNotEqualTo(Integer value) {
+            addCriterion("STATUS <>", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusGreaterThan(Integer value) {
+            addCriterion("STATUS >", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusGreaterThanOrEqualTo(Integer value) {
+            addCriterion("STATUS >=", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusLessThan(Integer value) {
+            addCriterion("STATUS <", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusLessThanOrEqualTo(Integer value) {
+            addCriterion("STATUS <=", value, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusIn(List<Integer> values) {
+            addCriterion("STATUS in", values, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusNotIn(List<Integer> values) {
+            addCriterion("STATUS not in", values, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusBetween(Integer value1, Integer value2) {
+            addCriterion("STATUS between", value1, value2, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andStatusNotBetween(Integer value1, Integer value2) {
+            addCriterion("STATUS not between", value1, value2, "status");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumIsNull() {
+            addCriterion("ORDER_NUM is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumIsNotNull() {
+            addCriterion("ORDER_NUM is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumEqualTo(Integer value) {
+            addCriterion("ORDER_NUM =", value, "orderNum");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumNotEqualTo(Integer value) {
+            addCriterion("ORDER_NUM <>", value, "orderNum");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumGreaterThan(Integer value) {
+            addCriterion("ORDER_NUM >", value, "orderNum");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumGreaterThanOrEqualTo(Integer value) {
+            addCriterion("ORDER_NUM >=", value, "orderNum");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumLessThan(Integer value) {
+            addCriterion("ORDER_NUM <", value, "orderNum");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumLessThanOrEqualTo(Integer value) {
+            addCriterion("ORDER_NUM <=", value, "orderNum");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumIn(List<Integer> values) {
+            addCriterion("ORDER_NUM in", values, "orderNum");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumNotIn(List<Integer> values) {
+            addCriterion("ORDER_NUM not in", values, "orderNum");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumBetween(Integer value1, Integer value2) {
+            addCriterion("ORDER_NUM between", value1, value2, "orderNum");
+            return (Criteria) this;
+        }
+
+        public Criteria andOrderNumNotBetween(Integer value1, Integer value2) {
+            addCriterion("ORDER_NUM not between", value1, value2, "orderNum");
+            return (Criteria) this;
+        }
+    }
+
+    /**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated do_not_delete_during_merge
+     */
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+
+    /**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table T_SYS_COMPANY
+     *
+     * @mbg.generated
+     */
+    public static class Criterion {
+        private String condition;
+
+        private Object value;
+
+        private Object secondValue;
+
+        private boolean noValue;
+
+        private boolean singleValue;
+
+        private boolean betweenValue;
+
+        private boolean listValue;
+
+        private String typeHandler;
+
+        public String getCondition() {
+            return condition;
+        }
+
+        public Object getValue() {
+            return value;
+        }
+
+        public Object getSecondValue() {
+            return secondValue;
+        }
+
+        public boolean isNoValue() {
+            return noValue;
+        }
+
+        public boolean isSingleValue() {
+            return singleValue;
+        }
+
+        public boolean isBetweenValue() {
+            return betweenValue;
+        }
+
+        public boolean isListValue() {
+            return listValue;
+        }
+
+        public String getTypeHandler() {
+            return typeHandler;
+        }
+
+        protected Criterion(String condition) {
+            super();
+            this.condition = condition;
+            this.typeHandler = null;
+            this.noValue = true;
+        }
+
+        protected Criterion(String condition, Object value, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.typeHandler = typeHandler;
+            if (value instanceof List<?>) {
+                this.listValue = true;
+            } else {
+                this.singleValue = true;
+            }
+        }
+
+        protected Criterion(String condition, Object value) {
+            this(condition, value, null);
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.secondValue = secondValue;
+            this.typeHandler = typeHandler;
+            this.betweenValue = true;
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue) {
+            this(condition, value, secondValue, null);
+        }
+    }
+}

+ 5 - 6
web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/SysDepartment.java

@@ -1,10 +1,9 @@
 package com.gyee.frame.model.auto;
 
-import java.io.Serializable;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 
-import java.lang.Integer;
+import java.io.Serializable;
 
 /**
  * 部门表 SysDepartment
@@ -20,7 +19,7 @@ public class SysDepartment implements Serializable {
 
 	/** id **/
 	@ApiModelProperty(value = "id")
-	private Integer id;
+	private String id;
 
 	/** 父id **/
 	@ApiModelProperty(value = "父id")
@@ -52,11 +51,11 @@ public class SysDepartment implements Serializable {
 
 	private Integer childCount;
 
-	public Integer getId() {
+	public String getId() {
 		return id;
 	}
 
-	public void setId(Integer id) {
+	public void setId(String id) {
 		this.id = id;
 	}
 
@@ -128,7 +127,7 @@ public class SysDepartment implements Serializable {
 		super();
 	}
 
-	public SysDepartment(Integer id, String parentId, String deptName, String leader, String phone, String email,
+	public SysDepartment(String id, String parentId, String deptName, String leader, String phone, String email,
 			Integer status, Integer orderNum, Integer childCount) {
 		this.id = id;
 		this.parentId = parentId;

+ 12 - 12
web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/SysDepartmentExample.java

@@ -121,62 +121,62 @@ public class SysDepartmentExample {
             return (Criteria) this;
         }
 
-        public Criteria andIdEqualTo(Integer value) {
+        public Criteria andIdEqualTo(String value) {
             addCriterion("id =", value, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdNotEqualTo(Integer value) {
+        public Criteria andIdNotEqualTo(String value) {
             addCriterion("id <>", value, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdGreaterThan(Integer value) {
+        public Criteria andIdGreaterThan(String value) {
             addCriterion("id >", value, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdGreaterThanOrEqualTo(Integer value) {
+        public Criteria andIdGreaterThanOrEqualTo(String value) {
             addCriterion("id >=", value, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdLessThan(Integer value) {
+        public Criteria andIdLessThan(String value) {
             addCriterion("id <", value, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdLessThanOrEqualTo(Integer value) {
+        public Criteria andIdLessThanOrEqualTo(String value) {
             addCriterion("id <=", value, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdLike(Integer value) {
+        public Criteria andIdLike(String value) {
             addCriterion("id like", value, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdNotLike(Integer value) {
+        public Criteria andIdNotLike(String value) {
             addCriterion("id not like", value, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdIn(List<Integer> values) {
+        public Criteria andIdIn(List<String> values) {
             addCriterion("id in", values, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdNotIn(List<Integer> values) {
+        public Criteria andIdNotIn(List<String> values) {
             addCriterion("id not in", values, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdBetween(Integer value1, Integer value2) {
+        public Criteria andIdBetween(String value1, String value2) {
             addCriterion("id between", value1, value2, "id");
             return (Criteria) this;
         }
 
-        public Criteria andIdNotBetween(Integer value1, Integer value2) {
+        public Criteria andIdNotBetween(String value1, String value2) {
             addCriterion("id not between", value1, value2, "id");
             return (Criteria) this;
         }

+ 33 - 16
web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/TsysUser.java

@@ -1,9 +1,9 @@
 package com.gyee.frame.model.auto;
 
-import java.io.Serializable;
-
 import io.swagger.annotations.ApiModelProperty;
 
+import java.io.Serializable;
+
 public class TsysUser implements Serializable {
 	
 	private static final long serialVersionUID = 1L;
@@ -26,20 +26,22 @@ public class TsysUser implements Serializable {
 		
 	/** 部门id **/
 	@ApiModelProperty(value = "部门id")
-	private Integer depId;
+	private String depId;
 		
 	/** 岗位id **/
 	@ApiModelProperty(value = "岗位id")
 	private String posId;
-	
-	/**部门名称**/
-	private String depName;
-	/**岗位名称**/
-	private String posName;
-
-	
-
-    public TsysUser(String id, String username, String password, String nickname, Integer depId, String posId) {
+    /** 公司id **/
+    @ApiModelProperty(value = "公司id")
+    private String comId;
+    /**公司名称**/
+    private String comName;
+    /**部门名称**/
+    private String depName;
+    /**岗位名称**/
+    private String posName;
+
+    public TsysUser(String id, String username, String password, String nickname, String depId, String posId, String comId) {
 		super();
 		this.id = id;
 		this.username = username;
@@ -47,6 +49,7 @@ public class TsysUser implements Serializable {
 		this.nickname = nickname;
 		this.depId = depId;
 		this.posId = posId;
+        this.comId = comId;
 	}
 
 	public TsysUser() {
@@ -84,11 +87,11 @@ public class TsysUser implements Serializable {
     public void setNickname(String nickname) {
         this.nickname = nickname == null ? null : nickname.trim();
     }
-	public Integer getDepId() {
+	public String getDepId() {
         return depId;
     }
 
-    public void setDepId(Integer depId) {
+    public void setDepId(String depId) {
         this.depId = depId;
     }
 	 
@@ -116,6 +119,20 @@ public class TsysUser implements Serializable {
 	public void setPosName(String posName) {
 		this.posName = posName;
 	}
-    
-    
+
+    public String getComId() {
+        return comId;
+    }
+
+    public void setComId(String comId) {
+        this.comId = comId;
+    }
+
+    public String getComName() {
+        return comName;
+    }
+
+    public void setComName(String comName) {
+        this.comName = comName;
+    }
 }

+ 71 - 10
web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/TsysUserExample.java

@@ -394,52 +394,52 @@ public class TsysUserExample {
             return (Criteria) this;
         }
 
-        public Criteria andDepIdEqualTo(Integer value) {
+        public Criteria andDepIdEqualTo(String value) {
             addCriterion("dep_id =", value, "depId");
             return (Criteria) this;
         }
 
-        public Criteria andDepIdNotEqualTo(Integer value) {
+        public Criteria andDepIdNotEqualTo(String value) {
             addCriterion("dep_id <>", value, "depId");
             return (Criteria) this;
         }
 
-        public Criteria andDepIdGreaterThan(Integer value) {
+        public Criteria andDepIdGreaterThan(String value) {
             addCriterion("dep_id >", value, "depId");
             return (Criteria) this;
         }
 
-        public Criteria andDepIdGreaterThanOrEqualTo(Integer value) {
+        public Criteria andDepIdGreaterThanOrEqualTo(String value) {
             addCriterion("dep_id >=", value, "depId");
             return (Criteria) this;
         }
 
-        public Criteria andDepIdLessThan(Integer value) {
+        public Criteria andDepIdLessThan(String value) {
             addCriterion("dep_id <", value, "depId");
             return (Criteria) this;
         }
 
-        public Criteria andDepIdLessThanOrEqualTo(Integer value) {
+        public Criteria andDepIdLessThanOrEqualTo(String value) {
             addCriterion("dep_id <=", value, "depId");
             return (Criteria) this;
         }
 
-        public Criteria andDepIdIn(List<Integer> values) {
+        public Criteria andDepIdIn(List<String> values) {
             addCriterion("dep_id in", values, "depId");
             return (Criteria) this;
         }
 
-        public Criteria andDepIdNotIn(List<Integer> values) {
+        public Criteria andDepIdNotIn(List<String> values) {
             addCriterion("dep_id not in", values, "depId");
             return (Criteria) this;
         }
 
-        public Criteria andDepIdBetween(Integer value1, Integer value2) {
+        public Criteria andDepIdBetween(String value1, String value2) {
             addCriterion("dep_id between", value1, value2, "depId");
             return (Criteria) this;
         }
 
-        public Criteria andDepIdNotBetween(Integer value1, Integer value2) {
+        public Criteria andDepIdNotBetween(String value1, String value2) {
             addCriterion("dep_id not between", value1, value2, "depId");
             return (Criteria) this;
         }
@@ -513,6 +513,67 @@ public class TsysUserExample {
             addCriterion("pos_id not between", value1, value2, "posId");
             return (Criteria) this;
         }
+
+
+        public Criteria andComIdIsNull() {
+            addCriterion("com_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdIsNotNull() {
+            addCriterion("com_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdEqualTo(String value) {
+            addCriterion("com_id =", value, "comId");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdNotEqualTo(String value) {
+            addCriterion("com_id <>", value, "comId");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdGreaterThan(String value) {
+            addCriterion("com_id >", value, "comId");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdGreaterThanOrEqualTo(String value) {
+            addCriterion("com_id >=", value, "comId");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdLessThan(String value) {
+            addCriterion("com_id <", value, "comId");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdLessThanOrEqualTo(String value) {
+            addCriterion("com_id <=", value, "comId");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdIn(List<String> values) {
+            addCriterion("com_id in", values, "comId");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdNotIn(List<String> values) {
+            addCriterion("com_id not in", values, "comId");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdBetween(String value1, String value2) {
+            addCriterion("com_id between", value1, value2, "comId");
+            return (Criteria) this;
+        }
+
+        public Criteria andComIdNotBetween(String value1, String value2) {
+            addCriterion("com_id not between", value1, value2, "comId");
+            return (Criteria) this;
+        }
     }
 
     public static class Criteria extends GeneratedCriteria {

+ 37 - 3
web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/TvueUser.java

@@ -1,5 +1,7 @@
 package com.gyee.frame.model.auto;
 
+import io.swagger.annotations.ApiModelProperty;
+
 import java.io.Serializable;
 
 public class TvueUser implements Serializable {
@@ -46,7 +48,7 @@ public class TvueUser implements Serializable {
      *
      * @mbg.generated
      */
-    private Long depId;
+    private String depId;
 
     /**
      *
@@ -60,7 +62,26 @@ public class TvueUser implements Serializable {
     private String depName;
     /**岗位名称**/
     private String posName;
+    @ApiModelProperty(value = "公司id")
+    private String comId;
+    /**公司名称**/
+    private String comName;
+
+    public String getComId() {
+        return comId;
+    }
+
+    public void setComId(String comId) {
+        this.comId = comId;
+    }
+
+    public String getComName() {
+        return comName;
+    }
 
+    public void setComName(String comName) {
+        this.comName = comName;
+    }
 
     /**
      * This field was generated by MyBatis Generator.
@@ -174,7 +195,7 @@ public class TvueUser implements Serializable {
      *
      * @mbg.generated
      */
-    public Long getDepId() {
+    public String getDepId() {
         return depId;
     }
 
@@ -186,7 +207,7 @@ public class TvueUser implements Serializable {
      *
      * @mbg.generated
      */
-    public void setDepId(Long depId) {
+    public void setDepId(String depId) {
         this.depId = depId;
     }
 
@@ -230,4 +251,17 @@ public class TvueUser implements Serializable {
     public void setPosName(String posName) {
         this.posName = posName;
     }
+    public TvueUser() {
+
+    }
+    public TvueUser(String id, String username, String password, String nickname, String depId, String posId, String comId) {
+        super();
+        this.id = id;
+        this.username = username;
+        this.password = password;
+        this.nickname = nickname;
+        this.depId = depId;
+        this.posId = posId;
+        this.comId = comId;
+    }
 }

+ 124 - 62
web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/auto/TvueUserExample.java

@@ -474,134 +474,196 @@ public class TvueUserExample {
             return (Criteria) this;
         }
 
+
         public Criteria andDepIdIsNull() {
-            addCriterion("DEP_ID is null");
-            return (Criteria) this;
+            addCriterion("dep_id is null");
+               return (Criteria) this;
         }
 
         public Criteria andDepIdIsNotNull() {
-            addCriterion("DEP_ID is not null");
-            return (Criteria) this;
+            addCriterion("dep_id is not null");
+               return (Criteria) this;
         }
 
-        public Criteria andDepIdEqualTo(Long value) {
-            addCriterion("DEP_ID =", value, "depId");
-            return (Criteria) this;
+        public Criteria andDepIdEqualTo(String value) {
+            addCriterion("dep_id =", value, "depId");
+               return (Criteria) this;
         }
 
-        public Criteria andDepIdNotEqualTo(Long value) {
-            addCriterion("DEP_ID <>", value, "depId");
-            return (Criteria) this;
+        public Criteria andDepIdNotEqualTo(String value) {
+            addCriterion("dep_id <>", value, "depId");
+               return (Criteria) this;
         }
 
-        public Criteria andDepIdGreaterThan(Long value) {
-            addCriterion("DEP_ID >", value, "depId");
-            return (Criteria) this;
+        public Criteria andDepIdGreaterThan(String value) {
+            addCriterion("dep_id >", value, "depId");
+               return (Criteria) this;
         }
 
-        public Criteria andDepIdGreaterThanOrEqualTo(Long value) {
-            addCriterion("DEP_ID >=", value, "depId");
-            return (Criteria) this;
+        public Criteria andDepIdGreaterThanOrEqualTo(String value) {
+            addCriterion("dep_id >=", value, "depId");
+               return (Criteria) this;
         }
 
-        public Criteria andDepIdLessThan(Long value) {
-            addCriterion("DEP_ID <", value, "depId");
-            return (Criteria) this;
+        public Criteria andDepIdLessThan(String value) {
+            addCriterion("dep_id <", value, "depId");
+               return (Criteria) this;
         }
 
-        public Criteria andDepIdLessThanOrEqualTo(Long value) {
-            addCriterion("DEP_ID <=", value, "depId");
-            return (Criteria) this;
+        public Criteria andDepIdLessThanOrEqualTo(String value) {
+            addCriterion("dep_id <=", value, "depId");
+               return (Criteria) this;
         }
 
-        public Criteria andDepIdIn(List<Long> values) {
-            addCriterion("DEP_ID in", values, "depId");
-            return (Criteria) this;
+        public Criteria andDepIdIn(List<String> values) {
+            addCriterion("dep_id in", values, "depId");
+               return (Criteria) this;
         }
 
-        public Criteria andDepIdNotIn(List<Long> values) {
-            addCriterion("DEP_ID not in", values, "depId");
-            return (Criteria) this;
+        public Criteria andDepIdNotIn(List<String> values) {
+            addCriterion("dep_id not in", values, "depId");
+               return (Criteria) this;
         }
 
-        public Criteria andDepIdBetween(Long value1, Long value2) {
-            addCriterion("DEP_ID between", value1, value2, "depId");
-            return (Criteria) this;
+        public Criteria andDepIdBetween(String value1, String value2) {
+            addCriterion("dep_id between", value1, value2, "depId");
+               return (Criteria) this;
         }
 
-        public Criteria andDepIdNotBetween(Long value1, Long value2) {
-            addCriterion("DEP_ID not between", value1, value2, "depId");
-            return (Criteria) this;
+        public Criteria andDepIdNotBetween(String value1, String value2) {
+            addCriterion("dep_id not between", value1, value2, "depId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdIsNull() {
-            addCriterion("POS_ID is null");
-            return (Criteria) this;
+            addCriterion("pos_id is null");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdIsNotNull() {
-            addCriterion("POS_ID is not null");
-            return (Criteria) this;
+            addCriterion("pos_id is not null");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdEqualTo(String value) {
-            addCriterion("POS_ID =", value, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id =", value, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdNotEqualTo(String value) {
-            addCriterion("POS_ID <>", value, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id <>", value, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdGreaterThan(String value) {
-            addCriterion("POS_ID >", value, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id >", value, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdGreaterThanOrEqualTo(String value) {
-            addCriterion("POS_ID >=", value, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id >=", value, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdLessThan(String value) {
-            addCriterion("POS_ID <", value, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id <", value, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdLessThanOrEqualTo(String value) {
-            addCriterion("POS_ID <=", value, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id <=", value, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdLike(String value) {
-            addCriterion("POS_ID like", value, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id like", value, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdNotLike(String value) {
-            addCriterion("POS_ID not like", value, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id not like", value, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdIn(List<String> values) {
-            addCriterion("POS_ID in", values, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id in", values, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdNotIn(List<String> values) {
-            addCriterion("POS_ID not in", values, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id not in", values, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdBetween(String value1, String value2) {
-            addCriterion("POS_ID between", value1, value2, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id between", value1, value2, "posId");
+               return (Criteria) this;
         }
 
         public Criteria andPosIdNotBetween(String value1, String value2) {
-            addCriterion("POS_ID not between", value1, value2, "posId");
-            return (Criteria) this;
+            addCriterion("pos_id not between", value1, value2, "posId");
+               return (Criteria) this;
+        }
+
+
+        public Criteria andComIdIsNull() {
+            addCriterion("com_id is null");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdIsNotNull() {
+            addCriterion("com_id is not null");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdEqualTo(String value) {
+            addCriterion("com_id =", value, "comId");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdNotEqualTo(String value) {
+            addCriterion("com_id <>", value, "comId");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdGreaterThan(String value) {
+            addCriterion("com_id >", value, "comId");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdGreaterThanOrEqualTo(String value) {
+            addCriterion("com_id >=", value, "comId");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdLessThan(String value) {
+            addCriterion("com_id <", value, "comId");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdLessThanOrEqualTo(String value) {
+            addCriterion("com_id <=", value, "comId");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdIn(List<String> values) {
+            addCriterion("com_id in", values, "comId");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdNotIn(List<String> values) {
+            addCriterion("com_id not in", values, "comId");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdBetween(String value1, String value2) {
+            addCriterion("com_id between", value1, value2, "comId");
+               return (Criteria) this;
+        }
+
+        public Criteria andComIdNotBetween(String value1, String value2) {
+            addCriterion("com_id not between", value1, value2, "comId");
+               return (Criteria) this;
         }
     }
 

+ 192 - 0
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/SysCompanyService.java

@@ -0,0 +1,192 @@
+package com.gyee.frame.service;
+
+import cn.hutool.core.util.StrUtil;
+import com.github.pagehelper.PageHelper;
+import com.github.pagehelper.PageInfo;
+import com.gyee.frame.common.base.BaseService;
+import com.gyee.frame.common.support.ConvertUtil;
+import com.gyee.frame.mapper.auto.SysCompanyMapper;
+import com.gyee.frame.model.auto.SysCompany;
+import com.gyee.frame.model.auto.SysCompanyExample;
+import com.gyee.frame.model.custom.BootstrapTree;
+import com.gyee.frame.model.custom.Tablepar;
+import com.gyee.frame.util.SnowflakeIdWorker;
+import com.gyee.frame.util.StringUtils;
+import org.springframework.stereotype.Service;
+
+import javax.annotation.Resource;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+/**
+ * 部门表 SysCompanyService
+ * 
+ * @Title: SysCompanyService.java 
+ * @Package com.gyee.frame.service 
+ * @author fuce_自动生成
+ * @email 115889198@qq.com
+ * @date 2020-04-17 13:12:58  
+ **/
+@Service
+public class SysCompanyService implements BaseService<SysCompany, SysCompanyExample> {
+	@Resource
+	private SysCompanyMapper sysCompanyMapper;
+
+
+	public PageInfo<SysCompany> list(Tablepar tablepar, String name) {
+		SysCompanyExample testExample = new SysCompanyExample();
+		testExample.setOrderByClause("id ASC");
+		if (name != null && !"".equals(name)) {
+			testExample.createCriteria().andCompanyNameEqualTo("%" + name + "%");
+		}
+		if (StrUtil.isNotEmpty(tablepar.getOrderByColumn())) {
+			testExample.setOrderByClause(
+					StringUtils.toUnderScoreCase(tablepar.getOrderByColumn()) + " " + tablepar.getIsAsc());
+		}
+		PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize());
+		List<SysCompany> list = sysCompanyMapper.selectByExample(testExample);
+		PageInfo<SysCompany> pageInfo = new PageInfo<SysCompany>(list);
+		return pageInfo;
+	}
+
+	public List<SysCompany> list2(String searchText) {
+		SysCompanyExample testExample = new SysCompanyExample();
+		testExample.setOrderByClause("order_num   ASC,order_num  ASC");
+		if (searchText != null && !"".equals(searchText)) {
+			testExample.createCriteria().andCompanyNameEqualTo("%" + searchText + "%");
+		}
+		List<SysCompany> list = sysCompanyMapper.selectByExample(testExample);
+		return list;
+	}
+
+	@Override
+	public int deleteByPrimaryKey(String ids) {
+
+        String[] integers = ConvertUtil.toStrArray(",", ids);
+		List<String> stringB = Arrays.asList(integers);
+		SysCompanyExample example = new SysCompanyExample();
+		example.createCriteria().andIdIn(stringB);
+		return sysCompanyMapper.deleteByExample(example);
+
+	}
+
+	@Override
+	public SysCompany selectByPrimaryKey(String id) {
+
+
+		return sysCompanyMapper.selectByPrimaryKey(id);
+
+	}
+
+	@Override
+	public int updateByPrimaryKeySelective(SysCompany record) {
+		return sysCompanyMapper.updateByPrimaryKeySelective(record);
+	}
+
+	/**
+	 * 添加
+	 */
+	@Override
+	public int insertSelective(SysCompany record) {
+
+        record.setId(SnowflakeIdWorker.getUUID());
+
+		return sysCompanyMapper.insertSelective(record);
+	}
+
+	@Override
+	public int updateByExampleSelective(SysCompany record, SysCompanyExample example) {
+
+		return sysCompanyMapper.updateByExampleSelective(record, example);
+	}
+
+	@Override
+	public int updateByExample(SysCompany record, SysCompanyExample example) {
+
+		return sysCompanyMapper.updateByExample(record, example);
+	}
+
+	@Override
+	public List<SysCompany> selectByExample(SysCompanyExample example) {
+
+		return sysCompanyMapper.selectByExample(example);
+	}
+
+	@Override
+	public long countByExample(SysCompanyExample example) {
+
+		return sysCompanyMapper.countByExample(example);
+	}
+
+	@Override
+	public int deleteByExample(SysCompanyExample example) {
+
+		return sysCompanyMapper.deleteByExample(example);
+	}
+
+	/**
+	 * 检查name
+	 * 
+	 * @param sysCompany
+	 * @return
+	 */
+	public int checkNameUnique(SysCompany sysCompany) {
+		SysCompanyExample example = new SysCompanyExample();
+		example.createCriteria().andCompanyNameEqualTo(sysCompany.getCompanyName());
+		List<SysCompany> list = sysCompanyMapper.selectByExample(example);
+		return list.size();
+	}
+	
+	
+	
+	/**
+	 * 获取树
+	 * @param menuList
+	 * @param parentId
+	 * @return
+	 */
+	private static List<BootstrapTree> getbooBootstrapTreePerm(List<SysCompany> menuList, String parentId){
+		List<BootstrapTree> treeList = new ArrayList<>();
+		List<BootstrapTree> childList = null;
+		for(SysCompany p : menuList) {
+			p.setParentId(p.getParentId()==null||p.getParentId().trim().equals("")? "0":p.getParentId());
+			if(p.getParentId().trim().equals(parentId)) {
+				if(p.getChildCount()!=null&&p.getChildCount()>0) {
+					childList = getbooBootstrapTreePerm(menuList, String.valueOf(p.getId()));
+				}
+				BootstrapTree bootstrapTree = new BootstrapTree(p.getCompanyName(), "", "", String.valueOf(p.getId()), "",0,childList,p.getCompanyName(),p.getStatus());
+				treeList.add(bootstrapTree);
+				childList = null;
+			}
+		}
+		return treeList.size() >0 ? treeList : null;
+	}
+	
+	/**
+	 * 获取转换成bootstarp的权限数据
+	 * @return
+	 */
+	public BootstrapTree getbooBootstrapTreePerm(){
+		List<BootstrapTree> treeList = new ArrayList<BootstrapTree>();
+		List<SysCompany> menuList =  getall();
+		treeList = getbooBootstrapTreePerm(menuList,"0");
+		if(treeList!=null&&treeList.size()==1) {
+			return treeList.get(0);
+		}
+		return new BootstrapTree("菜单", "fa fa-home", "", "0","###",0,treeList,"",0);
+	}
+	
+	
+	/**
+	 * 根据用户id获取用户角色如果用户为null 获取所有权限
+	 * @return
+	 */
+	public List<SysCompany> getall(){
+		SysCompanyExample example = new SysCompanyExample();
+		example.setOrderByClause("order_num asc");
+		return  sysCompanyMapper.selectByExample(example);
+		
+	}
+	
+}

+ 6 - 12
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/SysDepartmentService.java

@@ -10,6 +10,7 @@ import com.gyee.frame.model.auto.SysDepartment;
 import com.gyee.frame.model.auto.SysDepartmentExample;
 import com.gyee.frame.model.custom.BootstrapTree;
 import com.gyee.frame.model.custom.Tablepar;
+import com.gyee.frame.util.SnowflakeIdWorker;
 import com.gyee.frame.util.StringUtils;
 import org.springframework.stereotype.Service;
 
@@ -32,13 +33,7 @@ public class SysDepartmentService implements BaseService<SysDepartment, SysDepar
 	@Resource
 	private SysDepartmentMapper sysDepartmentMapper;
 
-	/**
-	 * 分页查询
-	 * 
-	 * @param pageNum
-	 * @param pageSize
-	 * @return
-	 */
+
 	public PageInfo<SysDepartment> list(Tablepar tablepar, String name) {
 		SysDepartmentExample testExample = new SysDepartmentExample();
 		testExample.setOrderByClause("id ASC");
@@ -68,8 +63,8 @@ public class SysDepartmentService implements BaseService<SysDepartment, SysDepar
 	@Override
 	public int deleteByPrimaryKey(String ids) {
 
-		Integer[] integers = ConvertUtil.toIntArray(",", ids);
-		List<Integer> stringB = Arrays.asList(integers);
+        String[] integers = ConvertUtil.toStrArray(",", ids);
+		List<String> stringB = Arrays.asList(integers);
 		SysDepartmentExample example = new SysDepartmentExample();
 		example.createCriteria().andIdIn(stringB);
 		return sysDepartmentMapper.deleteByExample(example);
@@ -79,8 +74,7 @@ public class SysDepartmentService implements BaseService<SysDepartment, SysDepar
 	@Override
 	public SysDepartment selectByPrimaryKey(String id) {
 
-		Integer id1 = Integer.valueOf(id);
-		return sysDepartmentMapper.selectByPrimaryKey(id1);
+		return sysDepartmentMapper.selectByPrimaryKey(id);
 
 	}
 
@@ -95,7 +89,7 @@ public class SysDepartmentService implements BaseService<SysDepartment, SysDepar
 	@Override
 	public int insertSelective(SysDepartment record) {
 
-		record.setId(null);
+        record.setId(SnowflakeIdWorker.getUUID());
 
 		return sysDepartmentMapper.insertSelective(record);
 	}

+ 8 - 13
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/SysNoticeService.java

@@ -1,28 +1,23 @@
 package com.gyee.frame.service;
 
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-import javax.annotation.Resource;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
-
 import com.github.pagehelper.PageHelper;
 import com.github.pagehelper.PageInfo;
 import com.gyee.frame.common.base.BaseService;
 import com.gyee.frame.common.support.ConvertUtil;
 import com.gyee.frame.mapper.auto.SysNoticeMapper;
 import com.gyee.frame.mapper.auto.SysNoticeUserMapper;
-import com.gyee.frame.model.auto.SysNotice;
-import com.gyee.frame.model.auto.SysNoticeExample;
-import com.gyee.frame.model.auto.SysNoticeUser;
-import com.gyee.frame.model.auto.SysNoticeUserExample;
+import com.gyee.frame.model.auto.*;
 import com.gyee.frame.model.auto.SysNoticeUserExample.Criteria;
-import com.gyee.frame.model.auto.TsysUser;
-import com.gyee.frame.model.auto.TsysUserExample;
 import com.gyee.frame.model.custom.Tablepar;
 import com.gyee.frame.shiro.util.ShiroUtils;
 import com.gyee.frame.util.SnowflakeIdWorker;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import javax.annotation.Resource;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
 
 /**
  * 公告 SysNoticeService

+ 10 - 15
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/SysUserService.java

@@ -1,10 +1,7 @@
 package com.gyee.frame.service;
 
-import java.util.ArrayList;
-import java.util.List;
-import javax.annotation.Resource;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Transactional;
+import com.github.pagehelper.PageHelper;
+import com.github.pagehelper.PageInfo;
 import com.gyee.frame.common.base.BaseService;
 import com.gyee.frame.common.support.ConvertUtil;
 import com.gyee.frame.mapper.auto.TSysRoleUserMapper;
@@ -12,19 +9,18 @@ import com.gyee.frame.mapper.auto.TsysRoleMapper;
 import com.gyee.frame.mapper.auto.TsysUserMapper;
 import com.gyee.frame.mapper.custom.RoleDao;
 import com.gyee.frame.mapper.custom.TsysUserDao;
-import com.gyee.frame.model.auto.TSysRoleUser;
-import com.gyee.frame.model.auto.TSysRoleUserExample;
-import com.gyee.frame.model.auto.TsysRole;
-import com.gyee.frame.model.auto.TsysRoleExample;
-import com.gyee.frame.model.auto.TsysUser;
-import com.gyee.frame.model.auto.TsysUserExample;
+import com.gyee.frame.model.auto.*;
 import com.gyee.frame.model.custom.RoleVo;
 import com.gyee.frame.model.custom.Tablepar;
 import com.gyee.frame.util.MD5Util;
 import com.gyee.frame.util.SnowflakeIdWorker;
 import com.gyee.frame.util.StringUtils;
-import com.github.pagehelper.PageHelper;
-import com.github.pagehelper.PageInfo;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import javax.annotation.Resource;
+import java.util.ArrayList;
+import java.util.List;
 
 /**
  * 系统用户
@@ -57,8 +53,7 @@ public class SysUserService implements BaseService<TsysUser, TsysUserExample>{
 	
 	/**
 	 * 分页查询
-	 * @param pageNum
-	 * @param pageSize
+
 	 * @return
 	 */
 	 public PageInfo<TsysUser> list(Tablepar tablepar,String username){

+ 2 - 3
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/WindPowerstationTestingPoint2Service.java

@@ -12,7 +12,6 @@ import com.gyee.frame.model.auto.Windpowerstationpointnew;
 import com.gyee.frame.model.auto.WindpowerstationpointnewExample;
 import com.gyee.frame.model.custom.SimpleVo;
 import com.gyee.frame.model.custom.Tablepar;
-import com.gyee.frame.util.SnowflakeIdWorker;
 import com.gyee.frame.util.StringUtils;
 import org.springframework.stereotype.Service;
 
@@ -87,8 +86,8 @@ public class WindPowerstationTestingPoint2Service implements BaseService<Windpow
 	@Override
 	public int insertSelective(Windpowerstationpointnew record) {
 				
-		//添加雪花主键id
-		record.setCode(SnowflakeIdWorker.getUUID());
+//		//添加雪花主键id
+//		record.setCode(SnowflakeIdWorker.getUUID());
 			
 				
 		return windpowerstationpointnewMapper.insertSelective(record);

+ 29 - 23
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/initialpoint/InitialPointEdosService.java

@@ -41,7 +41,7 @@ public class InitialPointEdosService implements  IinitialPoint{
     private final  String DI="DI";
     private final  String CI="CI";
     private final String CFT="CFT";
-
+    private final String HEAD="GDHF";
     @Override
     public void initalFc(boolean isGf) throws IOException {
 
@@ -117,12 +117,12 @@ public class InitialPointEdosService implements  IinitialPoint{
                             if(stp.getCode().equals(CI))
                             {
                                 sb =new StringBuilder();
-                                sb.append("SXJN.JSFW");
+                                 sb.append(HEAD).append(".JSFW");
                                 po.setRealtimeid(String.valueOf(sb));
                             }else
                             {
                                 sb =new StringBuilder();
-                                sb.append("SXJN.JSFWDD");
+                                 sb.append(HEAD).append(".JSFWDD");
                                 po.setRealtimeid(String.valueOf(sb));
                             }
 
@@ -178,12 +178,12 @@ public class InitialPointEdosService implements  IinitialPoint{
                             if(stp.getCode().equals(CI))
                             {
                                 sb =new StringBuilder();
-                                sb.append("SXJN.JSFW");
+                                 sb.append(HEAD).append(".JSFW");
                                 po.setRealtimeid(String.valueOf(sb));
                             }else
                             {
                                 sb =new StringBuilder();
-                                 sb.append("SXJN.JSFWDD");
+                                  sb.append(HEAD).append(".JSFWDD");
                                 po.setRealtimeid(String.valueOf(sb));
                             }
 
@@ -244,7 +244,7 @@ public class InitialPointEdosService implements  IinitialPoint{
 //                if(stp.getCode().equals(CI))
 //                {
 //                    sb =new StringBuilder();
-//                    sb.append("SXJN.JSFWFC");
+//                     sb.append(HEAD).append(".JSFWFC");
 //                    po.setRealtimeid(String.valueOf(sb));
 //                }
 //                points.add(po);
@@ -304,9 +304,15 @@ public class InitialPointEdosService implements  IinitialPoint{
                                 if(stp.getCode().equals(CI))
                                 {
                                     sb =new StringBuilder();
-                                    sb.append("SXJN.JSFWGC");
+                                     sb.append(HEAD).append(".JSFWGC");
+                                    po.setRealtimeid(String.valueOf(sb));
+                                }else
+                                {
+                                    sb =new StringBuilder();
+                                    sb.append(HEAD).append(".JSFWDD");
                                     po.setRealtimeid(String.valueOf(sb));
                                 }
+
                                 points.add(po);
                             }
             
@@ -407,10 +413,10 @@ public class InitialPointEdosService implements  IinitialPoint{
 
                 if(wp.getId().endsWith("FDC"))
                 {
-                    sb.append("SXJN.JSFW").append(temp).append("FC");
+                     sb.append(HEAD).append(".JSFW").append(temp).append("FC");
                 }else
                 {
-                    sb.append("SXJN.JSFW").append(temp).append("GC");
+                     sb.append(HEAD).append(".JSFW").append(temp).append("GC");
                 }
 
                 po.setRealtimeid(String.valueOf(sb));
@@ -418,7 +424,7 @@ public class InitialPointEdosService implements  IinitialPoint{
             {
                 sb =new StringBuilder();
                 temp=wp.getId().substring(0,wp.getId().indexOf("_"));
-                sb.append("SXJN.JSFW").append(temp).append("DD");
+                 sb.append(HEAD).append(".JSFW").append(temp).append("DD");
                 po.setRealtimeid(String.valueOf(sb));
             }
             points.add(po);
@@ -483,10 +489,10 @@ public class InitialPointEdosService implements  IinitialPoint{
 
                         if(wp.getId().endsWith("FDC"))
                         {
-                            sb.append("SXJN.JSFW").append(temp).append("FC");
+                             sb.append(HEAD).append(".JSFW").append(temp).append("FC");
                         }else
                         {
-                            sb.append("SXJN.JSFW").append(temp).append("GC");
+                             sb.append(HEAD).append(".JSFW").append(temp).append("GC");
                         }
 
                         po.setRealtimeid(String.valueOf(sb));
@@ -494,7 +500,7 @@ public class InitialPointEdosService implements  IinitialPoint{
                     {
                         sb =new StringBuilder();
                         temp=wp.getId().substring(0,wp.getId().indexOf("_"));
-                        sb.append("SXJN.JSFW").append(temp).append("DD");
+                         sb.append(HEAD).append(".JSFW").append(temp).append("DD");
                         po.setRealtimeid(String.valueOf(sb));
                     }
                     points.add(po);
@@ -558,10 +564,10 @@ public class InitialPointEdosService implements  IinitialPoint{
 
                             if(wp.getId().endsWith("FDC"))
                             {
-                                sb.append("SXJN.JSFW").append(temp).append("FC");
+                                 sb.append(HEAD).append(".JSFW").append(temp).append("FC");
                             }else
                             {
-                                sb.append("SXJN.JSFW").append(temp).append("GC");
+                                 sb.append(HEAD).append(".JSFW").append(temp).append("GC");
                             }
 
                             po.setRealtimeid(String.valueOf(sb));
@@ -569,7 +575,7 @@ public class InitialPointEdosService implements  IinitialPoint{
                         {
                             sb =new StringBuilder();
                             temp=wp.getId().substring(0,wp.getId().indexOf("_"));
-                            sb.append("SXJN.JSFW").append(temp).append("DD");
+                             sb.append(HEAD).append(".JSFW").append(temp).append("DD");
                             po.setRealtimeid(String.valueOf(sb));
                         }
                         points.add(po);
@@ -686,7 +692,7 @@ public class InitialPointEdosService implements  IinitialPoint{
 
                             sb =new StringBuilder();
                             temp=wp.getId().substring(0,wp.getId().indexOf("_"));
-                            sb.append("SXJN.JSFW").append(temp).append("DD");
+                             sb.append(HEAD).append(".JSFW").append(temp).append("DD");
                             po.setRealtimeid(String.valueOf(sb));
                         }
 
@@ -775,14 +781,14 @@ public class InitialPointEdosService implements  IinitialPoint{
 
                             sb =new StringBuilder();
                             temp=wp.getId().substring(0,wp.getId().indexOf("_"));
-                            sb.append("SXJN.").append(temp).append("FGL");
+                             sb.append(HEAD).append(".").append(temp).append("FGL");
                             po.setRealtimeid(String.valueOf(sb));
                         }else  if(wp.getId().endsWith("GDC"))
                         {
 
                             sb =new StringBuilder();
                             temp=wp.getId().substring(0,wp.getId().indexOf("_"));
-                            sb.append("SXJN.").append(temp).append("GGL");
+                             sb.append(HEAD).append(".").append(temp).append("GGL");
                             po.setRealtimeid(String.valueOf(sb));
                         }
 
@@ -898,13 +904,13 @@ public class InitialPointEdosService implements  IinitialPoint{
 //                                {
 //                                    sb =new StringBuilder();
 //                                    temp=wp.getId().substring(0,wp.getId().indexOf("_"));
-//                                    sb.append("SXJN.JSFW").append(temp).append("FJ");
+//                                     sb.append(HEAD).append(".JSFW").append(temp).append("FJ");
 //                                    po.setRealtimeid(String.valueOf(sb));
 //                                }else
 //                                {
 //                                    sb =new StringBuilder();
 //                                    temp=wp.getId().substring(0,wp.getId().indexOf("_"));
-//                                    sb.append("SXJN.").append(temp).append("FJ");
+//                                     sb.append(HEAD).append(".").append(temp).append("FJ");
 //                                    po.setRealtimeid(String.valueOf(sb));
 //                                }
 //                                points.add(po);
@@ -1004,13 +1010,13 @@ public class InitialPointEdosService implements  IinitialPoint{
                             {
                                 sb =new StringBuilder();
                                 temp=wp.getId().substring(0,wp.getId().indexOf("_"));
-                                sb.append("SXJN.JSFW").append(temp).append("FJ");
+                                 sb.append(HEAD).append(".JSFW").append(temp).append("FJ");
                                 po.setRealtimeid(String.valueOf(sb));
                             }else
                             {
                                 sb =new StringBuilder();
                                 temp=wp.getId().substring(0,wp.getId().indexOf("_"));
-                                sb.append("SXJN.").append(temp).append("FJ");
+                                 sb.append(HEAD).append(".").append(temp).append("FJ");
                                 po.setRealtimeid(String.valueOf(sb));
                             }
                             points.add(po);

+ 1 - 1
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/websocket/GenreSetPushService.java

@@ -79,7 +79,7 @@ public class GenreSetPushService {
         if (StringUtils.notEmp(id)) {
 
 
-            Double zjrl = 0.0;
+            Double zjrl = 1.0;
             Double zjts = 0.0;
 
             Double sjgl = 0.0;

+ 2 - 2
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/websocket/WpInfoPushService.java

@@ -116,7 +116,7 @@ public class WpInfoPushService {
 
             String id = wp.getId();
             double scadafdl = 0.0;
-            Double zjrl = 0.0;
+            Double zjrl = 1.0;
             Double zjts = 0.0;
 
             Double sjgl = 0.0;
@@ -1157,7 +1157,7 @@ public class WpInfoPushService {
             Map<String, Object> jczbmap = new HashMap<String, Object>();
             String id = wp.getId();
 
-            Double zjrl = 0.0;
+            Double zjrl = 1.0;
             Double zjts = 0.0;
 
             Double sjgl = 0.0;

+ 1 - 1
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/websocket/WtWarnPushService.java

@@ -49,7 +49,7 @@ public class WtWarnPushService {
 
                 List<Warning2> warnls=InitialRunner.warnmap.get(wt.getModelid());
 
-                if (!warnls.isEmpty()) {
+                if (StringUtils.notEmp(warnls) && !warnls.isEmpty()) {
 
                         if(!warnls.isEmpty())
                         {

+ 5 - 3
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/websocket/task/V2Task.java

@@ -1,11 +1,13 @@
 package com.gyee.frame.service.websocket.task;
-import java.util.List;
+
 import cn.hutool.core.date.DateUtil;
-import javax.annotation.Resource;
-import org.springframework.stereotype.Component;
 import com.gyee.frame.mapper.auto.TsysUserMapper;
 import com.gyee.frame.model.auto.TsysUser;
 import com.gyee.frame.model.auto.TsysUserExample;
+import org.springframework.stereotype.Component;
+
+import javax.annotation.Resource;
+import java.util.List;
 
 /**
  *测试类

+ 15 - 3
web/monitor-web-sxjn/src/main/java/com/gyee/frame/shiro/config/ShiroService.java

@@ -2,13 +2,14 @@ package com.gyee.frame.shiro.config;
 
 
 import com.gyee.frame.model.auto.TsysUser;
+import com.gyee.frame.model.auto.TvuePermission;
 import com.gyee.frame.model.custom.TokenUser;
+import com.gyee.frame.service.VuePermissionService;
+import com.gyee.frame.util.StringUtils;
 import org.springframework.stereotype.Service;
 
 import javax.annotation.Resource;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.Map;
+import java.util.*;
 
 @Service
 public class ShiroService {
@@ -17,6 +18,8 @@ public class ShiroService {
     @Resource
     TokenCache tokenCache;
 
+    @Resource
+    VuePermissionService vuePermissionService;
     //10天后过期
     public final long EXPIRE = 10 * 24 * 60 * 60;
 
@@ -45,6 +48,15 @@ public class ShiroService {
         result.put("authToken", token);
         result.put("user", tokenUser);
 
+        if(StringUtils.notEmp(tokenUser))
+        {
+            List<TvuePermission> list= vuePermissionService.getall(tokenUser.getLaborNum());
+            result.put("prmissionlist", list);
+        }else
+        {
+            result.put("prmissionlist", new ArrayList<>());
+        }
+
         return result;
     }
 

+ 3 - 3
web/monitor-web-sxjn/src/main/java/com/gyee/frame/shiro/service/MyShiroRealm.java

@@ -1,7 +1,5 @@
 package com.gyee.frame.shiro.service;
 
-import java.util.List;
-
 import com.gyee.frame.mapper.custom.PermissionDao;
 import com.gyee.frame.mapper.custom.RoleDao;
 import com.gyee.frame.mapper.custom.TsysUserDao;
@@ -19,9 +17,11 @@ import org.apache.shiro.authz.AuthorizationInfo;
 import org.apache.shiro.authz.SimpleAuthorizationInfo;
 import org.apache.shiro.realm.AuthorizingRealm;
 import org.apache.shiro.subject.PrincipalCollection;
-import javax.annotation.Resource;
 import org.springframework.stereotype.Service;
 
+import javax.annotation.Resource;
+import java.util.List;
+
 /**
  * 身份校验核心类
  * 

+ 16 - 17
web/monitor-web-sxjn/src/main/resources/application-dev.yml

@@ -12,16 +12,15 @@ spring:
         #        username: root
         #        password: 123456
 
-        #url: jdbc:oracle:thin:@192.168.2.215:1521:gdsj
+        url: jdbc:oracle:thin:@123.60.213.70:1521:gdnxfd
         #url: jdbc:oracle:thin:@10.0.118.71:1521:gdsj
-        #url: jdbc:oracle:thin:@10.83.68.165:1521:gdsj
-#        username: gdprod
-#        password: gd123
-#        driver-class-name: oracle.jdbc.driver.OracleDriver
-        url: jdbc:postgresql://10.81.3.151:5432/wisdom
-        username: gdprod
-        password: gd123
-        driver-class-name: org.postgresql.Driver
+        username: nxfdprod
+        password: gdnxfd123
+        driver-class-name: oracle.jdbc.driver.OracleDriver
+      #        url: jdbc:postgresql://10.81.3.151:5432/wisdom
+      #        username: gdprod
+      #        password: gd123
+      #        driver-class-name: org.postgresql.Driver
       #备数据源 #关闭
       slave:
         enabled: false
@@ -29,14 +28,14 @@ spring:
         username: root
         password: Gyee123
         #两票数据源
-#      ticket:
-#        url: jdbc:sqlserver://192.168.2.200:1434;DatabaseName=fdeamnew
-#        #url: jdbc:sqlserver://10.83.68.98:1434;DatabaseName=fdeamnew
-#        #url: jdbc:sqlserver://10.0.118.71:1433;DatabaseName=fdeamnew
-#        username: sa
-#        password: ibs
-#        #password: Gd!123456
-#        driver-class-name: com.microsoft.sqlserver.jdbc.SQLServerDriver
+        #      ticket:
+        #        url: jdbc:sqlserver://192.168.2.200:1434;DatabaseName=fdeamnew
+        #        #url: jdbc:sqlserver://10.83.68.98:1434;DatabaseName=fdeamnew
+        #        #url: jdbc:sqlserver://10.0.118.71:1433;DatabaseName=fdeamnew
+        #        username: sa
+        #        password: ibs
+        #        #password: Gd!123456
+        #        driver-class-name: com.microsoft.sqlserver.jdbc.SQLServerDriver
         #配置初始化连接数大小
       initial-size: 10
       # 最大连接数

+ 49 - 49
web/monitor-web-sxjn/src/main/resources/application.yml

@@ -27,8 +27,8 @@ gyee:
   rollVerification: true
   #实时数据库Url
   #baseurl: http://10.0.118.73:8011/ts
-  #baseurl: http://10.83.68.205:8011/ts
-  baseurl: http://10.81.3.155:8011/ts
+  baseurl: http://123.60.213.70:8011/ts
+  #baseurl: http://10.81.3.155:8011/ts
 
   #API访问ip
   #swaggerip: 49.4.50.80:8082
@@ -36,8 +36,8 @@ gyee:
   #默认小数位数
   digit: 2
   realtimedataBase: golden #数据查询模式 golden、hwy
-  #weatherurl: http://123.60.213.70:7011
-  weatherurl: http://10.81.3.155:7011
+  weatherurl: http://123.60.213.70:7011
+  #weatherurl: http://10.81.3.155:7011
   #weatherurl: http://10.83.68.97:7011
   weatherqygs: jn_qygs
   hbmaps: {CL_FDC_KEY: 2003,KB_FDC_KEY: 1460,DX_FDC_KEY: 2186,SY_FDC_KEY: 1366}
@@ -67,8 +67,8 @@ spring :
     cloud:
       nacos:
         discovery:
-          #server-addr: 192.168.56.1:8848
-          server-addr: 10.81.3.155:8848
+          server-addr: 192.168.56.1:8848
+          #server-addr: 10.81.3.155:8848
           #server-addr: 10.83.68.97:8848
           #指定yaml格式的配置
           file-extension: yaml
@@ -111,11 +111,11 @@ spring :
     time-zone: GMT+8
     date-format: yyyy-MM-dd HH:mm:ss
   redis:
-    database: 0
-    #host: 192.168.2.202
-    host: 10.81.3.155
+    database: 1
+    host: 123.60.213.70
+    #host: 10.81.3.155
     #host: 10.0.118.73
-    password:
+    password: gdnxfd123
     pool:
       maxTotal: 20
       maxIdle: 20
@@ -170,45 +170,45 @@ temperature:
 #总貌测点配置
 zmconfig:
   maps:
-#    XC_FDC_KEY:
-#      - XC66kVC1602
-#      - XC66kVC1601
-#      - XC2LC1304
-#      - XC1LC1302
-#      - XC35kV3604
-#      - XC35kV3504
-#      - XC35kV3404
-#      - XC35kV3304
-#      - XC35kV3204
-#      - XC35kV3104
-#      - XC2LC1304sc
-#      - XC1LC1302sc
-#      - XC35kV3604sc
-#      - XC35kV3504sc
-#      - XC35kV3404sc
-#      - XC35kV3304sc
-#      - XC35kV3204sc
-#      - XC35kV3104sc
-#
-#    XC_FDC_VALUES:
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0452
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0081
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0470
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0101
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0597
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0545
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0493
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0226
-#      - LN_GD_XCF_DQ_P1_L1_001_DI1028
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0125
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0470
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0102
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0598
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0546
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0494
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0227
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0175
-#      - LN_GD_XCF_DQ_P1_L1_001_DI0126
+    #    XC_FDC_KEY:
+    #      - XC66kVC1602
+    #      - XC66kVC1601
+    #      - XC2LC1304
+    #      - XC1LC1302
+    #      - XC35kV3604
+    #      - XC35kV3504
+    #      - XC35kV3404
+    #      - XC35kV3304
+    #      - XC35kV3204
+    #      - XC35kV3104
+    #      - XC2LC1304sc
+    #      - XC1LC1302sc
+    #      - XC35kV3604sc
+    #      - XC35kV3504sc
+    #      - XC35kV3404sc
+    #      - XC35kV3304sc
+    #      - XC35kV3204sc
+    #      - XC35kV3104sc
+    #
+    #    XC_FDC_VALUES:
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0452
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0081
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0470
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0101
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0597
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0545
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0493
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0226
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI1028
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0125
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0470
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0102
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0598
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0546
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0494
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0227
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0175
+    #      - LN_GD_XCF_DQ_P1_L1_001_DI0126
 
     CL_FDC_KEY:
       - CL110kV112dl

+ 11 - 4
web/monitor-web-sxjn/src/main/resources/mybatis-generator.xml

@@ -51,11 +51,18 @@
 <!--                userId="root"-->
 <!--                password="123456">-->
 <!--        </jdbcConnection>-->
+<!--        <jdbcConnection-->
+<!--                driverClass="oracle.jdbc.driver.OracleDriver"-->
+<!--                connectionURL="jdbc:oracle:thin:@10.0.118.71:1521:gdsj"-->
+<!--                userId="gdprod"-->
+<!--                password="gd123">-->
+<!--        </jdbcConnection>-->
+
         <jdbcConnection
                 driverClass="oracle.jdbc.driver.OracleDriver"
-                connectionURL="jdbc:oracle:thin:@10.0.118.71:1521:gdsj"
-                userId="gdprod"
-                password="gd123">
+                connectionURL="jdbc:oracle:thin:@123.60.213.70:1521:gdnxfd"
+                userId="nxfdprod"
+                password="gdnxfd123">
         </jdbcConnection>
 
 <!--                <jdbcConnection-->
@@ -110,7 +117,7 @@
 <!--        <table tableName='StopAnalysismain' domainObjectName='StopAnalysismain'/>-->
 <!--        <table tableName='StopAnalysismainVo' domainObjectName='StopAnalysismainVo'/>-->
 
-        <table tableName='windsubstationtestingpointnew' domainObjectName='Windsubstationtestingpointnew'/>
+        <table tableName='t_sys_user' domainObjectName='TsysUser'/>
 
 
     </context>

+ 257 - 0
web/monitor-web-sxjn/src/main/resources/mybatis/auto/SysCompanyMapper.xml

@@ -0,0 +1,257 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.gyee.frame.mapper.auto.SysCompanyMapper">
+    <resultMap id="BaseResultMap" type="com.gyee.frame.model.auto.SysCompany">
+        <result column="id" jdbcType="VARCHAR" property="id" />
+        <result column="parent_id" jdbcType="VARCHAR" property="parentId" />
+        <result column="company_name" jdbcType="VARCHAR" property="companyName" />
+        <result column="status" jdbcType="INTEGER" property="status" />
+        <result column="order_num" jdbcType="INTEGER" property="orderNum" />
+        <result column="childcount" jdbcType="INTEGER" property="childCount"/>
+    </resultMap>
+    <sql id="Example_Where_Clause">
+        <where>
+            <foreach collection="oredCriteria" item="criteria" separator="or">
+                <if test="criteria.valid">
+                    <trim prefix="(" prefixOverrides="and" suffix=")">
+                        <foreach collection="criteria.criteria" item="criterion">
+                            <choose>
+                                <when test="criterion.noValue">
+                                    and ${criterion.condition}
+                                </when>
+                                <when test="criterion.singleValue">
+                                    and ${criterion.condition} #{criterion.value}
+                                </when>
+                                <when test="criterion.betweenValue">
+                                    and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                                </when>
+                                <when test="criterion.listValue">
+                                    and ${criterion.condition}
+                                    <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                                        #{listItem}
+                                    </foreach>
+                                </when>
+                            </choose>
+                        </foreach>
+                    </trim>
+                </if>
+            </foreach>
+        </where>
+    </sql>
+    <sql id="Update_By_Example_Where_Clause">
+        <where>
+            <foreach collection="example.oredCriteria" item="criteria" separator="or">
+                <if test="criteria.valid">
+                    <trim prefix="(" prefixOverrides="and" suffix=")">
+                        <foreach collection="criteria.criteria" item="criterion">
+                            <choose>
+                                <when test="criterion.noValue">
+                                    and ${criterion.condition}
+                                </when>
+                                <when test="criterion.singleValue">
+                                    and ${criterion.condition} #{criterion.value}
+                                </when>
+                                <when test="criterion.betweenValue">
+                                    and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                                </when>
+                                <when test="criterion.listValue">
+                                    and ${criterion.condition}
+                                    <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                                        #{listItem}
+                                    </foreach>
+                                </when>
+                            </choose>
+                        </foreach>
+                    </trim>
+                </if>
+            </foreach>
+        </where>
+    </sql>
+    <sql id="Base_Column_List">
+	  	  	      	id,
+       	  	      	parent_id,
+       	  	      	company_name,
+       	  	      	status,
+       	  	    	order_num,
+       	  	    	(select count(1) from t_sys_company where parent_id=a.id) childcount
+       	</sql>
+    <select id="selectByExample" parameterType="com.gyee.frame.model.auto.SysCompanyExample" resultMap="BaseResultMap">
+        select
+        <if test="distinct">
+            distinct
+        </if>
+        <include refid="Base_Column_List" />
+        from t_sys_company a
+        <if test="_parameter != null">
+            <include refid="Example_Where_Clause" />
+        </if>
+        <if test="orderByClause != null">
+            order by ${orderByClause}
+        </if>
+    </select>
+    <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
+        select
+        <include refid="Base_Column_List" />
+        from t_sys_company a
+        where id = #{id,jdbcType=VARCHAR}
+    </select>
+
+    <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
+    delete from t_sys_company
+    where id = #{id,jdbcType=VARCHAR}
+  </delete>
+    <delete id="deleteByExample" parameterType="com.gyee.frame.model.auto.SysCompanyExample">
+        delete from t_sys_company
+        <if test="_parameter != null">
+            <include refid="Example_Where_Clause" />
+        </if>
+    </delete>
+
+    <insert id="insert" parameterType="com.gyee.frame.model.auto.SysCompany">
+    insert into t_sys_company (
+      	  	       id,
+       	  	       parent_id,
+       	  	       company_name,
+       	  	       status,
+       	  	       order_num
+       	    )
+    values (
+	  	  	      	#{id,jdbcType=VARCHAR},
+       	  	      	#{parentId,jdbcType=VARCHAR},
+       	  	      	#{companyName,jdbcType=VARCHAR},
+       	  	      	#{status,jdbcType=INTEGER},
+       	  	    	#{orderNum,jdbcType=INTEGER}
+       	    )
+  </insert>
+
+    <insert id="insertSelective" parameterType="com.gyee.frame.model.auto.SysCompany">
+        insert into t_sys_company
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+
+            <if test="id != null">
+                id,
+            </if>
+
+
+            <if test="parentId != null">
+                parent_id,
+            </if>
+
+
+            <if test="companyName != null">
+                company_name,
+            </if>
+            <if test="status != null">
+                status,
+            </if>
+
+
+            <if test="orderNum != null">
+                order_num,
+            </if>
+
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">
+                #{id,jdbcType=VARCHAR},
+            </if>
+            <if test="parentId != null">
+                #{parentId,jdbcType=VARCHAR},
+            </if>
+            <if test="companyName != null">
+                #{companyName,jdbcType=VARCHAR},
+            </if>
+            <if test="status != null">
+                #{status,jdbcType=INTEGER},
+            </if>
+            <if test="orderNum != null">
+                #{orderNum,jdbcType=INTEGER},
+            </if>
+        </trim>
+    </insert>
+
+    <select id="countByExample" parameterType="com.gyee.frame.model.auto.SysCompanyExample" resultType="java.lang.Long">
+        select count(*) from t_sys_company a
+        <if test="_parameter != null">
+            <include refid="Example_Where_Clause" />
+        </if>
+    </select>
+
+    <update id="updateByExampleSelective" parameterType="map">
+        update t_sys_company
+        <set>
+            <if test="record.id != null">
+                id = #{record.id,jdbcType=VARCHAR},
+            </if>
+            <if test="record.parentId != null">
+                parent_id = #{record.parentId,jdbcType=VARCHAR},
+            </if>
+            <if test="record.companyName != null">
+                company_name = #{record.companyName,jdbcType=VARCHAR},
+            </if>
+            <if test="record.status != null">
+                status = #{record.status,jdbcType=INTEGER},
+            </if>
+            <if test="record.orderNum != null">
+                order_num = #{record.orderNum,jdbcType=INTEGER},
+            </if>
+
+        </set>
+        <if test="_parameter != null">
+            <include refid="Update_By_Example_Where_Clause" />
+        </if>
+    </update>
+
+
+    <update id="updateByExample" parameterType="map">
+        update t_sys_company
+        set
+        id = #{record.id,jdbcType=VARCHAR},
+        parent_id = #{record.parentId,jdbcType=VARCHAR},
+        company_name = #{record.companyName,jdbcType=VARCHAR},
+        status = #{record.status,jdbcType=INTEGER},
+        order_num = #{record.orderNum,jdbcType=INTEGER}
+        <if test="_parameter != null">
+            <include refid="Update_By_Example_Where_Clause" />
+        </if>
+    </update>
+
+
+    <update id="updateByPrimaryKeySelective" parameterType="com.gyee.frame.model.auto.SysCompany">
+        update t_sys_company
+        <set>
+            <if test="parentId != null">
+                parent_id = #{parentId,jdbcType=VARCHAR},
+            </if>
+            <if test="companyName != null">
+                company_name = #{companyName,jdbcType=VARCHAR},
+            </if>
+
+            <if test="status != null">
+                status = #{status,jdbcType=INTEGER},
+            </if>
+            <if test="orderNum != null">
+                order_num = #{orderNum,jdbcType=INTEGER},
+            </if>
+        </set>
+        where
+        id = #{id,jdbcType=VARCHAR}
+
+    </update>
+
+
+
+    <update id="updateByPrimaryKey" parameterType="com.gyee.frame.model.auto.SysCompany">
+    update t_sys_company
+    set 
+             	        	    	 			parent_id = #{parentId,jdbcType=VARCHAR},
+		     	        	    	 			company_name = #{companyName,jdbcType=VARCHAR},
+		     	        	    	 			status = #{status,jdbcType=INTEGER},
+		     	        	    	 			order_num = #{orderNum,jdbcType=INTEGER}
+		     	        where 
+            id = #{id,jdbcType=VARCHAR}
+                                                                    
+  </update>
+
+
+</mapper>

+ 3 - 3
web/monitor-web-sxjn/src/main/resources/mybatis/auto/SysDepartmentMapper.xml

@@ -2,7 +2,7 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.gyee.frame.mapper.auto.SysDepartmentMapper">
   <resultMap id="BaseResultMap" type="com.gyee.frame.model.auto.SysDepartment">
-    <result column="id" jdbcType="INTEGER" property="id" />
+    <result column="id" jdbcType="VARCHAR" property="id" />
     <result column="parent_id" jdbcType="VARCHAR" property="parentId" />
     <result column="dept_name" jdbcType="VARCHAR" property="deptName" />
     <result column="leader" jdbcType="VARCHAR" property="leader" />
@@ -95,14 +95,14 @@
       order by ${orderByClause}
     </if>
   </select>
-  <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
+  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
     select 
     <include refid="Base_Column_List" />
     from t_sys_department a
     where id = #{id,jdbcType=INTEGER}
   </select>
 
-  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
     delete from t_sys_department
     where id = #{id,jdbcType=INTEGER}
   </delete>

+ 26 - 7
web/monitor-web-sxjn/src/main/resources/mybatis/auto/TsysUserMapper.xml

@@ -7,8 +7,9 @@
       <arg column="username" jdbcType="VARCHAR" javaType="java.lang.String" />
       <arg column="password" jdbcType="VARCHAR" javaType="java.lang.String" />
       <arg column="nickname" jdbcType="VARCHAR" javaType="java.lang.String" />
-      <arg column="dep_id" jdbcType="INTEGER" javaType="java.lang.Integer" />
+      <arg column="dep_id" jdbcType="VARCHAR" javaType="java.lang.String" />
       <arg column="pos_id" jdbcType="VARCHAR" javaType="java.lang.String" />
+      <arg column="com_id" jdbcType="VARCHAR" javaType="java.lang.String" />
     </constructor>
   </resultMap>
   
@@ -17,10 +18,13 @@
     <result column="username" jdbcType="VARCHAR" property="username" />
     <result column="password" jdbcType="VARCHAR" property="password" />
     <result column="nickname" jdbcType="VARCHAR" property="nickname" />
-    <result column="dep_id" jdbcType="INTEGER" property="depId" />
+    <result column="dep_id" jdbcType="VARCHAR" property="depId" />
     <result column="pos_id" jdbcType="VARCHAR" property="posId" />
-    <result column="dep_name" jdbcType="INTEGER" property="depName" />
+      <result column="com_id" jdbcType="VARCHAR" property="comId" />
+      <result column="com_name" jdbcType="VARCHAR" property="comName" />
+    <result column="dep_name" jdbcType="VARCHAR" property="depName" />
     <result column="pos_name" jdbcType="VARCHAR" property="posName" />
+
   </resultMap>
   
 
@@ -104,6 +108,7 @@
     select 
     <include refid="Base_Column_List" />
     ,(select dept_name from t_sys_department dep where dep.id=tsu.dep_id) as dep_name,
+      (select company_name from t_sys_company com where com.id=tsu.dep_id) as com_name,
 	(select post_name from t_sys_position pos where pos.id=tsu.pos_id) as pos_name
     from t_sys_user tsu
     where id = #{id,jdbcType=VARCHAR}
@@ -120,10 +125,10 @@
   </delete>
   <insert id="insert" parameterType="com.gyee.frame.model.auto.TsysUser" >
     insert into t_sys_user (id, username, password, 
-      nickname, dep_id, pos_id
+      nickname, dep_id, pos_id,com_id
       )
     values (#{id,jdbcType=VARCHAR}, #{username,jdbcType=VARCHAR}, #{password,jdbcType=VARCHAR}, 
-      #{nickname,jdbcType=VARCHAR}, #{depId,jdbcType=INTEGER}, #{posId,jdbcType=VARCHAR}
+      #{nickname,jdbcType=VARCHAR}, #{depId,jdbcType=INTEGER}, #{posId,jdbcType=VARCHAR}, #{comId,jdbcType=VARCHAR}
       )
   </insert>
   <insert id="insertSelective" parameterType="com.gyee.frame.model.auto.TsysUser" >
@@ -147,6 +152,9 @@
       <if test="posId != null" >
         pos_id,
       </if>
+        <if test="comId != null" >
+            com_id,
+        </if>
     </trim>
     <trim prefix="values (" suffix=")" suffixOverrides="," >
       <if test="id != null" >
@@ -167,6 +175,9 @@
       <if test="posId != null" >
         #{posId,jdbcType=VARCHAR},
       </if>
+        <if test="comId != null" >
+            #{comId,jdbcType=VARCHAR},
+        </if>
     </trim>
   </insert>
   <select id="countByExample" parameterType="com.gyee.frame.model.auto.TsysUserExample" resultType="java.lang.Integer" >
@@ -196,6 +207,9 @@
       <if test="record.posId != null" >
         pos_id = #{record.posId,jdbcType=VARCHAR},
       </if>
+        <if test="record.comId != null" >
+            com_id = #{record.comId,jdbcType=VARCHAR},
+        </if>
     </set>
     <if test="_parameter != null" >
       <include refid="Update_By_Example_Where_Clause" />
@@ -208,7 +222,8 @@
       password = #{record.password,jdbcType=VARCHAR},
       nickname = #{record.nickname,jdbcType=VARCHAR},
       dep_id = #{record.depId,jdbcType=INTEGER},
-      pos_id = #{record.posId,jdbcType=VARCHAR}
+      pos_id = #{record.posId,jdbcType=VARCHAR},
+      com_id = #{record.comId,jdbcType=VARCHAR}
     <if test="_parameter != null" >
       <include refid="Update_By_Example_Where_Clause" />
     </if>
@@ -231,6 +246,9 @@
       <if test="posId != null" >
         pos_id = #{posId,jdbcType=VARCHAR},
       </if>
+        <if test="posId != null" >
+            com_id = #{comId,jdbcType=VARCHAR},
+        </if>
     </set>
     where id = #{id,jdbcType=VARCHAR}
   </update>
@@ -240,7 +258,8 @@
       password = #{password,jdbcType=VARCHAR},
       nickname = #{nickname,jdbcType=VARCHAR},
       dep_id = #{depId,jdbcType=INTEGER},
-      pos_id = #{posId,jdbcType=VARCHAR}
+      pos_id = #{posId,jdbcType=VARCHAR},
+      com_id = #{comId,jdbcType=VARCHAR}
     where id = #{id,jdbcType=VARCHAR}
   </update>
 </mapper>

+ 20 - 5
web/monitor-web-sxjn/src/main/resources/mybatis/auto/TvueUserMapper.xml

@@ -12,6 +12,7 @@
     <result column="NICKNAME" jdbcType="VARCHAR" property="nickname" />
     <result column="DEP_ID" jdbcType="DECIMAL" property="depId" />
     <result column="POS_ID" jdbcType="VARCHAR" property="posId" />
+      <result column="COM_ID" jdbcType="VARCHAR" property="comId" />
   </resultMap>
   <sql id="Example_Where_Clause">
     <!--
@@ -84,7 +85,7 @@
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
     -->
-    ID, USERNAME, PASSWORD, NICKNAME, DEP_ID, POS_ID
+    ID, USERNAME, PASSWORD, NICKNAME, DEP_ID, POS_ID,COM_ID
   </sql>
   <select id="selectByExample" parameterType="com.gyee.frame.model.auto.TvueUserExample" resultMap="BaseResultMap">
     <!--
@@ -138,10 +139,10 @@
       This element is automatically generated by MyBatis Generator, do not modify.
     -->
     insert into T_VUE_USER (ID, USERNAME, PASSWORD, 
-      NICKNAME, DEP_ID, POS_ID
+      NICKNAME, DEP_ID, POS_ID,COM_ID
       )
     values (#{id,jdbcType=VARCHAR}, #{username,jdbcType=VARCHAR}, #{password,jdbcType=VARCHAR}, 
-      #{nickname,jdbcType=VARCHAR}, #{depId,jdbcType=DECIMAL}, #{posId,jdbcType=VARCHAR}
+      #{nickname,jdbcType=VARCHAR}, #{depId,jdbcType=DECIMAL}, #{posId,jdbcType=VARCHAR}, #{comId,jdbcType=VARCHAR}
       )
   </insert>
   <insert id="insertSelective" parameterType="com.gyee.frame.model.auto.TvueUser">
@@ -169,6 +170,9 @@
       <if test="posId != null">
         POS_ID,
       </if>
+        <if test="posId != null">
+            COM_ID,
+        </if>
     </trim>
     <trim prefix="values (" suffix=")" suffixOverrides=",">
       <if test="id != null">
@@ -189,6 +193,9 @@
       <if test="posId != null">
         #{posId,jdbcType=VARCHAR},
       </if>
+        <if test="comId != null">
+            #{comId,jdbcType=VARCHAR},
+        </if>
     </trim>
   </insert>
   <select id="countByExample" parameterType="com.gyee.frame.model.auto.TvueUserExample" resultType="java.lang.Long">
@@ -226,6 +233,9 @@
       <if test="record.posId != null">
         POS_ID = #{record.posId,jdbcType=VARCHAR},
       </if>
+        <if test="record.comId != null">
+            COM_ID = #{record.comId,jdbcType=VARCHAR},
+        </if>
     </set>
     <if test="_parameter != null">
       <include refid="Update_By_Example_Where_Clause" />
@@ -242,7 +252,8 @@
       PASSWORD = #{record.password,jdbcType=VARCHAR},
       NICKNAME = #{record.nickname,jdbcType=VARCHAR},
       DEP_ID = #{record.depId,jdbcType=DECIMAL},
-      POS_ID = #{record.posId,jdbcType=VARCHAR}
+      POS_ID = #{record.posId,jdbcType=VARCHAR},
+      COM_ID = #{record.comId,jdbcType=VARCHAR}
     <if test="_parameter != null">
       <include refid="Update_By_Example_Where_Clause" />
     </if>
@@ -269,6 +280,9 @@
       <if test="posId != null">
         POS_ID = #{posId,jdbcType=VARCHAR},
       </if>
+        <if test="posId != null">
+            COM_ID = #{comId,jdbcType=VARCHAR},
+        </if>
     </set>
     where ID = #{id,jdbcType=VARCHAR}
   </update>
@@ -282,7 +296,8 @@
       PASSWORD = #{password,jdbcType=VARCHAR},
       NICKNAME = #{nickname,jdbcType=VARCHAR},
       DEP_ID = #{depId,jdbcType=DECIMAL},
-      POS_ID = #{posId,jdbcType=VARCHAR}
+      POS_ID = #{posId,jdbcType=VARCHAR},
+      COM_ID = #{comId,jdbcType=VARCHAR}
     where ID = #{id,jdbcType=VARCHAR}
   </update>
 

+ 6 - 3
web/monitor-web-sxjn/src/main/resources/mybatis/custom/TsysUserMapper.xml

@@ -6,10 +6,12 @@
     <result column="username" jdbcType="VARCHAR" property="username" />
     <result column="password" jdbcType="VARCHAR" property="password" />
     <result column="nickname" jdbcType="VARCHAR" property="nickname" />
-    <result column="dep_id" jdbcType="INTEGER" property="depId" />
+    <result column="dep_id" jdbcType="VARCHAR" property="depId" />
     <result column="pos_id" jdbcType="VARCHAR" property="posId" />
-    <result column="dep_name" jdbcType="INTEGER" property="depName" />
+    <result column="dep_name" jdbcType="VARCHAR" property="depName" />
     <result column="pos_name" jdbcType="VARCHAR" property="posName" />
+      <result column="com_id" jdbcType="VARCHAR" property="comId" />
+      <result column="com_name" jdbcType="VARCHAR" property="comName" />
   </resultMap>
   
   
@@ -22,7 +24,8 @@
    	select id, username, password, nickname, 
 	(select dept_name from t_sys_department dep where dep.id=tsu.dep_id)as dep_name,
 	(select post_name from t_sys_position pos where pos.id=tsu.pos_id)as pos_name,
-	dep_id, pos_id
+     (select company_name from t_sys_company com where com.id=tsu.com_id)as com_name,
+	dep_id, pos_id, com_id
 	from t_sys_user tsu 
 	<if test="_parameter != null and _parameter!=''" >
        where  username= #{_parameter}

+ 3 - 4
web/monitor-web-sxjn/src/main/resources/mybatis/custom/TvuePremissionMapper.xml

@@ -24,11 +24,10 @@
 	</select>
 
 <select id="findByAdminUserId" parameterType="String" resultMap="BaseResultMap">
-        select distinct p.*,(select count(1) from t_vue_permission where pid=p.id) childcount
+  select distinct p.*,(select count(1) from t_vue_permission where pid=p.id) childcount
         from t_vue_permission_role spr,t_vue_role_user sru,t_vue_permission p
-        where 	spr.role_id = sru.sys_role_id AND spr.permission_id = p.id AND sru.sys_user_id=#{userId} 
-		GROUP BY p.id
-		ORDER BY order_num  is null  ASC,order_num  ASC
+        where   spr.role_id = sru.sys_role_id AND spr.permission_id = p.id AND sru.sys_user_id='1'
+    ORDER BY order_num    ASC,order_num  ASC
  </select>
  
  <select id="queryRoleId"  parameterType="String" resultMap="BaseResultMap">

+ 6 - 3
web/monitor-web-sxjn/src/main/resources/mybatis/custom/TvueUserMapper.xml

@@ -6,10 +6,12 @@
     <result column="username" jdbcType="VARCHAR" property="username" />
     <result column="password" jdbcType="VARCHAR" property="password" />
     <result column="nickname" jdbcType="VARCHAR" property="nickname" />
-    <result column="dep_id" jdbcType="INTEGER" property="depId" />
+    <result column="dep_id" jdbcType="VARCHAR" property="depId" />
     <result column="pos_id" jdbcType="VARCHAR" property="posId" />
-    <result column="dep_name" jdbcType="INTEGER" property="depName" />
+    <result column="dep_name" jdbcType="VARCHAR" property="depName" />
     <result column="pos_name" jdbcType="VARCHAR" property="posName" />
+      <result column="com_id" jdbcType="VARCHAR" property="comId" />
+      <result column="com_name" jdbcType="VARCHAR" property="comName" />
   </resultMap>
   
   
@@ -22,7 +24,8 @@
    	select id, username, password, nickname, 
 	(select dept_name from t_sys_department dep where dep.id=tsu.dep_id)as dep_name,
 	(select post_name from t_sys_position pos where pos.id=tsu.pos_id)as pos_name,
-	dep_id, pos_id
+     (select company_name from t_sys_company com where com.id=tsu.com_id)as com_name,
+	dep_id, pos_id, com_id
 	from t_vue_user tsu
 	<if test="_parameter != null and _parameter!=''" >
        where  username= #{_parameter}

BIN
web/monitor-web-sxjn/src/main/resources/static/syz.7z


+ 174 - 0
web/monitor-web-sxjn/src/main/resources/templates/admin/sysCompany/add.html

@@ -0,0 +1,174 @@
+<!DOCTYPE html>
+<html xmlns:th="http://www.thymeleaf.org" 
+      xmlns:sec="http://www.pollix.at/thymeleaf/shiro">
+<head th:replace="admin/common/html/tableHead :: head(~{::title},~{::link},~{::style})">
+
+<title th:text=${title}></title>
+<!-- 这儿引用单独的css link -->
+<!-- Ladda for Bootstrap 3按钮加载进度插件 -->
+<link rel="stylesheet" th:href="@{/static/admin/assets/js/button/ladda/ladda.min.css}">
+<!-- bootstrap-table表单样式 -->
+<link th:href="@{/static/admin/assets/js/bootstrap/css/bootstrap-table/bootstrap-table.min.css}" rel="stylesheet"/>
+<!-- 用户界面自定义css -->
+<link th:href="@{/static/admin/user/css/user-add.css}" rel="stylesheet"/>
+<style type="text/css"></style>
+</head>
+
+<body>
+
+<div class="content-wrap">
+	<div class="row">
+		<div class="col-sm-12">
+			<div class="nest" id="elementClose">
+				<div class="">
+				</div>
+				<div class="body-nest" id="element">
+					<div class="panel-body">
+						<form  class="form-horizontal m" id="form-add">
+						
+									<div class="form-group">
+										<label class="col-sm-3 control-label ">父级:</label>
+										<div class="col-sm-8">
+											<input class="form-control" type="hidden" id="parentId" name="parentId"/>
+											<input class="form-control" readonly="true" type="text" id="pidName" onclick="selectMenuTree()" />
+										</div>
+									</div>
+									
+								
+									<div class="form-group">
+										<label class="col-sm-3 control-label ">公司名称:</label>
+										<div class="col-sm-8">
+											<input class="form-control" type="text" id="companyName" name="companyName"/>
+										</div>
+									</div>
+
+								
+									<div class="form-group">
+										<label class="col-sm-3 control-label ">状态:</label>
+										<div class="col-sm-8">
+											<select class="form-control"  id="status" name="status">
+													<option value="1">开启</option>
+													<option value="0">关闭</option>
+											</select>
+										</div>
+									</div>
+									
+								
+									<div class="form-group">
+										<label class="col-sm-3 control-label ">排序:</label>
+										<div class="col-sm-8">
+											<input class="form-control" type="number" value="1" id="orderNum" name="orderNum"/>
+										</div>
+									</div>
+									
+			
+									<div class="form-group">
+										<div class="form-control-static col-sm-offset-9">
+											<button type="submit" class="btn btn-primary">提交</button>
+											<button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>
+										</div>
+									</div>
+						 </form>
+					</div>
+				</div>
+			</div>
+		</div>
+	</div>
+</div>
+
+<!-- 通用js -->
+<div th:include="admin/common/html/js :: onload_js">
+   
+</div>
+<!-- bootstarp 表格 -->
+<script th:src="@{/static/admin/assets/js/bootstrap/js/bootstrap-table/bootstrap-table.min.js}" type="text/javascript"></script>
+<script th:src="@{/static/admin/assets/js/bootstrap/js/bootstrap-table/locale/bootstrap-table-zh-CN.min.js}" type="text/javascript"></script>
+<script th:src="@{/static/admin/assets/js/bootstrap/js/base_list.js}" type="text/javascript"></script>
+
+
+<!-- 弹窗 -->
+<script  th:src="@{/static/admin/assets/js/layer/layer.js}" type="text/javascript"></script>
+<!-- 遮罩层 -->
+<script  th:src="@{/static/admin/assets/js/blockUI/jquery.blockUI.js}" type="text/javascript"></script>
+<!-- jqueryForm序列化 -->
+<script  th:src="@{/static/js/jqueryFormSerializeJson.js}" type="text/javascript"></script>
+<script type="text/javascript">
+
+$(function(){
+	 $(".MyDate").datetimepicker({
+		 	format: "yyyy-mm-dd hh:00:00",
+	        startDate: new Date(),
+	        autoclose: true,
+	        todayBtn: true,
+	        language: 'zh-CN',
+	        initialDate:new Date(),
+	        minView: 1      
+	    });
+	
+})
+
+
+$("#form-add").validate({
+	rules:{
+		companyName:{
+			required:true,
+			minlength: 2,
+			maxlength: 20,
+			remote: {
+                url: rootPath + "/SysCompanyController/checkNameUnique",
+                type: "post",
+                dataType: "json",
+                dataFilter: function(data, type) {
+                    if (data == "0")
+                    	return true;
+                    else 
+                    	return false;
+                }
+            }
+		}
+	},
+	messages: {
+        "companyName": {
+            remote: "已经存在"
+        }
+    },
+	submitHandler:function(form){
+		add();
+	}
+});
+
+/**
+ * 用户添加方法
+ */
+function add() {
+	var dataFormJson=$("#form-add").serialize();
+	$.ajax({
+		cache : true,
+		type : "POST",
+		url : rootPath + "/SysCompanyController/add",
+		data : dataFormJson,
+		async : false,
+		error : function(request) {
+			$.modal.alertError("系统错误");
+		},
+		success : function(data) {
+			$.operate.saveSuccess(data);
+		}
+	});
+}
+
+
+/*菜单管理-修改-选择菜单树*/
+function selectMenuTree() {
+	var url =  rootPath+ "/SysCompanyController/tree";
+	$.modal.open("选择菜单", url, '380', '380');
+}
+
+
+</script>
+
+
+</body>
+
+
+</html>

+ 21 - 59
web/analysis-hb/target/classes/templates/admin/province/sysProvince/edit.html

@@ -17,7 +17,7 @@
 </head>
 
 <body>
-      	   	      	      	      	      	      	      	      	      	      	      	      
+      	   	      	      	      	      	      	      	      	      
 <div class="content-wrap">
 	<div class="row">
 		<div class="col-sm-12">
@@ -26,45 +26,35 @@
 				</div>
 				<div class="body-nest" id="element">
 					<div class="panel-body">
-						<form  class="form-horizontal m" id="form-edit" th:object="${SysProvince}">
+						<form  class="form-horizontal m" id="form-edit" th:object="${SysCompany}">
 							<input id="id" name="id" type="hidden" th:field="*{id}"/>
 						
 									<div class="form-group">
-										<label class="col-sm-3 control-label ">省份代码:</label>
+										<label class="col-sm-3 control-label ">父级:</label>
 										<div class="col-sm-8">
-											<input class="form-control" type="text" id="provinceCode" name="provinceCode" th:value="*{provinceCode}"/>
+											<input class="form-control" type="hidden" id="parentId" name="parentId" th:value="*{parentId}"/>
+											<input class="form-control" readonly="true" type="text" th:value="${perSysCompany.companyName}" id="pidName" onclick="selectMenuTree()" />
 										</div>
 									</div>
 
 								
 									<div class="form-group">
-										<label class="col-sm-3 control-label ">省份名称:</label>
+										<label class="col-sm-3 control-label ">公司名称:</label>
 										<div class="col-sm-8">
-											<input class="form-control" type="text" id="provinceName" name="provinceName" th:value="*{provinceName}"/>
+											<input class="form-control" type="text" id="companyName" name="companyName" th:value="*{companyName}"/>
+											
 										</div>
 									</div>
 
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">简称:</label>
-										<div class="col-sm-8">
-											<input class="form-control" type="text" id="shortName" name="shortName" th:value="*{shortName}"/>
-										</div>
-									</div>
-
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">经度:</label>
-										<div class="col-sm-8">
-											<input class="form-control" type="text" id="lng" name="lng" th:value="*{lng}"/>
-										</div>
-									</div>
 
 								
 									<div class="form-group">
-										<label class="col-sm-3 control-label ">纬度:</label>
+										<label class="col-sm-3 control-label ">状态:</label>
 										<div class="col-sm-8">
-											<input class="form-control" type="text" id="lat" name="lat" th:value="*{lat}"/>
+											<select class="form-control"  id="status" name="status" th:field="*{status}">
+													<option value="1">开启</option>
+													<option value="0">关闭</option>
+											</select>
 										</div>
 									</div>
 
@@ -72,41 +62,7 @@
 									<div class="form-group">
 										<label class="col-sm-3 control-label ">排序:</label>
 										<div class="col-sm-8">
-											<input class="form-control" type="number" id="sort" name="sort" th:value="*{sort}"/>
-										</div>
-									</div>
-
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">创建时间:</label>
-										<div class="col-sm-8">
-											<input class="form-control MyDate" type="text" id="gmtCreate" name="gmtCreate" th:value="*{#dates.format(gmtCreate,'yyyy-MM-dd HH:mm:ss')}"/>
-										</div>
-									</div>
-									
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">修改时间:</label>
-										<div class="col-sm-8">
-											<input class="form-control MyDate" type="text" id="gmtModified" name="gmtModified" th:value="*{#dates.format(gmtModified,'yyyy-MM-dd HH:mm:ss')}"/>
-										</div>
-									</div>
-									
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">备注:</label>
-										<div class="col-sm-8">
-											<input class="form-control" type="text" id="memo" name="memo" th:value="*{memo}"/>
-										</div>
-									</div>
-
-								
-									<div class="form-group">
-										<label class="col-sm-3 control-label ">状态:</label>
-										<div class="col-sm-8">
-											<select name="dataState" id="dataState"  class="form-control m-b" th:with="type=${@dict.getType('sys_province_state')}" th:field="*{dataState}">
-												<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
-											</select>
+											<input class="form-control" type="number" id="orderNum" name="orderNum" th:value="*{orderNum}"/>
 										</div>
 									</div>
 
@@ -160,12 +116,18 @@ $("#form-edit").validate({
 	}
 });
 
+/*菜单管理-修改-选择菜单树*/
+function selectMenuTree() {
+	var url = rootPath + "/SysCompanyController/tree";
+	$.modal.open("选择菜单", url, '380', '380');
+}
+
 function edit() {
 	var dataFormJson = $("#form-edit").serialize();
 	$.ajax({
 		cache : true,
 		type : "POST",
-		url : rootPath + "/SysProvinceController/edit",
+		url : rootPath + "/SysCompanyController/edit",
 		data : dataFormJson,
 		async : false,
 		error : function(request) {

+ 314 - 0
web/monitor-web-sxjn/src/main/resources/templates/admin/sysCompany/list.html

@@ -0,0 +1,314 @@
+<!DOCTYPE html>
+<html xmlns:th="http://www.thymeleaf.org" 
+      xmlns:sec="http://www.pollix.at/thymeleaf/shiro">
+<head th:replace="admin/common/html/head :: Head_Premiss(~{::title},~{::link},~{::style})">
+
+<title th:text=${title}></title>
+<!-- 这儿引用单独的css link -->
+<!-- Ladda for Bootstrap 3按钮加载进度插件 -->
+<link rel="stylesheet" th:href="@{/static/admin/assets/js/button/ladda/ladda.min.css}">
+
+<link rel="stylesheet" th:href="@{/static/js/bootstrap-treetable/bootstrap-treetable.min.css}">
+
+<style type="text/css">
+/**
+*这里写单独的css样式
+*/
+
+</style>
+
+</head>
+
+<body id="listbody">
+<!-- # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # 代码编写处 # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # -->
+
+<!-- 右边内容 -->
+<div class="wrap-fluid">
+    <div class="container-fluid paper-wrap bevel tlbr">
+        <!-- 内容 -->
+        <!--标题 通用-->
+        <div th:replace="admin/common/html/title :: title(${title},${parenttitle},${isMsg},${msgHTML})">
+        </div>
+        <!-- 结束标题 通用-->
+        <div class="content-wrap">
+            <!-- 结束内容 -->
+            <div class="row">
+                <div class="col-sm-12">
+                <!-- 搜索条件 -->
+                
+                	 <div class="nest" id="inlineClose">
+                            <div class="title-alt">
+                                <h6>搜索条件</h6>
+                                <div class="titleClose">
+                                    <a class="gone" href="#inlineClose">
+                                        <span class="entypo-cancel"></span>
+                                    </a>
+                                </div>
+                                <div class="titleToggle">
+                                    <a class="nav-toggle-alt" href="#search_div" >
+                                        <span class="entypo-down-open"></span>
+                                    </a>
+                                </div>
+                            </div>
+
+                            <div class="body-nest" id="search_div" style="display: none">
+                                <div class="form_left">
+                                    <form role="form" class="form-inline">
+                                        <div class="form-group">
+                                            <label for="exampleInputEmail2" class="sr-only">搜索名字</label>
+                                            <input type="text" name="searchText" placeholder="搜索名字"class="form-control">
+                                        </div>
+                                        <button onclick="$.table.search(this)" class="btn btn-success" type="button"><i class="fa fa-search"></i>&nbsp;搜索</button>
+                                    </form>
+                                </div>
+                            </div>
+                        </div>
+                	<!-- END搜索条件 -->
+                    <!-- 空白页开始-->
+                    <div class="nest" id="Blank_PageClose">
+                        <div class="title-alt">
+                            <h6>表单</h6>
+                            <div class="titleClose">
+                                <a class="gone" href="#Blank_PageClose">
+                                    <span class="entypo-cancel"></span>
+                                </a>
+                            </div>
+                            <div class="titleToggle">
+                                <a class="nav-toggle-alt" href="#Blank_Page_Content">
+                                    <span class="entypo-up-open"></span>
+                                </a>
+                            </div>
+                        </div>
+                        
+                        <div class="body-nest" id="Blank_Page_Content">
+                            <!-- 工具条 -->
+                            <div class="btn-group hidden-xs" id="exampleTableEventsToolbar" role="group">
+                            	<button onclick="add()" type="button" class="btn btn-primary">
+                                    <span class="entypo-plus-squared"></span>&nbsp;&nbsp;新增
+                                </button>
+                               <button onclick="batRemove()" type="button" class="btn btn-info">
+                                    <span class="entypo-trash"></span>&nbsp;&nbsp;删除
+                               </button>
+                               <button id="expandAllBtn"  type="button" class="btn btn-success">
+                                    <span class="entypo-shuffle"></span>&nbsp;&nbsp;展开/折叠
+                               </button>
+                               
+                           </div>
+                            <!-- 工具条 end-->
+                           <table id="demo" class="table-striped footable-res footable metro-blue" data-page-size="6">
+                                   
+                           </table>
+                        </div>
+                    </div>
+                </div>
+                <!-- 空白页结束 -->
+            </div>
+            <!-- 结束内容 -->
+        </div>
+    </div>
+</div>
+<!-- 结束右边内容 -->
+<!-- # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # 代码编写处 END# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # -->
+
+
+
+
+
+
+
+<!-- 右侧隐藏滑块内容 -->
+<div th:include="admin/common/html/rightHide :: rightHide">
+    
+</div>
+   <!-- END 右侧隐藏滑块内容-->
+
+<!-- 通用js -->
+<div th:include="admin/common/html/js :: onload_js_Premiss">
+   
+</div>
+<script th:src="@{/static/js/bootstrap-treetable/bootstrap-treetable.min.js}" type="text/javascript"></script>
+<script type="text/javascript">
+var dataUrl=window.rootPath+"/SysCompanyController/list2";
+var removeUrl=window.rootPath+"/SysCompanyController/remove";
+var createUrl=window.rootPath+"/SysCompanyController/add";
+var updateUrl=window.rootPath+"/SysCompanyController/edit/{id}";
+var exportUrl=window.rootPath+"/SysCompanyController/export";
+
+
+var treeTable = $('#demo').bootstrapTreeTable({
+    toolbar: "#demo-toolbar",//顶部工具条
+    expandColumn : 3,// 在哪一列上面显示展开按钮
+    url: dataUrl,// 请求后台的URL(*)
+    type: 'post',
+    id : "id",
+    rootIdValue: '0',
+    parentId: 'parentId',
+    striped:true,
+    columns: [
+		{
+		    checkbox: true
+		},
+		{
+		    field: 'id',
+		    title: '序号',
+		    visible: true //隐藏
+		},
+		{
+		    field: 'parentId',
+		    visible: false, //隐藏
+		    title: '父id'
+		},
+		{
+		    field: 'companyName',
+		    title: '公司名称'
+		},
+		{
+		    field: 'status',
+		    title: '状态',
+		    formatter: function (value, row, index) {
+		        var actions = [];
+		        if(value==0){
+		        	 actions.push('<span class="label label-danger">关闭</span>');
+		        }else if(value==1){
+		        	 actions.push('<span class="label label-primary">开启</span>');
+		        }
+		      	return actions.join('');			    
+			}
+		},
+		{
+		    field: 'orderNum',
+		    title: '排序',
+		    sortable:true,//设置true为允许列可以排序
+			order: 'asc' //排序顺序
+		},
+		{
+		    title: '操作',
+		    formatter: function (value, row, index) {
+		        var id = row.id;
+		        var actions = [];
+		        if(row.id!=1){
+		        	actions.push('<a class="btn btn-success btn-xs"  href="#" onclick="edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
+			        actions.push('<a class="btn btn-danger btn-xs" href="#" onclick="remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>');
+		        }
+		        return actions.join('');
+		    }
+		}
+    ],
+    onAll: function(data) {
+        console.log("onAll");
+        return false;
+    },
+    onLoadSuccess: function(data) {
+        console.log("onLoadSuccess");
+        return false;
+    },
+    onLoadError: function(status) {
+        console.log("onLoadError");
+        return false;
+    },
+    onClickCell: function(field, value, row, $element) {
+        console.log("onClickCell",row);
+        return false;
+    },
+    onDblClickCell: function(field, value, row, $element) {
+        console.log("onDblClickCell",row);
+        return false;
+    },
+    onClickRow: function(row, $element) {
+        console.log("onClickRow",row);
+        return false;
+    },
+    onDblClickRow: function(row, $element) {
+        console.log("onDblClickRow",row);
+        return false;
+    }
+   
+});
+$("#selectBtn").click(function(){
+    var selecteds = $('#demo').bootstrapTreeTable('getSelections');
+    $.each(selecteds,function(_i,_item){
+        console.log(_item);
+    });
+    alert("看console");
+})
+
+var _expandFlag_all = false;
+$("#expandAllBtn").click(function(){
+    if(_expandFlag_all){
+        $('#demo').bootstrapTreeTable('expandAll');
+    }else{
+        $('#demo').bootstrapTreeTable('collapseAll');
+    }
+    _expandFlag_all = _expandFlag_all?false:true;
+})
+var _showFlag = true;
+$("#showColumnBtn").click(function(){
+    if(_showFlag){
+        $('#demo').bootstrapTreeTable('hideColumn',"orderNum");
+    }else{
+        $('#demo').bootstrapTreeTable('showColumn',"orderNum");
+    }
+    _showFlag = _showFlag?false:true;
+})
+$("#destroyBtn").click(function(){
+    $('#demo').bootstrapTreeTable('destroy');
+})
+
+
+</script>
+<script type="text/javascript">
+
+function add(){
+	$.modal.open("添加公司", createUrl);
+}
+
+function batRemove(){
+	
+	var rows = $('#demo').bootstrapTreeTable('getSelections');
+    if (rows.length == 0) {
+        $.modal.alertWarning("请至少选择一条记录");
+        return
+    }
+    $.modal.confirm("确认要删除选中的" + rows.length + "条数据吗?", function() {
+    	var rowid=[];
+    	for ( var i in rows) {
+    		rowid.push(rows[i].id);
+		}
+        var url = removeUrl;
+        var data = {
+            "ids": rowid.join()
+        };
+        $.operate.submit(url, "post", "json", data);
+    })
+}
+
+function edit(id){
+	 var url = updateUrl.replace("{id}", id);
+     $.modal.open("修改权限", url);
+}
+
+function remove(id){
+	
+	$.modal.confirm("确定删除该条权限信息吗?", function() {
+        var url = removeUrl.replace("{id}", id);
+        var data = {
+            "ids": id
+        };
+        $.operate.submit(url, "post", "json", data);
+    })
+}
+
+
+//重写刷新方法
+$.table.refresh=function() {
+	$('#demo').bootstrapTreeTable("refresh",{
+		url:dataUrl,
+		silent:true
+	});
+}
+</script>
+
+</body>
+
+
+</html>

+ 190 - 0
web/monitor-web-sxjn/src/main/resources/templates/admin/sysCompany/tree.html

@@ -0,0 +1,190 @@
+<!DOCTYPE html>
+<html xmlns:th="http://www.thymeleaf.org" 
+      xmlns:sec="http://www.pollix.at/thymeleaf/shiro">
+<head th:replace="admin/common/html/tableHead :: tableHead(~{::title},~{::link},~{::style})">
+<title th:text=${title}></title>
+<!-- 这儿引用单独的css link -->
+<!-- Ladda for Bootstrap 3按钮加载进度插件 -->
+<link rel="stylesheet" th:href="@{/static/admin/assets/js/button/ladda/ladda.min.css}">
+<!-- treeview -->
+<link th:href="@{/static/admin/assets/js/bootstrap/bootstrap-treeview/css/bootstrap-treeview.css}" rel="stylesheet"/>
+
+<style type="text/css">
+.content-wrap {
+     padding: 0px;
+}
+body {
+	 color: #9ea7b3;
+    font-family: "Open Sans", Arial, sans-serif!important;
+    font-size: 13px!important;
+    line-height: 20px;
+    overflow-x: hidden!important;
+    min-height: 100%;
+    z-index: -2;
+    margin: 0px !important;
+    background: url() no-repeat top center fixed;
+    -moz-background-size: cover;
+    -webkit-background-size: cover;
+    -o-background-size: cover;
+    background-size: cover;
+}
+label.error {
+    position: absolute;
+    right: 18px;
+    top: 5px;
+    color: #ef392b;
+    font-size: 12px;
+}
+</style>
+
+</head>
+<body>
+
+<div id="fcapp" class="content-wrap">
+	<div class="row">
+		<div class="col-sm-12">
+			<div class="nest" id="elementClose">
+				<div class="">
+				</div>
+				<div class="body-nest" id="element">
+					<div class="panel-body">
+						<form  class="form-horizontal m" id="form-add">
+							<div class="form-group">
+								<div class="col-sm-8">
+									<div id="tree"></div> 
+								</div>
+							</div>
+							<div class="form-group">
+								<div class="form-control-static col-sm-offset-9">
+									<button type="submit" class="btn btn-primary">提交</button>
+									<button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>
+								</div>
+							</div>
+						</form>
+					</div>
+				</div>
+			</div>
+		</div>
+	</div>
+</div>
+
+<!-- 通用js -->
+<div th:include="admin/common/html/js :: onload_js"></div>
+<!-- 弹窗 -->
+<script th:src="@{/static/admin/assets/js/layer/layer.js}" type="text/javascript"></script>
+<!-- 遮罩层 -->
+<script th:src="@{/static/admin/assets/js/blockUI/jquery.blockUI.js}" type="text/javascript"></script>
+<!--bootstarp threeView -->
+<script th:src="@{/static/admin/assets/js/bootstrap/bootstrap-treeview/js/bootstrap-treeview.js}" type="text/javascript"></script>
+<script th:src="@{/static/admin/assets/js/bootstrap/js/base_list.js}" type="text/javascript"></script>
+
+
+<script type="text/javascript">
+
+//添加方法
+function add() {
+	var dataFormJson=$("#form-add").serialize();
+	$.ajax({
+		cache : true,
+		type : "POST",
+		url : rootPath + "/SysCompanyController/add",
+		data :dataFormJson,
+		async : false,
+		error : function(request) {
+			$.modal.alertError("系统错误");
+		},
+		success : function(data) {
+			$.operate.saveSuccess(data);
+		}
+	});
+}
+
+
+/***权限配置***/
+
+function getTree() {
+	var tree = [];
+	$.ajax({
+		url: rootPath + "/SysCompanyController/tree/0",
+		type:"post",
+		async : false,
+		cache : true,
+		error : function(request) {
+			$.modal.alertError("系统错误");
+		},
+		success : function(data) {
+			if(!$.common.isEmpty(data)&&data.code==200){
+				tree.push(data.data);
+			}
+		}
+		
+		
+	})
+    return tree;
+}
+
+
+//赋值给父菜单
+function loadObj(data){
+	var treeId = data.id;
+	var treeName = data.text;
+	
+	if(treeId != "1") {
+		parent.$("#parentIdCom").val(treeId);
+		parent.$("#pidNameCom").val(treeName);
+		var index = parent.layer.getFrameIndex(window.name); // 获取窗口索引
+		parent.layer.close(index);
+	}
+	else {
+		$.modal.alertError("主菜单不能选择");
+	}
+	
+	
+
+}
+
+
+
+$(function() {
+	
+	$('#tree').treeview({
+		levels : 3,////设置初始化展开几级菜单 默认为2
+		//showCheckbox : 1,//这里之所以写1,是因为我引得js源码里定义1为true  checkbox
+		//multiSelect : 1,//这里之所以写1,是因为我引得js源码里定义1为true  多选
+		data : getTree(),
+		color : "#000000",//设置字体加载颜色
+		backColor : "#FFFFFF",//设置背景颜色
+		selectedColor : "#428bca",//设置选中的字体颜色
+		 highlightSelected:true,     //是否选中高亮显示
+		 onhoverColor: "#FF00FF",    //鼠标滑过的颜色
+		 showBorder:true,//是否显示边框
+		onNodeSelected : function(event, data) {//选中节点
+			// 事件代码...
+			console.log(data.id);
+			loadObj(data);
+		},
+		onNodeChecked : function(event, node) { //选中节点 
+			
+		},
+		nodeSelected (event, node){
+		},
+		nodeChecked (event, node){//一个节点被checkedc
+		},
+		onNodeUnchecked : function(event, node) { //取消选中节点  
+		}
+
+	});
+
+})
+
+
+
+
+
+</script>
+
+
+</body>
+
+
+</html>

+ 2 - 3
web/monitor-web-sxjn/src/main/resources/templates/admin/sysDepartment/list.html

@@ -199,9 +199,8 @@ var treeTable = $('#demo').bootstrapTreeTable({
 		        var id = row.id;
 		        var actions = [];
 		        if(row.id!=1){
-		        	actions.push('<a class="btn btn-success btn-xs"  href="#" onclick="edit(' + row.id + ')"><i class="fa fa-edit"></i>编辑</a> ');
-			        actions.push('<a class="btn btn-danger btn-xs" href="#" onclick="remove(' + row.id + ')"><i class="fa fa-remove"></i>删除</a>');
-		        }
+                    actions.push('<a class="btn btn-success btn-xs"  href="#" onclick="edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
+                    actions.push('<a class="btn btn-danger btn-xs" href="#" onclick="remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>');	        }
 		        return actions.join('');
 		    }
 		}

+ 12 - 1
web/monitor-web-sxjn/src/main/resources/templates/admin/user/add.html

@@ -45,7 +45,13 @@
 									<input class="form-control" type="text" id="nickname" name="nickname"/>
 								</div>
 							</div>
-							
+                            <div class="form-group">
+                                <label class="col-sm-3 control-label ">公司:</label>
+                                <div class="col-sm-8">
+                                    <input class="form-control" type="hidden" id="parentIdCom" name="comId"/>
+                                    <input class="form-control" readonly="true" type="text" id="pidNameCom" onclick="selectCompanyMenuTree()" />
+                                </div>
+                            </div>
 							<div class="form-group">
 								<label class="col-sm-3 control-label ">部门:</label>
 								<div class="col-sm-8">
@@ -116,6 +122,11 @@ function selectMenuTree() {
 	var url =  rootPath+ "/SysDepartmentController/tree";
 	$.modal.open("选择菜单", url, '380', '380');
 }
+
+function selectCompanyMenuTree() {
+    var url =  rootPath+ "/SysCompanyController/tree";
+    $.modal.open("选择菜单", url, '380', '380');
+}
 </script>
 
 </body>

+ 14 - 1
web/monitor-web-sxjn/src/main/resources/templates/admin/user/edit.html

@@ -42,7 +42,15 @@
 									<input class="form-control" type="text" id="nickname" name="nickname" th:value="*{nickname}"/>
 								</div>
 							</div>
-							
+
+                            <div class="form-group">
+                                <label class="col-sm-3 control-label ">公司:</label>
+                                <div class="col-sm-8">
+                                    <input class="form-control" type="hidden" id="parentIdCom" name="comId" th:value="*{comId}"/>
+                                    <input class="form-control" readonly="true" type="text" th:value="*{comName}" id="pidNameCom" onclick="selectCompanyMenuTree()" />
+                                </div>
+                            </div>
+
 							<div class="form-group">
 								<label class="col-sm-3 control-label ">部门:</label>
 								<div class="col-sm-8">
@@ -108,6 +116,11 @@ function selectMenuTree() {
 	var url =  rootPath+ "/SysDepartmentController/tree";
 	$.modal.open("选择菜单", url, '380', '380');
 }
+
+function selectCompanyMenuTree() {
+    var url =  rootPath+ "/SysCompanyController/tree";
+    $.modal.open("选择菜单", url, '380', '380');
+}
 </script>
 
 </body>

+ 4 - 0
web/monitor-web-sxjn/src/main/resources/templates/admin/user/list.html

@@ -163,6 +163,10 @@ var exportUrl=window.rootPath+"/UserController/export";
 			    field: 'username',
 			    title: '账号'
 			},
+           {
+               field: 'comName',
+               title: '公司名称'
+           },
 			{
 			    field: 'depName',
 			    title: '部门名称'

+ 11 - 1
web/monitor-web-sxjn/src/main/resources/templates/admin/uservue/add.html

@@ -45,7 +45,13 @@
 									<input class="form-control" type="text" id="nickname" name="nickname"/>
 								</div>
 							</div>
-							
+                            <div class="form-group">
+                                <label class="col-sm-3 control-label ">公司:</label>
+                                <div class="col-sm-8">
+                                    <input class="form-control" type="hidden" id="parentIdCom" name="comId"/>
+                                    <input class="form-control" readonly="true" type="text" id="pidNameCom" onclick="selectCompanyMenuTree()" />
+                                </div>
+                            </div>
 							<div class="form-group">
 								<label class="col-sm-3 control-label ">部门:</label>
 								<div class="col-sm-8">
@@ -116,6 +122,10 @@ function selectMenuTree() {
 	var url =  rootPath+ "/SysDepartmentController/tree";
 	$.modal.open("选择菜单", url, '380', '380');
 }
+function selectCompanyMenuTree() {
+    var url =  rootPath+ "/SysCompanyController/tree";
+    $.modal.open("选择菜单", url, '380', '380');
+}
 </script>
 
 </body>

+ 13 - 1
web/monitor-web-sxjn/src/main/resources/templates/admin/uservue/edit.html

@@ -42,7 +42,15 @@
 									<input class="form-control" type="text" id="nickname" name="nickname" th:value="*{nickname}"/>
 								</div>
 							</div>
-							
+
+                            <div class="form-group">
+                                <label class="col-sm-3 control-label ">公司:</label>
+                                <div class="col-sm-8">
+                                    <input class="form-control" type="hidden" id="parentIdCom" name="comId" th:value="*{comId}"/>
+                                    <input class="form-control" readonly="true" type="text" th:value="*{comName}" id="pidNameCom" onclick="selectCompanyMenuTree()" />
+                                </div>
+                            </div>
+
 							<div class="form-group">
 								<label class="col-sm-3 control-label ">部门:</label>
 								<div class="col-sm-8">
@@ -108,6 +116,10 @@ function selectMenuTree() {
 	var url =  rootPath+ "/SysDepartmentController/tree";
 	$.modal.open("选择菜单", url, '380', '380');
 }
+function selectCompanyMenuTree() {
+    var url =  rootPath+ "/SysCompanyController/tree";
+    $.modal.open("选择菜单", url, '380', '380');
+}
 </script>
 
 </body>

+ 4 - 0
web/monitor-web-sxjn/src/main/resources/templates/admin/uservue/list.html

@@ -163,6 +163,10 @@ var exportUrl=window.rootPath+"/UserVueController/export";
 			    field: 'username',
 			    title: '账号'
 			},
+           {
+               field: 'comName',
+               title: '公司名称'
+           },
 			{
 			    field: 'depName',
 			    title: '部门名称'