Browse Source

后台管理修改

shilin 2 years ago
parent
commit
6089a8bf0c

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

@@ -5,12 +5,10 @@ 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.*;
-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.model.custom.*;
 import com.gyee.frame.service.SysDepartmentService;
 import com.gyee.frame.service.SysPositionService;
+import com.gyee.frame.service.SysWindpowerstationService;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import org.apache.shiro.authz.annotation.RequiresPermissions;
@@ -40,7 +38,10 @@ public class UserVueController extends BaseController{
 	//岗位
 	@Resource
 	private SysPositionService positionService;
-	
+
+    //岗位
+    @Resource
+    private SysWindpowerstationService sysWindpowerstationService;
 	/**
 	 * 展示跳转页面
 	 * @param model
@@ -94,6 +95,10 @@ public class UserVueController extends BaseController{
 		List<SysDepartment> departments=departmentService.selectByExample(new SysDepartmentExample());
 		//岗位列表
 		List<SysPosition> sysPositions=positionService.selectByExample(new SysPositionExample());
+		//场站列表
+        List<SysWindpowerstation>  wpls=sysWindpowerstationService.queryList();
+        //场站
+        modelMap.put("wpls",wpls);
 		//角色
 		modelMap.put("tsysRoleList",tsysRoleList);
 		//部门
@@ -116,8 +121,10 @@ public class UserVueController extends BaseController{
 	@PostMapping("/add")
 	@RequiresPermissions("system:uservue:add")
 	@ResponseBody
-	public AjaxResult add(TvueUser uservue,Model model,@RequestParam(value="roles", required = false)List<String> roles){
-		int b=vueUserService.insertUserVueRoles(uservue,roles);
+	public AjaxResult add(TvueUser uservue,Model model,
+                          @RequestParam(value="roles", required = false)List<String> roles,
+                            @RequestParam(value="wpls", required = false)List<String> wpls){
+		int b=vueUserService.insertUserVueRoles(uservue,roles,wpls);
 		if(b>0){
 			return success();
 		}else{
@@ -178,6 +185,9 @@ public class UserVueController extends BaseController{
 		List<SysPosition> sysPositions=positionService.selectByExample(new SysPositionExample());
 		mmap.put("roleVos",roleVos);
         mmap.put("TvueUser", vueUserService.selectByPrimaryKey(id));
+        //场站列表
+        List<WpVo>  wpls=sysWindpowerstationService.getUserVueIsWp(id);
+        mmap.put("wpls",wpls);
         //岗位
         mmap.put("sysPositionsList",sysPositions);
         return prefix + "/edit";
@@ -191,9 +201,11 @@ public class UserVueController extends BaseController{
     @RequiresPermissions("system:uservue:edit")
     @PostMapping("/edit")
     @ResponseBody
-    public AjaxResult editSave(TvueUser tsysUserVue,@RequestParam(value="roles", required = false)List<String> roles)
+    public AjaxResult editSave(TvueUser tsysUserVue,
+                               @RequestParam(value="roles", required = false)List<String> roles,
+                               @RequestParam(value="wpls", required = false)List<String> wpls)
     {
-        return toAjax(vueUserService.updateUserVueRoles(tsysUserVue,roles));
+        return toAjax(vueUserService.updateUserVueRoles(tsysUserVue,roles,wpls));
     }
 
     

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

@@ -0,0 +1,64 @@
+package com.gyee.frame.mapper.auto;
+
+import com.gyee.frame.model.auto.TvueWpUser;
+import com.gyee.frame.model.auto.TvueWpUserExample;
+import java.util.List;
+import org.apache.ibatis.annotations.Param;
+
+public interface TvueWpUserMapper {
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    long countByExample(TvueWpUserExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    int deleteByExample(TvueWpUserExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    int insert(TvueWpUser record);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    int insertSelective(TvueWpUser record);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    List<TvueWpUser> selectByExample(TvueWpUserExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    int updateByExampleSelective(@Param("record") TvueWpUser record, @Param("example") TvueWpUserExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    int updateByExample(@Param("record") TvueWpUser record, @Param("example") TvueWpUserExample example);
+}

+ 4 - 0
web/monitor-web-sxjn/src/main/java/com/gyee/frame/mapper/custom/TvueUserDao.java

@@ -1,6 +1,7 @@
 package com.gyee.frame.mapper.custom;
 
 
+import com.gyee.frame.model.auto.SysWindpowerstation;
 import com.gyee.frame.model.auto.TvueUser;
 
 import java.util.List;
@@ -27,4 +28,7 @@ public interface TvueUserDao {
 	 * @Date 2020年12月6日 下午9:02:20
 	 */
 	public List<TvueUser> queryVueUserInfo(String username);
+
+
+    public List<SysWindpowerstation> queryUserWp(String userid);
 }

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

@@ -264,4 +264,6 @@ public class TvueUser implements Serializable {
         this.posId = posId;
         this.comId = comId;
     }
+
+
 }

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

@@ -0,0 +1,124 @@
+package com.gyee.frame.model.auto;
+
+import java.io.Serializable;
+
+public class TvueWpUser implements Serializable {
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column t_vue_wp_user.id
+     *
+     * @mbg.generated
+     */
+    private String id;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column t_vue_wp_user.sys_user_id
+     *
+     * @mbg.generated
+     */
+    private String sysUserId;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column t_vue_wp_user.sys_wp_id
+     *
+     * @mbg.generated
+     */
+    private String sysWpId;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column t_vue_wp_user.id
+     *
+     * @return the value of t_vue_wp_user.id
+     *
+     * @mbg.generated
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column t_vue_wp_user.id
+     *
+     * @param id the value for t_vue_wp_user.id
+     *
+     * @mbg.generated
+     */
+    public void setId(String id) {
+        this.id = id == null ? null : id.trim();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column t_vue_wp_user.sys_user_id
+     *
+     * @return the value of t_vue_wp_user.sys_user_id
+     *
+     * @mbg.generated
+     */
+    public String getSysUserId() {
+        return sysUserId;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column t_vue_wp_user.sys_user_id
+     *
+     * @param sysUserId the value for t_vue_wp_user.sys_user_id
+     *
+     * @mbg.generated
+     */
+    public void setSysUserId(String sysUserId) {
+        this.sysUserId = sysUserId == null ? null : sysUserId.trim();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column t_vue_wp_user.sys_wp_id
+     *
+     * @return the value of t_vue_wp_user.sys_wp_id
+     *
+     * @mbg.generated
+     */
+    public String getSysWpId() {
+        return sysWpId;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column t_vue_wp_user.sys_wp_id
+     *
+     * @param sysWpId the value for t_vue_wp_user.sys_wp_id
+     *
+     * @mbg.generated
+     */
+    public void setSysWpId(String sysWpId) {
+        this.sysWpId = sysWpId == null ? null : sysWpId.trim();
+    }
+
+    public TvueWpUser(String id, String sysUserId, String sysWpId) {
+        this.id = id;
+        this.sysUserId = sysUserId;
+        this.sysWpId = sysWpId;
+    }
+
+    public TvueWpUser() {
+        this.id = id;
+        this.sysUserId = sysUserId;
+        this.sysWpId = sysWpId;
+    }
+}

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

@@ -0,0 +1,512 @@
+package com.gyee.frame.model.auto;
+
+import java.util.ArrayList;
+import java.util.List;
+
+public class TvueWpUserExample {
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    protected String orderByClause;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    protected boolean distinct;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    protected List<Criteria> oredCriteria;
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    public TvueWpUserExample() {
+        oredCriteria = new ArrayList<Criteria>();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @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_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    public String getOrderByClause() {
+        return orderByClause;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @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_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    public boolean isDistinct() {
+        return distinct;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @mbg.generated
+     */
+    public List<Criteria> getOredCriteria() {
+        return oredCriteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table t_vue_wp_user
+     *
+     * @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_vue_wp_user
+     *
+     * @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_vue_wp_user
+     *
+     * @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_vue_wp_user
+     *
+     * @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_vue_wp_user
+     *
+     * @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_vue_wp_user
+     *
+     * @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 andIdLike(String value) {
+            addCriterion("id like", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotLike(String value) {
+            addCriterion("id not like", 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 andSysUserIdIsNull() {
+            addCriterion("sys_user_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdIsNotNull() {
+            addCriterion("sys_user_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdEqualTo(String value) {
+            addCriterion("sys_user_id =", value, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdNotEqualTo(String value) {
+            addCriterion("sys_user_id <>", value, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdGreaterThan(String value) {
+            addCriterion("sys_user_id >", value, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdGreaterThanOrEqualTo(String value) {
+            addCriterion("sys_user_id >=", value, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdLessThan(String value) {
+            addCriterion("sys_user_id <", value, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdLessThanOrEqualTo(String value) {
+            addCriterion("sys_user_id <=", value, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdLike(String value) {
+            addCriterion("sys_user_id like", value, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdNotLike(String value) {
+            addCriterion("sys_user_id not like", value, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdIn(List<String> values) {
+            addCriterion("sys_user_id in", values, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdNotIn(List<String> values) {
+            addCriterion("sys_user_id not in", values, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdBetween(String value1, String value2) {
+            addCriterion("sys_user_id between", value1, value2, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysUserIdNotBetween(String value1, String value2) {
+            addCriterion("sys_user_id not between", value1, value2, "sysUserId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdIsNull() {
+            addCriterion("sys_wp_id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdIsNotNull() {
+            addCriterion("sys_wp_id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdEqualTo(String value) {
+            addCriterion("sys_wp_id =", value, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdNotEqualTo(String value) {
+            addCriterion("sys_wp_id <>", value, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdGreaterThan(String value) {
+            addCriterion("sys_wp_id >", value, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdGreaterThanOrEqualTo(String value) {
+            addCriterion("sys_wp_id >=", value, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdLessThan(String value) {
+            addCriterion("sys_wp_id <", value, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdLessThanOrEqualTo(String value) {
+            addCriterion("sys_wp_id <=", value, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdLike(String value) {
+            addCriterion("sys_wp_id like", value, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdNotLike(String value) {
+            addCriterion("sys_wp_id not like", value, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdIn(List<String> values) {
+            addCriterion("sys_wp_id in", values, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdNotIn(List<String> values) {
+            addCriterion("sys_wp_id not in", values, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdBetween(String value1, String value2) {
+            addCriterion("sys_wp_id between", value1, value2, "sysWpId");
+            return (Criteria) this;
+        }
+
+        public Criteria andSysWpIdNotBetween(String value1, String value2) {
+            addCriterion("sys_wp_id not between", value1, value2, "sysWpId");
+            return (Criteria) this;
+        }
+    }
+
+    /**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table t_vue_wp_user
+     *
+     * @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_vue_wp_user
+     *
+     * @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);
+        }
+    }
+}

+ 29 - 0
web/monitor-web-sxjn/src/main/java/com/gyee/frame/model/custom/WpVo.java

@@ -0,0 +1,29 @@
+package com.gyee.frame.model.custom;
+
+import com.gyee.frame.model.auto.TsysRole;
+
+/**
+ * 角色自定义数据
+ * @author gyee
+ * @date: 2018年9月8日 上午12:18:59
+ */
+public class WpVo extends TsysRole{
+	private static final long serialVersionUID = 1L;
+	private boolean ischeck;//判断是否又这个权限
+
+	public boolean isIscheck() {
+		return ischeck;
+	}
+	public void setIscheck(boolean ischeck) {
+		this.ischeck = ischeck;
+	}
+
+	public WpVo() {
+		super();
+	}
+	public WpVo(String id, String name, Boolean ischeck) {
+		super(id, name);
+		this.ischeck=ischeck;
+	}
+	
+}

+ 49 - 2
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/SysWindpowerstationService.java

@@ -6,10 +6,12 @@ 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.SysWindpowerstationMapper;
+import com.gyee.frame.mapper.custom.TvueUserDao;
 import com.gyee.frame.model.auto.SysWindpowerstation;
 import com.gyee.frame.model.auto.SysWindpowerstationExample;
 import com.gyee.frame.model.custom.BootstrapTree;
 import com.gyee.frame.model.custom.Tablepar;
+import com.gyee.frame.model.custom.WpVo;
 import com.gyee.frame.util.SnowflakeIdWorker;
 import com.gyee.frame.util.StringUtils;
 import org.springframework.stereotype.Service;
@@ -32,7 +34,8 @@ import java.util.List;
 public class SysWindpowerstationService implements BaseService<SysWindpowerstation, SysWindpowerstationExample> {
 	@Resource
 	private SysWindpowerstationMapper sysWindpowerstationMapper;
-
+    @Resource
+    private TvueUserDao tvueUserDao;
 
 	public PageInfo<SysWindpowerstation> list(Tablepar tablepar, String name) {
 		SysWindpowerstationExample testExample = new SysWindpowerstationExample();
@@ -191,6 +194,50 @@ public class SysWindpowerstationService implements BaseService<SysWindpowerstati
     }
 
 
+    public List<SysWindpowerstation> queryUserWp(String userid)
+    {
+        List<SysWindpowerstation> ls=new ArrayList<>();
+        if(StringUtils.notEmp(userid))
+        {
+            ls=tvueUserDao.queryUserWp(userid);
+        }
+        return ls;
+        
+    }
+    public List<SysWindpowerstation> queryList(){
+        SysWindpowerstationExample sysWindpowerstationExample=new SysWindpowerstationExample();
+        return sysWindpowerstationMapper.selectByExample(sysWindpowerstationExample);
+    }
 
-	
+    /**
+     * 获取所有权限 并且增加是否有权限字段
+     * @return
+     */
+    public List<WpVo> getUserVueIsWp(String userid){
+        List<WpVo> list=new ArrayList<WpVo>();
+        //查询出我的权限
+        List<SysWindpowerstation> myWpls= tvueUserDao.queryUserWp(userid);
+        SysWindpowerstationExample sysWindpowerstationExample=new SysWindpowerstationExample();
+        //查询系统所有的角色
+        List<SysWindpowerstation> wpls=sysWindpowerstationMapper.selectByExample(sysWindpowerstationExample);
+        if(StringUtils.isNotEmpty(wpls)){
+            for (SysWindpowerstation wp : wpls) {
+                Boolean isflag=false;
+                WpVo roleVo=new WpVo(wp.getId(),wp.getName(), isflag);
+                for (SysWindpowerstation mywp : myWpls) {
+                    if(wp.getId().equals(mywp.getId())){
+                        isflag=true;
+                        break;
+                    }
+                }
+                if(isflag){
+                    roleVo.setIscheck(true);
+                    list.add(roleVo);
+                }else{
+                    list.add(roleVo);
+                }
+            }
+        }
+        return list;
+    }
 }

+ 27 - 7
web/monitor-web-sxjn/src/main/java/com/gyee/frame/service/VueUserService.java

@@ -4,9 +4,7 @@ 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.TvueRoleUserMapper;
-import com.gyee.frame.mapper.auto.TvueRoleMapper;
-import com.gyee.frame.mapper.auto.TvueUserMapper;
+import com.gyee.frame.mapper.auto.*;
 import com.gyee.frame.mapper.custom.RoleVueDao;
 import com.gyee.frame.mapper.custom.TvueUserDao;
 import com.gyee.frame.model.auto.*;
@@ -50,7 +48,11 @@ public class VueUserService implements BaseService<TvueUser, TvueUserExample>{
 	//自定义用户dao
 	@Resource
 	private TvueUserDao tvueUserDao ;
-	
+
+
+    @Resource
+    private TvueWpUserMapper tvueWpUserMapper;
+
 	/**
 	 * 分页查询
 	 * @return
@@ -96,7 +98,7 @@ public class VueUserService implements BaseService<TvueUser, TvueUserExample>{
 	 * @return
 	 */
 	@Transactional
-	public int insertUserVueRoles(TvueUser record,List<String> roles) {
+	public int insertUserVueRoles(TvueUser record,List<String> roles,List<String> wpls) {
 		String userid=SnowflakeIdWorker.getUUID();
 		record.setId(userid);
 		if(StringUtils.isNotEmpty(roles)){
@@ -105,7 +107,13 @@ public class VueUserService implements BaseService<TvueUser, TvueUserExample>{
 				 tvueRoleUserMapper.insertSelective(roleUser);
 			}
 		}
-		
+        if(StringUtils.isNotEmpty(wpls)){
+            for (String wpid : wpls) {
+                TvueWpUser wpUser=new TvueWpUser(SnowflakeIdWorker.getUUID(), userid,wpid);
+                tvueWpUserMapper.insertSelective(wpUser);
+            }
+        }
+
 		//密码加密
 		record.setPassword(MD5Util.encode(record.getPassword()));
 		return tvueUserMapper.insertSelective(record);
@@ -226,7 +234,7 @@ public class VueUserService implements BaseService<TvueUser, TvueUserExample>{
 	 * @return
 	 */
 	@Transactional
-	public int updateUserVueRoles(TvueUser record,List<String> roles) {
+	public int updateUserVueRoles(TvueUser record,List<String> roles,List<String> wpls) {
 		
 		
 		
@@ -234,6 +242,11 @@ public class VueUserService implements BaseService<TvueUser, TvueUserExample>{
 		TvueRoleUserExample tVueRoleUserExample=new TvueRoleUserExample();
 		tVueRoleUserExample.createCriteria().andSysUserIdEqualTo(record.getId());
 		tvueRoleUserMapper.deleteByExample(tVueRoleUserExample);
+
+
+        TvueWpUserExample tvueWpUserExample=new TvueWpUserExample();
+        tvueWpUserExample.createCriteria().andSysUserIdEqualTo(record.getId());
+        tvueWpUserMapper.deleteByExample(tvueWpUserExample);
 		if(roles!=null) {
 			//添加新的角色信息
 			for (String role : roles) {
@@ -241,6 +254,13 @@ public class VueUserService implements BaseService<TvueUser, TvueUserExample>{
 				tvueRoleUserMapper.insertSelective(tVueRoleUser);
 			}
 		}
+
+        if(StringUtils.isNotEmpty(wpls)){
+            for (String wpid : wpls) {
+                TvueWpUser wpUser=new TvueWpUser(SnowflakeIdWorker.getUUID(), record.getId(),wpid);
+                tvueWpUserMapper.insertSelective(wpUser);
+            }
+        }
 		//修改用户信息
 		return tvueUserMapper.updateByPrimaryKeySelective(record);
 	}

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

@@ -125,7 +125,7 @@
 <!--        <table tableName='StopAnalysismainVo' domainObjectName='StopAnalysismainVo'/>-->
 
 
-        <table tableName='t_sys_user' domainObjectName='TsysUser'/>
+        <table tableName='t_vue_wp_user' domainObjectName='TvueWpUser'/>
 
 
     </context>

+ 19 - 13
web/monitor-web-sxjn/src/main/resources/mybatis/auto/TvueUserMapper.xml

@@ -6,13 +6,16 @@
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
     -->
-    <id column="ID" jdbcType="VARCHAR" property="id" />
-    <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="DECIMAL" property="depId" />
-    <result column="POS_ID" jdbcType="VARCHAR" property="posId" />
+      <id column="ID" jdbcType="VARCHAR" property="id" />
+      <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="VARCHAR" property="depId" />
+      <result column="POS_ID" jdbcType="VARCHAR" property="posId" />
       <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>
   <sql id="Example_Where_Clause">
     <!--
@@ -110,10 +113,13 @@
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
     -->
-    select 
-    <include refid="Base_Column_List" />
-    from T_VUE_USER
-    where ID = #{id,jdbcType=VARCHAR}
+      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.com_id) as com_name,
+      (select post_name from t_sys_position pos where pos.id=tsu.pos_id) as pos_name
+      from T_VUE_USER tsu
+      where id = #{id,jdbcType=VARCHAR}
   </select>
   <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
     <!--
@@ -170,9 +176,9 @@
       <if test="posId != null">
         POS_ID,
       </if>
-        <if test="posId != null">
-            COM_ID,
-        </if>
+      <if test="comId != null">
+        COM_ID
+      </if>
     </trim>
     <trim prefix="values (" suffix=")" suffixOverrides=",">
       <if test="id != null">

+ 197 - 0
web/monitor-web-sxjn/src/main/resources/mybatis/auto/TvueWpUserMapper.xml

@@ -0,0 +1,197 @@
+<?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.TvueWpUserMapper">
+  <resultMap id="BaseResultMap" type="com.gyee.frame.model.auto.TvueWpUser">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    <result column="id" jdbcType="VARCHAR" property="id" />
+    <result column="sys_user_id" jdbcType="VARCHAR" property="sysUserId" />
+    <result column="sys_wp_id" jdbcType="VARCHAR" property="sysWpId" />
+  </resultMap>
+  <sql id="Example_Where_Clause">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    <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">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    <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">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    id, sys_user_id, sys_wp_id
+  </sql>
+  <select id="selectByExample" parameterType="com.gyee.frame.model.auto.TvueWpUserExample" resultMap="BaseResultMap">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from t_vue_wp_user
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+  </select>
+  <delete id="deleteByExample" parameterType="com.gyee.frame.model.auto.TvueWpUserExample">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    delete from t_vue_wp_user
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.gyee.frame.model.auto.TvueWpUser">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    insert into t_vue_wp_user (id, sys_user_id, sys_wp_id
+      )
+    values (#{id,jdbcType=VARCHAR}, #{sysUserId,jdbcType=VARCHAR}, #{sysWpId,jdbcType=VARCHAR}
+      )
+  </insert>
+  <insert id="insertSelective" parameterType="com.gyee.frame.model.auto.TvueWpUser">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    insert into t_vue_wp_user
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        id,
+      </if>
+      <if test="sysUserId != null">
+        sys_user_id,
+      </if>
+      <if test="sysWpId != null">
+        sys_wp_id,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=VARCHAR},
+      </if>
+      <if test="sysUserId != null">
+        #{sysUserId,jdbcType=VARCHAR},
+      </if>
+      <if test="sysWpId != null">
+        #{sysWpId,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.gyee.frame.model.auto.TvueWpUserExample" resultType="java.lang.Long">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    select count(*) from t_vue_wp_user
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </select>
+  <update id="updateByExampleSelective" parameterType="map">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    update t_vue_wp_user
+    <set>
+      <if test="record.id != null">
+        id = #{record.id,jdbcType=VARCHAR},
+      </if>
+      <if test="record.sysUserId != null">
+        sys_user_id = #{record.sysUserId,jdbcType=VARCHAR},
+      </if>
+      <if test="record.sysWpId != null">
+        sys_wp_id = #{record.sysWpId,jdbcType=VARCHAR},
+      </if>
+    </set>
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExample" parameterType="map">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+    -->
+    update t_vue_wp_user
+    set id = #{record.id,jdbcType=VARCHAR},
+      sys_user_id = #{record.sysUserId,jdbcType=VARCHAR},
+      sys_wp_id = #{record.sysWpId,jdbcType=VARCHAR}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+</mapper>

+ 2 - 0
web/monitor-web-sxjn/src/main/resources/mybatis/custom/TvueRoleMapper.xml

@@ -14,4 +14,6 @@
 		LEFT JOIN t_vue_role_user ru ON  r.id=ru.sys_role_id
 		where ru.sys_user_id=#{userid}
  </select>
+
+
 </mapper>

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

@@ -32,8 +32,12 @@
     </if>
 	order by id DESC
   </select>
- 
- 
+
+    <select id="queryUserWp" parameterType="String" resultType="com.gyee.frame.model.auto.SysWindpowerstation">
+        select r.id,r.name  from t_sys_windpowerstation r
+		LEFT JOIN t_vue_wp_user ru ON  r.id=ru.sys_wp_id
+		where ru.sys_user_id=#{userid}
+ </select>
  
  
  

+ 30 - 5
web/monitor-web-sxjn/src/main/resources/templates/admin/uservue/add.html

@@ -45,11 +45,36 @@
 									<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="parentIdcm" name="comId"/>-->
+<!--                                    <input class="form-control" readonly="true" type="text" id="parentnamecm" onclick="selectCompanyMenuTree()" />-->
+<!--                                </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="hidden" id="parentIdcm" name="comId"/>
-                                    <input class="form-control" readonly="true" type="text" id="parentnamecm" onclick="selectCompanyMenuTree()" />
+
+                                    <div class="">
+
+                                        <table border="0" th:with="colSize=${4}, rowSize=${wpls.size()/colSize}, rowSize=${(wpls.size()%colSize==0 ? rowSize : (rowSize+1))}">
+                                            <!--遍历行数,rowIdx为行号,每一行是一个tr标签对 -->
+                                            <tr th:if="${wpls.size() gt 0}" th:each="rowIdx:${#numbers.sequence(1, rowSize)}">
+                                                <!--遍历列数,colIdx为列号,每一列是一个td标签对 -->
+                                                <td th:each="colIdx:${#numbers.sequence(1,colSize)}" width="150px">
+                                                    <!-- 根据行号和列号计算数组的下标索引号idx ,然后通过idx从userList中取出一个元素user
+                                                    由于最后一行的数据可能没有满行(userList.size()%colSize!=0的情况),因此需要做数组越界判断, -->
+                                                    <!-- th:block 功能标签,标签本身不会输出为一个html元素,此处只是用来配合 th:with -->
+                                                    <th:block th:with="idx=${(rowIdx-1)*colSize+colIdx-1}, user=${idx<wpls.size() ? wpls[idx] : null}">
+                                                        <!-- th:if 决定是否输出 input 标签:user不是空指针才输出 -->
+                                                        <input th:if="${user ne null}" th:id="${user.id}" class="sqcheckbox" name="wpls" type="checkbox" th:value="${user.id}" th:text="${user.name}"/>
+                                                    </th:block>
+                                                </td>
+                                            </tr>
+                                        </table>
+                                    </div>
+
                                 </div>
                             </div>
 							<div class="form-group">
@@ -59,8 +84,8 @@
 									<input class="form-control" readonly="true" type="text" id="parentnamedep" onclick="selectMenuTree()" />
 								</div>
 							</div>
-							
-							
+
+
 							<div class="form-group">
 								<label class="col-sm-3 control-label ">岗位:</label>
 								<div class="col-sm-8">

+ 29 - 5
web/monitor-web-sxjn/src/main/resources/templates/admin/uservue/edit.html

@@ -43,19 +43,43 @@
 								</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="parentIdcm" name="comId" th:value="*{comId}"/>-->
+<!--                                    <input class="form-control" readonly="true" type="text" th:value="*{comName}" id="parentnamecm" onclick="selectCompanyMenuTree()" />-->
+<!--                                </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="hidden" id="parentIdcm" name="comId" th:value="*{comId}"/>
-                                    <input class="form-control" readonly="true" type="text" th:value="*{comName}" id="parentnamecm" onclick="selectCompanyMenuTree()" />
+
+                                    <div class="">
+
+                                        <table border="0" th:with="colSize=${4}, rowSize=${wpls.size()/colSize}, rowSize=${(wpls.size()%colSize==0 ? rowSize : (rowSize+1))}">
+                                            <!--遍历行数,rowIdx为行号,每一行是一个tr标签对 -->
+                                            <tr th:if="${wpls.size() gt 0}" th:each="rowIdx:${#numbers.sequence(1, rowSize)}">
+                                                <!--遍历列数,colIdx为列号,每一列是一个td标签对 -->
+                                                <td th:each="colIdx:${#numbers.sequence(1,colSize)}" width="150px">
+                                                    <!-- 根据行号和列号计算数组的下标索引号idx ,然后通过idx从userList中取出一个元素user
+                                                    由于最后一行的数据可能没有满行(userList.size()%colSize!=0的情况),因此需要做数组越界判断, -->
+                                                    <!-- th:block 功能标签,标签本身不会输出为一个html元素,此处只是用来配合 th:with -->
+                                                    <th:block th:with="idx=${(rowIdx-1)*colSize+colIdx-1}, user=${idx<wpls.size() ? wpls[idx] : null}">
+                                                        <!-- th:if 决定是否输出 input 标签:user不是空指针才输出 -->
+                                                        <input th:if="${user ne null}" th:id="${user.id}" class="sqcheckbox" name="wpls" type="checkbox" th:value="${user.id}" th:text="${user.name}" th:checked="${user.ischeck}"/>
+                                                    </th:block>
+                                                </td>
+                                            </tr>
+                                        </table>
+                                    </div>
+
                                 </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="parentId" name="parentIddep" th:value="*{depId}"/>
-									<input class="form-control" readonly="true" type="text" th:value="*{depName}" id="parentnamedep" onclick="selectMenuTree()" />
+									<input class="form-control" readonly="true" type="text" th:value="*{depName}" id="parentnamedep"  name="depName" onclick="selectMenuTree()" />
 								</div>
 							</div>