master
wangh 1 year ago
parent 38d80b803c
commit 4fc3e50675

@ -1,3 +1,5 @@
**管理端代码haiwei-manage**
**管理端代码存放路径**
haiwei-manage
**返回看板地址Contreller:haiwei-admin**
Contrellercom.haiwei.web.controller.broad.BroadContreller
****

@ -0,0 +1,44 @@
package com.haiwei.web.controller.broad;
import com.haiwei.common.core.domain.AjaxResult;
import static com.haiwei.common.core.domain.AjaxResult.*;
import com.haiwei.manage.service.IBaseCustomerService;
import com.haiwei.manage.service.IBaseDeviceInfoService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.models.Tag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* @author wanghao
* @date 2023/8/14 14:02
*/
@RestController
public class ApiController {
@Autowired
private IBaseDeviceInfoService baseDeviceInfoService;//设备
@Autowired
private IBaseCustomerService baseCustomerService;//客户
@ApiOperation(tags = {"首页"}, value = "获取客户展示")
@GetMapping("/home/queryCustomer")
public AjaxResult queryCustomer(){
return success(baseCustomerService.selectBaseCustomerList(null));
}
@ApiOperation(tags = {"首页"}, value = "获取产品列表")
@GetMapping("/home/queryDevice")
public AjaxResult queryDevice(){
return success(baseDeviceInfoService.selectBaseDeviceInfoList(null));
}
}

@ -7,6 +7,6 @@ import org.springframework.stereotype.Controller;
* @date 2023/8/14 10:18
*/
@Controller
public class BroadContreller {
public class BroadController {
}

@ -1,17 +1,20 @@
package com.haiwei.web.core.config;
import com.google.common.collect.Ordering;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import com.haiwei.common.config.Global;
import io.swagger.annotations.ApiOperation;
import springfox.documentation.builders.ApiInfoBuilder;
import springfox.documentation.builders.PathSelectors;
import springfox.documentation.builders.RequestHandlerSelectors;
import springfox.documentation.service.ApiInfo;
import springfox.documentation.service.Contact;
import springfox.documentation.service.Operation;
import springfox.documentation.spi.DocumentationType;
import springfox.documentation.spring.web.plugins.Docket;
import springfox.documentation.swagger.web.OperationsSorter;
import springfox.documentation.swagger.web.UiConfiguration;
import springfox.documentation.swagger.web.UiConfigurationBuilder;
import springfox.documentation.swagger2.annotations.EnableSwagger2;
/**
@ -41,14 +44,27 @@ public class SwaggerConfig
// 设置哪些接口暴露给Swagger展示
.select()
// 扫描所有有注解的api用这种方式更灵活
.apis(RequestHandlerSelectors.withMethodAnnotation(ApiOperation.class))
// .apis(RequestHandlerSelectors.withMethodAnnotation(ApiOperation.class))
// 扫描指定包中的swagger注解
//.apis(RequestHandlerSelectors.basePackage("com.haiwei.project.tool.swagger"))
.apis(RequestHandlerSelectors.basePackage("com.haiwei.web.controller.broad"))
// 扫描所有 .apis(RequestHandlerSelectors.any())
.paths(PathSelectors.any())
.build();
.build()
// .operationOrdering(new Ordering<Operation>() {
// @Override
// public int compare(Operation left, Operation right) {
// return left.getMethod().name().compareTo(right.getMethod().name());
// }
// })
;
}
// @Bean
// public UiConfiguration uiConfig() {
// return UiConfigurationBuilder
// .builder()
// .operationsSorter(OperationsSorter.ALPHA)
// .build();
// }
/**
*
*/
@ -57,11 +73,11 @@ public class SwaggerConfig
// 用ApiInfoBuilder进行定制
return new ApiInfoBuilder()
// 设置标题
.title("标题若依管理系统_接口文档")
.title("接口文档")
// 描述
.description("描述:用于管理集团旗下公司的人员信息,具体包括XXX,XXX模块...")
// .description("描述:用于管理集团旗下公司的人员信息,具体包括XXX,XXX模块...")
// 作者信息
.contact(new Contact(Global.getName(), null, null))
// .contact(new Contact(Global.getName(), null, null))
// 版本
.version("版本号:" + Global.getVersion())
.build();

@ -69,7 +69,7 @@ spring:
devtools:
restart:
# 热部署开关
enabled: true
enabled: false
# MyBatis
mybatis:
@ -97,7 +97,7 @@ shiro:
# 首页地址
indexUrl: /index
# 验证码开关
captchaEnabled: true
captchaEnabled: false
# 验证码类型 math 数组计算 char 字符
captchaType: math
cookie:
@ -126,7 +126,7 @@ shiro:
# 防止XSS攻击
xss:
# 过滤开关
enabled: true
enabled: false
# 排除链接(多个用逗号分隔)
excludes: /system/notice/*
# 匹配链接

@ -1 +1,174 @@
html{height:100%}body.signin{height:auto;background:url(../img/login-background.jpg) no-repeat center fixed;-webkit-background-size:cover;-moz-background-size:cover;-o-background-size:cover;background-size:cover;color:rgba(255,255,255,.95)}.signinpanel{width:750px;margin:10% auto 0}.signinpanel .logopanel{float:none;width:auto;padding:0;background:0}.signinpanel .signin-info ul{list-style:none;padding:0;margin:20px 0}.signinpanel .form-control{display:block;margin-top:15px}.signinpanel .uname{background:#fff url(../img/user.png) no-repeat 95% center;color:#333}.signinpanel .pword{background:#fff url(../img/locked.png) no-repeat 95% center;color:#333}.signinpanel .code{background:#fff no-repeat 95% center;color:#333;margin:0 0 15px 0}.signinpanel .btn{margin-top:15px}.signinpanel form{background:rgba(255,255,255,.2);border:1px solid rgba(255,255,255,.3);-moz-box-shadow:0 3px 0 rgba(12,12,12,.03);-webkit-box-shadow:0 3px 0 rgba(12,12,12,.03);box-shadow:0 3px 0 rgba(12,12,12,.03);-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;padding:30px}.signup-footer{border-top:solid 1px rgba(255,255,255,.3);margin:20px 0;padding-top:15px}@media screen and (max-width:768px){.signinpanel,.signuppanel{margin:0 auto;width:420px!important;padding:20px}.signinpanel form{margin-top:20px}.signup-footer,.signuppanel .form-control{margin-bottom:10px}.signup-footer .pull-left,.signup-footer .pull-right{float:none!important;text-align:center}.signinpanel .signin-info ul{display:none}}@media screen and (max-width:320px){.signinpanel,.signuppanel{margin:0 20px;width:auto}}.checkbox-custom{position:relative;padding:0 15px 0 25px;margin-bottom:7px;display:inline-block}.checkbox-custom input[type="checkbox"]{opacity:0;position:absolute;cursor:pointer;z-index:2;margin:-6px 0 0 0;top:50%;left:3px}.checkbox-custom label:before{content:'';position:absolute;top:50%;left:0;margin-top:-9px;width:18px;height:17px;display:inline-block;border-radius:2px;border:1px solid #bbb;background:#fff}.checkbox-custom input[type="checkbox"]:checked+label:after{position:absolute;display:inline-block;font-family:'Glyphicons Halflings';content:"\e013";top:42%;left:3px;margin-top:-5px;font-size:11px;line-height:1;width:16px;height:16px;color:#333}.checkbox-custom label{cursor:pointer;line-height:1.2;font-weight:normal;margin-bottom:0;text-align:left}.form-control,.form-control:focus,.has-error .form-control:focus,.has-success .form-control:focus,.has-warning .form-control:focus,.navbar-collapse,.navbar-form,.navbar-form-custom .form-control:focus,.navbar-form-custom .form-control:hover,.open .btn.dropdown-toggle,.panel,.popover,.progress,.progress-bar{box-shadow:none}.form-control{border-radius:1px!important;padding:6px 12px!important;height:34px!important}.form-control:focus{border-color:#1ab394!important}
html {
height: 100%
}
body.signin {
height: auto;
background: url(../img/login-background.jpg) no-repeat center fixed;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
color: rgba(255, 255, 255, .95)
}
.signinpanel {
width: 750px;
margin: 10% auto 0
}
.signinpanel .logopanel {
float: none;
width: auto;
padding: 0;
background: 0
}
.signinpanel .signin-info ul {
list-style: none;
padding: 0;
margin: 20px 0
}
.signinpanel .form-control {
display: block;
margin-top: 15px
}
.signinpanel .uname {
background: #fff url(../img/user.png) no-repeat 95% center;
color: #333
}
.signinpanel .pword {
background: #fff url(../img/locked.png) no-repeat 95% center;
color: #333
}
.signinpanel .code {
background: #fff no-repeat 95% center;
color: #333;
margin: 0 0 15px 0
}
.signinpanel .btn {
margin-top: 15px
}
.signinpanel form {
background: rgba(255, 255, 255, .2);
border: 1px solid rgba(255, 255, 255, .3);
-moz-box-shadow: 0 3px 0 rgba(12, 12, 12, .03);
-webkit-box-shadow: 0 3px 0 rgba(12, 12, 12, .03);
box-shadow: 0 3px 0 rgba(12, 12, 12, .03);
-moz-border-radius: 3px;
-webkit-border-radius: 3px;
border-radius: 3px;
padding: 30px
}
.signup-footer {
border-top: solid 1px rgba(255, 255, 255, .3);
margin: 20px 0;
padding-top: 15px
}
@media screen and (max-width: 768px) {
.signinpanel, .signuppanel {
margin: 0 auto;
width: 420px !important;
padding: 20px
}
.signinpanel form {
margin-top: 20px
}
.signup-footer, .signuppanel .form-control {
margin-bottom: 10px
}
.signup-footer .pull-left, .signup-footer .pull-right {
float: none !important;
text-align: center
}
.signinpanel .signin-info ul {
display: none
}
}
@media screen and (max-width: 320px) {
.signinpanel, .signuppanel {
margin: 0 20px;
width: auto
}
}
.checkbox-custom {
position: relative;
padding: 0 15px 0 25px;
margin-bottom: 7px;
display: inline-block
}
.checkbox-custom input[type="checkbox"] {
opacity: 0;
position: absolute;
cursor: pointer;
z-index: 2;
margin: -6px 0 0 0;
top: 50%;
left: 3px
}
.checkbox-custom label:before {
content: '';
position: absolute;
top: 50%;
left: 0;
margin-top: -9px;
width: 18px;
height: 17px;
display: inline-block;
border-radius: 2px;
border: 1px solid #bbb;
background: #fff
}
.checkbox-custom input[type="checkbox"]:checked + label:after {
position: absolute;
display: inline-block;
font-family: 'Glyphicons Halflings';
content: "\e013";
top: 42%;
left: 3px;
margin-top: -5px;
font-size: 11px;
line-height: 1;
width: 16px;
height: 16px;
color: #333
}
.checkbox-custom label {
cursor: pointer;
line-height: 1.2;
font-weight: normal;
margin-bottom: 0;
text-align: left
}
.form-control, .form-control:focus, .has-error .form-control:focus, .has-success .form-control:focus, .has-warning .form-control:focus, .navbar-collapse, .navbar-form, .navbar-form-custom .form-control:focus, .navbar-form-custom .form-control:hover, .open .btn.dropdown-toggle, .panel, .popover, .progress, .progress-bar {
box-shadow: none
}
.form-control {
border-radius: 1px !important;
padding: 6px 12px !important;
height: 34px !important
}
.form-control:focus {
border-color: #1ab394 !important
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 156 KiB

@ -26,7 +26,7 @@
</div>
<a th:href="@{/index}">
<li class="logo hidden-xs">
<span class="logo-lg">RuoYi</span>
<span class="logo-lg">后台管理</span>
</li>
</a>
<div class="sidebar-collapse">
@ -182,8 +182,8 @@
</a>
</div>
<ul class="nav navbar-top-links navbar-right welcome-message">
<li><a title="视频教程" href="http://doc.ruoyi.vip/ruoyi/document/spjc.html" target="_blank"><i class="fa fa-video-camera"></i> 视频教程</a></li>
<li><a title="开发文档" href="http://doc.ruoyi.vip" target="_blank"><i class="fa fa-question-circle"></i> 开发文档</a></li>
<!-- <li><a title="视频教程" href="http://doc.ruoyi.vip/ruoyi/document/spjc.html" target="_blank"><i class="fa fa-video-camera"></i> 视频教程</a></li>-->
<!-- <li><a title="开发文档" href="http://doc.ruoyi.vip" target="_blank"><i class="fa fa-question-circle"></i> 开发文档</a></li>-->
<li><a title="全屏显示" href="javascript:void(0)" id="fullScreen"><i class="fa fa-arrows-alt"></i> 全屏显示</a></li>
<li class="dropdown user-menu">
<a href="javascript:void(0)" class="dropdown-toggle" data-hover="dropdown">

@ -23,27 +23,27 @@
<body class="signin">
<div class="signinpanel">
<div class="row">
<div class="col-sm-7">
<div class="signin-info">
<div class="logopanel m-b">
<h1><img alt="[ 若依 ]" src="../static/ruoyi.png" th:src="@{/ruoyi.png}"></h1>
</div>
<div class="m-b"></div>
<h4>欢迎使用 <strong>设备智能监控</strong></h4>
<ul class="m-b">
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> SpringBoot</li>
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Mybatis</li>
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Shiro</li>
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Thymeleaf</li>
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Bootstrap</li>
</ul>
<strong th:if="${@config.getKey('sys.account.registerUser')}">还没有账号? <a th:href="@{/register}">立即注册&raquo;</a></strong>
</div>
</div>
<div class="col-sm-5">
<!-- <div class="col-sm-7">-->
<!-- <div class="signin-info">-->
<!-- <div class="logopanel m-b">-->
<!-- <h1><img alt="[ 若依 ]" src="../static/ruoyi.png" th:src="@{/ruoyi.png}"></h1>-->
<!-- </div>-->
<!-- <div class="m-b"></div>-->
<!-- <h4>欢迎使用 <strong>设备智能监控</strong></h4>-->
<!-- <ul class="m-b">-->
<!-- <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> </li>-->
<!-- <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> </li>-->
<!-- <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> </li>-->
<!-- <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> </li>-->
<!-- <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> </li>-->
<!-- </ul>-->
<!-- <strong th:if="${@config.getKey('sys.account.registerUser')}">还没有账号? <a th:href="@{/register}">立即注册&raquo;</a></strong>-->
<!-- </div>-->
<!-- </div>-->
<div class="col-sm-7" style="left: 20%">
<form id="signupForm" autocomplete="off">
<h4 class="no-margins">登录:</h4>
<p class="m-t-md">你若不离不弃,我必生死相依</p>
<p class="m-t-md">设备智能监控</p>
<input type="text" name="username" class="form-control uname" placeholder="用户名" value="admin" />
<input type="password" name="password" class="form-control pword" placeholder="密码" value="admin123" />
<div class="row m-t" th:if="${captchaEnabled==true}">
@ -63,11 +63,11 @@
</form>
</div>
</div>
<div class="signup-footer">
<div class="pull-left">
&copy; 2019 All Rights Reserved. RuoYi <br>
</div>
</div>
<!-- <div class="signup-footer">-->
<!-- <div class="pull-left">-->
<!-- &copy; 2019 All Rights Reserved. RuoYi <br>-->
<!-- </div>-->
<!-- </div>-->
</div>
<script th:inline="javascript"> var ctx = [[@{/}]]; var captchaType = [[${captchaType}]]; </script>
<!-- 全局js -->

@ -11,8 +11,11 @@
<link href="../static/css/main/animate.min.css" th:href="@{/css/main/animate.min.css}" rel="stylesheet"/>
<link href="../static/css/main/style.min862f.css" th:href="@{/css/main/style.min862f.css}" rel="stylesheet"/>
</head>
<body style="background: url(../img/index.jpg) ">
<body class="gray-bg">
</body>
<!--<body class="gray-bg">
<div class="row border-bottom white-bg dashboard-header">
<div class="col-sm-12">
<blockquote class="text-warning" style="font-size:14px">
@ -1028,5 +1031,5 @@
});
});
</script>
</body>
</body>-->
</html>

@ -0,0 +1,126 @@
package com.haiwei.manage.controller;
import java.util.List;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
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.haiwei.common.annotation.Log;
import com.haiwei.common.enums.BusinessType;
import com.haiwei.manage.domain.BaseCustomer;
import com.haiwei.manage.service.IBaseCustomerService;
import com.haiwei.common.core.controller.BaseController;
import com.haiwei.common.core.domain.AjaxResult;
import com.haiwei.common.utils.poi.ExcelUtil;
import com.haiwei.common.core.page.TableDataInfo;
/**
* Controller
*
* @author wangh
* @date 2023-08-15
*/
@Controller
@RequestMapping("/manage/base_customer")
public class BaseCustomerController extends BaseController
{
private String prefix = "manage/base_customer";
@Autowired
private IBaseCustomerService baseCustomerService;
@RequiresPermissions("manage:base_customer:view")
@GetMapping()
public String base_customer()
{
return prefix + "/base_customer";
}
/**
*
*/
@RequiresPermissions("manage:base_customer:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(BaseCustomer baseCustomer)
{
startPage();
List<BaseCustomer> list = baseCustomerService.selectBaseCustomerList(baseCustomer);
return getDataTable(list);
}
/**
*
*/
@RequiresPermissions("manage:base_customer:export")
@Log(title = "客户信息管理", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(BaseCustomer baseCustomer)
{
List<BaseCustomer> list = baseCustomerService.selectBaseCustomerList(baseCustomer);
ExcelUtil<BaseCustomer> util = new ExcelUtil<BaseCustomer>(BaseCustomer.class);
return util.exportExcel(list, "base_customer");
}
/**
*
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
*
*/
@RequiresPermissions("manage:base_customer:add")
@Log(title = "客户信息管理", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(BaseCustomer baseCustomer)
{
return toAjax(baseCustomerService.insertBaseCustomer(baseCustomer));
}
/**
*
*/
@GetMapping("/edit/{objid}")
public String edit(@PathVariable("objid") Long objid, ModelMap mmap)
{
BaseCustomer baseCustomer = baseCustomerService.selectBaseCustomerById(objid);
mmap.put("baseCustomer", baseCustomer);
return prefix + "/edit";
}
/**
*
*/
@RequiresPermissions("manage:base_customer:edit")
@Log(title = "客户信息管理", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(BaseCustomer baseCustomer)
{
return toAjax(baseCustomerService.updateBaseCustomer(baseCustomer));
}
/**
*
*/
@RequiresPermissions("manage:base_customer:remove")
@Log(title = "客户信息管理", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(baseCustomerService.deleteBaseCustomerByIds(ids));
}
}

@ -0,0 +1,126 @@
package com.haiwei.manage.controller;
import java.util.List;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
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.haiwei.common.annotation.Log;
import com.haiwei.common.enums.BusinessType;
import com.haiwei.manage.domain.BaseDeviceInfo;
import com.haiwei.manage.service.IBaseDeviceInfoService;
import com.haiwei.common.core.controller.BaseController;
import com.haiwei.common.core.domain.AjaxResult;
import com.haiwei.common.utils.poi.ExcelUtil;
import com.haiwei.common.core.page.TableDataInfo;
/**
* Controller
*
* @author wangh
* @date 2023-08-15
*/
@Controller
@RequestMapping("/manage/base_device_info")
public class BaseDeviceInfoController extends BaseController
{
private String prefix = "manage/base_device_info";
@Autowired
private IBaseDeviceInfoService baseDeviceInfoService;
@RequiresPermissions("manage:base_device_info:view")
@GetMapping()
public String base_device_info()
{
return prefix + "/base_device_info";
}
/**
*
*/
@RequiresPermissions("manage:base_device_info:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(BaseDeviceInfo baseDeviceInfo)
{
startPage();
List<BaseDeviceInfo> list = baseDeviceInfoService.selectBaseDeviceInfoList(baseDeviceInfo);
return getDataTable(list);
}
/**
*
*/
@RequiresPermissions("manage:base_device_info:export")
@Log(title = "设备信息维护", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(BaseDeviceInfo baseDeviceInfo)
{
List<BaseDeviceInfo> list = baseDeviceInfoService.selectBaseDeviceInfoList(baseDeviceInfo);
ExcelUtil<BaseDeviceInfo> util = new ExcelUtil<BaseDeviceInfo>(BaseDeviceInfo.class);
return util.exportExcel(list, "base_device_info");
}
/**
*
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
*
*/
@RequiresPermissions("manage:base_device_info:add")
@Log(title = "设备信息维护", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(BaseDeviceInfo baseDeviceInfo)
{
return toAjax(baseDeviceInfoService.insertBaseDeviceInfo(baseDeviceInfo));
}
/**
*
*/
@GetMapping("/edit/{objid}")
public String edit(@PathVariable("objid") Long objid, ModelMap mmap)
{
BaseDeviceInfo baseDeviceInfo = baseDeviceInfoService.selectBaseDeviceInfoById(objid);
mmap.put("baseDeviceInfo", baseDeviceInfo);
return prefix + "/edit";
}
/**
*
*/
@RequiresPermissions("manage:base_device_info:edit")
@Log(title = "设备信息维护", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(BaseDeviceInfo baseDeviceInfo)
{
return toAjax(baseDeviceInfoService.updateBaseDeviceInfo(baseDeviceInfo));
}
/**
*
*/
@RequiresPermissions("manage:base_device_info:remove")
@Log(title = "设备信息维护", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(baseDeviceInfoService.deleteBaseDeviceInfoByIds(ids));
}
}

@ -0,0 +1,126 @@
package com.haiwei.manage.controller;
import java.util.List;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
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.haiwei.common.annotation.Log;
import com.haiwei.common.enums.BusinessType;
import com.haiwei.manage.domain.BaseMonitorInfo;
import com.haiwei.manage.service.IBaseMonitorInfoService;
import com.haiwei.common.core.controller.BaseController;
import com.haiwei.common.core.domain.AjaxResult;
import com.haiwei.common.utils.poi.ExcelUtil;
import com.haiwei.common.core.page.TableDataInfo;
/**
* Controller
*
* @author wangh
* @date 2023-08-15
*/
@Controller
@RequestMapping("/manage/base_monitor_info")
public class BaseMonitorInfoController extends BaseController
{
private String prefix = "manage/base_monitor_info";
@Autowired
private IBaseMonitorInfoService baseMonitorInfoService;
@RequiresPermissions("manage:base_monitor_info:view")
@GetMapping()
public String base_monitor_info()
{
return prefix + "/base_monitor_info";
}
/**
*
*/
@RequiresPermissions("manage:base_monitor_info:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(BaseMonitorInfo baseMonitorInfo)
{
startPage();
List<BaseMonitorInfo> list = baseMonitorInfoService.selectBaseMonitorInfoList(baseMonitorInfo);
return getDataTable(list);
}
/**
*
*/
@RequiresPermissions("manage:base_monitor_info:export")
@Log(title = "视频监控信息管理", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(BaseMonitorInfo baseMonitorInfo)
{
List<BaseMonitorInfo> list = baseMonitorInfoService.selectBaseMonitorInfoList(baseMonitorInfo);
ExcelUtil<BaseMonitorInfo> util = new ExcelUtil<BaseMonitorInfo>(BaseMonitorInfo.class);
return util.exportExcel(list, "base_monitor_info");
}
/**
*
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
*
*/
@RequiresPermissions("manage:base_monitor_info:add")
@Log(title = "视频监控信息管理", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(BaseMonitorInfo baseMonitorInfo)
{
return toAjax(baseMonitorInfoService.insertBaseMonitorInfo(baseMonitorInfo));
}
/**
*
*/
@GetMapping("/edit/{objid}")
public String edit(@PathVariable("objid") Long objid, ModelMap mmap)
{
BaseMonitorInfo baseMonitorInfo = baseMonitorInfoService.selectBaseMonitorInfoById(objid);
mmap.put("baseMonitorInfo", baseMonitorInfo);
return prefix + "/edit";
}
/**
*
*/
@RequiresPermissions("manage:base_monitor_info:edit")
@Log(title = "视频监控信息管理", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(BaseMonitorInfo baseMonitorInfo)
{
return toAjax(baseMonitorInfoService.updateBaseMonitorInfo(baseMonitorInfo));
}
/**
*
*/
@RequiresPermissions("manage:base_monitor_info:remove")
@Log(title = "视频监控信息管理", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(baseMonitorInfoService.deleteBaseMonitorInfoByIds(ids));
}
}

@ -0,0 +1,83 @@
package com.haiwei.manage.domain;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.haiwei.common.annotation.Excel;
import com.haiwei.common.core.domain.BaseEntity;
/**
* base_customer
*
* @author wangh
* @date 2023-08-15
*/
public class BaseCustomer extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** 主键 */
private Long objid;
/** 客户名称 */
@Excel(name = "客户名称")
private String customerName;
/** 客户logo */
@Excel(name = "客户logo")
private String customerLogo;
/** 客户介绍 */
@Excel(name = "客户介绍")
private String customerInfo;
public void setObjid(Long objid)
{
this.objid = objid;
}
public Long getObjid()
{
return objid;
}
public void setCustomerName(String customerName)
{
this.customerName = customerName;
}
public String getCustomerName()
{
return customerName;
}
public void setCustomerLogo(String customerLogo)
{
this.customerLogo = customerLogo;
}
public String getCustomerLogo()
{
return customerLogo;
}
public void setCustomerInfo(String customerInfo)
{
this.customerInfo = customerInfo;
}
public String getCustomerInfo()
{
return customerInfo;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("objid", getObjid())
.append("customerName", getCustomerName())
.append("customerLogo", getCustomerLogo())
.append("customerInfo", getCustomerInfo())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.toString();
}
}

@ -0,0 +1,125 @@
package com.haiwei.manage.domain;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.haiwei.common.annotation.Excel;
import com.haiwei.common.core.domain.BaseEntity;
/**
* base_device_info
*
* @author wangh
* @date 2023-08-15
*/
public class BaseDeviceInfo extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** 主键 */
private Long objid;
/** 设备名称 */
@Excel(name = "设备名称")
private String deviceName;
/** 设备类型 */
@Excel(name = "设备类型")
private String deviceTypeName;
/** 设备模型图片 */
@Excel(name = "设备模型图片")
private String deviceMode;
/** 设备规格 */
@Excel(name = "设备规格")
private String deviceSpe;
/** 功能描述 */
@Excel(name = "功能描述")
private String deviceFunction;
/** 设备参数 */
@Excel(name = "设备参数")
private String deviceParam;
public void setObjid(Long objid)
{
this.objid = objid;
}
public Long getObjid()
{
return objid;
}
public void setDeviceName(String deviceName)
{
this.deviceName = deviceName;
}
public String getDeviceName()
{
return deviceName;
}
public void setDeviceTypeName(String deviceTypeName)
{
this.deviceTypeName = deviceTypeName;
}
public String getDeviceTypeName()
{
return deviceTypeName;
}
public void setDeviceMode(String deviceMode)
{
this.deviceMode = deviceMode;
}
public String getDeviceMode()
{
return deviceMode;
}
public void setDeviceSpe(String deviceSpe)
{
this.deviceSpe = deviceSpe;
}
public String getDeviceSpe()
{
return deviceSpe;
}
public void setDeviceFunction(String deviceFunction)
{
this.deviceFunction = deviceFunction;
}
public String getDeviceFunction()
{
return deviceFunction;
}
public void setDeviceParam(String deviceParam)
{
this.deviceParam = deviceParam;
}
public String getDeviceParam()
{
return deviceParam;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("objid", getObjid())
.append("deviceName", getDeviceName())
.append("deviceTypeName", getDeviceTypeName())
.append("deviceMode", getDeviceMode())
.append("deviceSpe", getDeviceSpe())
.append("deviceFunction", getDeviceFunction())
.append("deviceParam", getDeviceParam())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.toString();
}
}

@ -0,0 +1,69 @@
package com.haiwei.manage.domain;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.haiwei.common.annotation.Excel;
import com.haiwei.common.core.domain.BaseEntity;
/**
* base_monitor_info
*
* @author wangh
* @date 2023-08-15
*/
public class BaseMonitorInfo extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** 主键 */
private Long objid;
/** 监控名称 */
@Excel(name = "监控名称")
private String monitorName;
/** 设备IP */
@Excel(name = "设备IP")
private String monitorIp;
public void setObjid(Long objid)
{
this.objid = objid;
}
public Long getObjid()
{
return objid;
}
public void setMonitorName(String monitorName)
{
this.monitorName = monitorName;
}
public String getMonitorName()
{
return monitorName;
}
public void setMonitorIp(String monitorIp)
{
this.monitorIp = monitorIp;
}
public String getMonitorIp()
{
return monitorIp;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("objid", getObjid())
.append("monitorName", getMonitorName())
.append("monitorIp", getMonitorIp())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.toString();
}
}

@ -0,0 +1,61 @@
package com.haiwei.manage.mapper;
import java.util.List;
import com.haiwei.manage.domain.BaseCustomer;
/**
* Mapper
*
* @author wangh
* @date 2023-08-15
*/
public interface BaseCustomerMapper
{
/**
*
*
* @param objid ID
* @return
*/
public BaseCustomer selectBaseCustomerById(Long objid);
/**
*
*
* @param baseCustomer
* @return
*/
public List<BaseCustomer> selectBaseCustomerList(BaseCustomer baseCustomer);
/**
*
*
* @param baseCustomer
* @return
*/
public int insertBaseCustomer(BaseCustomer baseCustomer);
/**
*
*
* @param baseCustomer
* @return
*/
public int updateBaseCustomer(BaseCustomer baseCustomer);
/**
*
*
* @param objid ID
* @return
*/
public int deleteBaseCustomerById(Long objid);
/**
*
*
* @param objids ID
* @return
*/
public int deleteBaseCustomerByIds(String[] objids);
}

@ -0,0 +1,61 @@
package com.haiwei.manage.mapper;
import java.util.List;
import com.haiwei.manage.domain.BaseDeviceInfo;
/**
* Mapper
*
* @author wangh
* @date 2023-08-15
*/
public interface BaseDeviceInfoMapper
{
/**
*
*
* @param objid ID
* @return
*/
public BaseDeviceInfo selectBaseDeviceInfoById(Long objid);
/**
*
*
* @param baseDeviceInfo
* @return
*/
public List<BaseDeviceInfo> selectBaseDeviceInfoList(BaseDeviceInfo baseDeviceInfo);
/**
*
*
* @param baseDeviceInfo
* @return
*/
public int insertBaseDeviceInfo(BaseDeviceInfo baseDeviceInfo);
/**
*
*
* @param baseDeviceInfo
* @return
*/
public int updateBaseDeviceInfo(BaseDeviceInfo baseDeviceInfo);
/**
*
*
* @param objid ID
* @return
*/
public int deleteBaseDeviceInfoById(Long objid);
/**
*
*
* @param objids ID
* @return
*/
public int deleteBaseDeviceInfoByIds(String[] objids);
}

@ -0,0 +1,61 @@
package com.haiwei.manage.mapper;
import java.util.List;
import com.haiwei.manage.domain.BaseMonitorInfo;
/**
* Mapper
*
* @author wangh
* @date 2023-08-15
*/
public interface BaseMonitorInfoMapper
{
/**
*
*
* @param objid ID
* @return
*/
public BaseMonitorInfo selectBaseMonitorInfoById(Long objid);
/**
*
*
* @param baseMonitorInfo
* @return
*/
public List<BaseMonitorInfo> selectBaseMonitorInfoList(BaseMonitorInfo baseMonitorInfo);
/**
*
*
* @param baseMonitorInfo
* @return
*/
public int insertBaseMonitorInfo(BaseMonitorInfo baseMonitorInfo);
/**
*
*
* @param baseMonitorInfo
* @return
*/
public int updateBaseMonitorInfo(BaseMonitorInfo baseMonitorInfo);
/**
*
*
* @param objid ID
* @return
*/
public int deleteBaseMonitorInfoById(Long objid);
/**
*
*
* @param objids ID
* @return
*/
public int deleteBaseMonitorInfoByIds(String[] objids);
}

@ -0,0 +1,61 @@
package com.haiwei.manage.service;
import java.util.List;
import com.haiwei.manage.domain.BaseCustomer;
/**
* Service
*
* @author wangh
* @date 2023-08-15
*/
public interface IBaseCustomerService
{
/**
*
*
* @param objid ID
* @return
*/
public BaseCustomer selectBaseCustomerById(Long objid);
/**
*
*
* @param baseCustomer
* @return
*/
public List<BaseCustomer> selectBaseCustomerList(BaseCustomer baseCustomer);
/**
*
*
* @param baseCustomer
* @return
*/
public int insertBaseCustomer(BaseCustomer baseCustomer);
/**
*
*
* @param baseCustomer
* @return
*/
public int updateBaseCustomer(BaseCustomer baseCustomer);
/**
*
*
* @param ids ID
* @return
*/
public int deleteBaseCustomerByIds(String ids);
/**
*
*
* @param objid ID
* @return
*/
public int deleteBaseCustomerById(Long objid);
}

@ -0,0 +1,61 @@
package com.haiwei.manage.service;
import java.util.List;
import com.haiwei.manage.domain.BaseDeviceInfo;
/**
* Service
*
* @author wangh
* @date 2023-08-15
*/
public interface IBaseDeviceInfoService
{
/**
*
*
* @param objid ID
* @return
*/
public BaseDeviceInfo selectBaseDeviceInfoById(Long objid);
/**
*
*
* @param baseDeviceInfo
* @return
*/
public List<BaseDeviceInfo> selectBaseDeviceInfoList(BaseDeviceInfo baseDeviceInfo);
/**
*
*
* @param baseDeviceInfo
* @return
*/
public int insertBaseDeviceInfo(BaseDeviceInfo baseDeviceInfo);
/**
*
*
* @param baseDeviceInfo
* @return
*/
public int updateBaseDeviceInfo(BaseDeviceInfo baseDeviceInfo);
/**
*
*
* @param ids ID
* @return
*/
public int deleteBaseDeviceInfoByIds(String ids);
/**
*
*
* @param objid ID
* @return
*/
public int deleteBaseDeviceInfoById(Long objid);
}

@ -0,0 +1,61 @@
package com.haiwei.manage.service;
import java.util.List;
import com.haiwei.manage.domain.BaseMonitorInfo;
/**
* Service
*
* @author wangh
* @date 2023-08-15
*/
public interface IBaseMonitorInfoService
{
/**
*
*
* @param objid ID
* @return
*/
public BaseMonitorInfo selectBaseMonitorInfoById(Long objid);
/**
*
*
* @param baseMonitorInfo
* @return
*/
public List<BaseMonitorInfo> selectBaseMonitorInfoList(BaseMonitorInfo baseMonitorInfo);
/**
*
*
* @param baseMonitorInfo
* @return
*/
public int insertBaseMonitorInfo(BaseMonitorInfo baseMonitorInfo);
/**
*
*
* @param baseMonitorInfo
* @return
*/
public int updateBaseMonitorInfo(BaseMonitorInfo baseMonitorInfo);
/**
*
*
* @param ids ID
* @return
*/
public int deleteBaseMonitorInfoByIds(String ids);
/**
*
*
* @param objid ID
* @return
*/
public int deleteBaseMonitorInfoById(Long objid);
}

@ -0,0 +1,100 @@
package com.haiwei.manage.service.impl;
import java.util.List;
import com.haiwei.common.utils.DateUtils;
import com.haiwei.framework.util.ShiroUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.haiwei.manage.mapper.BaseCustomerMapper;
import com.haiwei.manage.domain.BaseCustomer;
import com.haiwei.manage.service.IBaseCustomerService;
import com.haiwei.common.core.text.Convert;
/**
* Service
*
* @author wangh
* @date 2023-08-15
*/
@Service
public class BaseCustomerServiceImpl implements IBaseCustomerService
{
@Autowired
private BaseCustomerMapper baseCustomerMapper;
/**
*
*
* @param objid ID
* @return
*/
@Override
public BaseCustomer selectBaseCustomerById(Long objid)
{
return baseCustomerMapper.selectBaseCustomerById(objid);
}
/**
*
*
* @param baseCustomer
* @return
*/
@Override
public List<BaseCustomer> selectBaseCustomerList(BaseCustomer baseCustomer)
{
return baseCustomerMapper.selectBaseCustomerList(baseCustomer);
}
/**
*
*
* @param baseCustomer
* @return
*/
@Override
public int insertBaseCustomer(BaseCustomer baseCustomer)
{
baseCustomer.setCreateBy(ShiroUtils.getLoginName());
baseCustomer.setCreateTime(DateUtils.getNowDate());
return baseCustomerMapper.insertBaseCustomer(baseCustomer);
}
/**
*
*
* @param baseCustomer
* @return
*/
@Override
public int updateBaseCustomer(BaseCustomer baseCustomer)
{
baseCustomer.setUpdateBy(ShiroUtils.getLoginName());
baseCustomer.setUpdateTime(DateUtils.getNowDate());
return baseCustomerMapper.updateBaseCustomer(baseCustomer);
}
/**
*
*
* @param ids ID
* @return
*/
@Override
public int deleteBaseCustomerByIds(String ids)
{
return baseCustomerMapper.deleteBaseCustomerByIds(Convert.toStrArray(ids));
}
/**
*
*
* @param objid ID
* @return
*/
@Override
public int deleteBaseCustomerById(Long objid)
{
return baseCustomerMapper.deleteBaseCustomerById(objid);
}
}

@ -0,0 +1,100 @@
package com.haiwei.manage.service.impl;
import java.util.List;
import com.haiwei.common.utils.DateUtils;
import com.haiwei.framework.util.ShiroUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.haiwei.manage.mapper.BaseDeviceInfoMapper;
import com.haiwei.manage.domain.BaseDeviceInfo;
import com.haiwei.manage.service.IBaseDeviceInfoService;
import com.haiwei.common.core.text.Convert;
/**
* Service
*
* @author wangh
* @date 2023-08-15
*/
@Service
public class BaseDeviceInfoServiceImpl implements IBaseDeviceInfoService
{
@Autowired
private BaseDeviceInfoMapper baseDeviceInfoMapper;
/**
*
*
* @param objid ID
* @return
*/
@Override
public BaseDeviceInfo selectBaseDeviceInfoById(Long objid)
{
return baseDeviceInfoMapper.selectBaseDeviceInfoById(objid);
}
/**
*
*
* @param baseDeviceInfo
* @return
*/
@Override
public List<BaseDeviceInfo> selectBaseDeviceInfoList(BaseDeviceInfo baseDeviceInfo)
{
return baseDeviceInfoMapper.selectBaseDeviceInfoList(baseDeviceInfo);
}
/**
*
*
* @param baseDeviceInfo
* @return
*/
@Override
public int insertBaseDeviceInfo(BaseDeviceInfo baseDeviceInfo)
{
baseDeviceInfo.setCreateBy(ShiroUtils.getLoginName());
baseDeviceInfo.setCreateTime(DateUtils.getNowDate());
return baseDeviceInfoMapper.insertBaseDeviceInfo(baseDeviceInfo);
}
/**
*
*
* @param baseDeviceInfo
* @return
*/
@Override
public int updateBaseDeviceInfo(BaseDeviceInfo baseDeviceInfo)
{
baseDeviceInfo.setUpdateBy(ShiroUtils.getLoginName());
baseDeviceInfo.setUpdateTime(DateUtils.getNowDate());
return baseDeviceInfoMapper.updateBaseDeviceInfo(baseDeviceInfo);
}
/**
*
*
* @param ids ID
* @return
*/
@Override
public int deleteBaseDeviceInfoByIds(String ids)
{
return baseDeviceInfoMapper.deleteBaseDeviceInfoByIds(Convert.toStrArray(ids));
}
/**
*
*
* @param objid ID
* @return
*/
@Override
public int deleteBaseDeviceInfoById(Long objid)
{
return baseDeviceInfoMapper.deleteBaseDeviceInfoById(objid);
}
}

@ -0,0 +1,100 @@
package com.haiwei.manage.service.impl;
import java.util.List;
import com.haiwei.common.utils.DateUtils;
import com.haiwei.framework.util.ShiroUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.haiwei.manage.mapper.BaseMonitorInfoMapper;
import com.haiwei.manage.domain.BaseMonitorInfo;
import com.haiwei.manage.service.IBaseMonitorInfoService;
import com.haiwei.common.core.text.Convert;
/**
* Service
*
* @author wangh
* @date 2023-08-15
*/
@Service
public class BaseMonitorInfoServiceImpl implements IBaseMonitorInfoService
{
@Autowired
private BaseMonitorInfoMapper baseMonitorInfoMapper;
/**
*
*
* @param objid ID
* @return
*/
@Override
public BaseMonitorInfo selectBaseMonitorInfoById(Long objid)
{
return baseMonitorInfoMapper.selectBaseMonitorInfoById(objid);
}
/**
*
*
* @param baseMonitorInfo
* @return
*/
@Override
public List<BaseMonitorInfo> selectBaseMonitorInfoList(BaseMonitorInfo baseMonitorInfo)
{
return baseMonitorInfoMapper.selectBaseMonitorInfoList(baseMonitorInfo);
}
/**
*
*
* @param baseMonitorInfo
* @return
*/
@Override
public int insertBaseMonitorInfo(BaseMonitorInfo baseMonitorInfo)
{
baseMonitorInfo.setCreateBy(ShiroUtils.getLoginName());
baseMonitorInfo.setCreateTime(DateUtils.getNowDate());
return baseMonitorInfoMapper.insertBaseMonitorInfo(baseMonitorInfo);
}
/**
*
*
* @param baseMonitorInfo
* @return
*/
@Override
public int updateBaseMonitorInfo(BaseMonitorInfo baseMonitorInfo)
{
baseMonitorInfo.setUpdateBy(ShiroUtils.getLoginName());
baseMonitorInfo.setUpdateTime(DateUtils.getNowDate());
return baseMonitorInfoMapper.updateBaseMonitorInfo(baseMonitorInfo);
}
/**
*
*
* @param ids ID
* @return
*/
@Override
public int deleteBaseMonitorInfoByIds(String ids)
{
return baseMonitorInfoMapper.deleteBaseMonitorInfoByIds(Convert.toStrArray(ids));
}
/**
*
*
* @param objid ID
* @return
*/
@Override
public int deleteBaseMonitorInfoById(Long objid)
{
return baseMonitorInfoMapper.deleteBaseMonitorInfoById(objid);
}
}

@ -0,0 +1,83 @@
<?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.haiwei.manage.mapper.BaseCustomerMapper">
<resultMap type="BaseCustomer" id="BaseCustomerResult">
<result property="objid" column="objid" />
<result property="customerName" column="customer_name" />
<result property="customerLogo" column="customer_logo" />
<result property="customerInfo" column="customer_info" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
</resultMap>
<sql id="selectBaseCustomerVo">
select objid, customer_name, customer_logo, customer_info, create_by, create_time, update_by, update_time from base_customer
</sql>
<select id="selectBaseCustomerList" parameterType="BaseCustomer" resultMap="BaseCustomerResult">
<include refid="selectBaseCustomerVo"/>
<where>
<if test="customerName != null and customerName != ''"> and customer_name like ('%' + #{customerName} + '%')</if>
</where>
</select>
<select id="selectBaseCustomerById" parameterType="Long" resultMap="BaseCustomerResult">
<include refid="selectBaseCustomerVo"/>
where objid = #{objid}
</select>
<insert id="insertBaseCustomer" parameterType="BaseCustomer">
insert into base_customer
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="objid != null">objid,</if>
<if test="customerName != null and customerName != ''">customer_name,</if>
<if test="customerLogo != null and customerLogo != ''">customer_logo,</if>
<if test="customerInfo != null">customer_info,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="objid != null">#{objid},</if>
<if test="customerName != null and customerName != ''">#{customerName},</if>
<if test="customerLogo != null and customerLogo != ''">#{customerLogo},</if>
<if test="customerInfo != null">#{customerInfo},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
</trim>
</insert>
<update id="updateBaseCustomer" parameterType="BaseCustomer">
update base_customer
<trim prefix="SET" suffixOverrides=",">
<if test="customerName != null and customerName != ''">customer_name = #{customerName},</if>
<if test="customerLogo != null and customerLogo != ''">customer_logo = #{customerLogo},</if>
<if test="customerInfo != null">customer_info = #{customerInfo},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
</trim>
where objid = #{objid}
</update>
<delete id="deleteBaseCustomerById" parameterType="Long">
delete from base_customer where objid = #{objid}
</delete>
<delete id="deleteBaseCustomerByIds" parameterType="String">
delete from base_customer where objid in
<foreach item="objid" collection="array" open="(" separator="," close=")">
#{objid}
</foreach>
</delete>
</mapper>

@ -0,0 +1,96 @@
<?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.haiwei.manage.mapper.BaseDeviceInfoMapper">
<resultMap type="BaseDeviceInfo" id="BaseDeviceInfoResult">
<result property="objid" column="objid" />
<result property="deviceName" column="device_name" />
<result property="deviceTypeName" column="device_type_name" />
<result property="deviceMode" column="device_mode" />
<result property="deviceSpe" column="device_spe" />
<result property="deviceFunction" column="device_function" />
<result property="deviceParam" column="device_param" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
</resultMap>
<sql id="selectBaseDeviceInfoVo">
select objid, device_name, device_type_name, device_mode, device_spe, device_function, device_param, create_by, create_time, update_by, update_time from base_device_info
</sql>
<select id="selectBaseDeviceInfoList" parameterType="BaseDeviceInfo" resultMap="BaseDeviceInfoResult">
<include refid="selectBaseDeviceInfoVo"/>
<where>
<if test="deviceName != null and deviceName != ''"> and device_name like ('%' + #{deviceName} + '%')</if>
<if test="deviceTypeName != null and deviceTypeName != ''"> and device_type_name = #{deviceTypeName}</if>
</where>
</select>
<select id="selectBaseDeviceInfoById" parameterType="Long" resultMap="BaseDeviceInfoResult">
<include refid="selectBaseDeviceInfoVo"/>
where objid = #{objid}
</select>
<insert id="insertBaseDeviceInfo" parameterType="BaseDeviceInfo">
insert into base_device_info
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="objid != null">objid,</if>
<if test="deviceName != null">device_name,</if>
<if test="deviceTypeName != null">device_type_name,</if>
<if test="deviceMode != null">device_mode,</if>
<if test="deviceSpe != null">device_spe,</if>
<if test="deviceFunction != null">device_function,</if>
<if test="deviceParam != null">device_param,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="objid != null">#{objid},</if>
<if test="deviceName != null">#{deviceName},</if>
<if test="deviceTypeName != null">#{deviceTypeName},</if>
<if test="deviceMode != null">#{deviceMode},</if>
<if test="deviceSpe != null">#{deviceSpe},</if>
<if test="deviceFunction != null">#{deviceFunction},</if>
<if test="deviceParam != null">#{deviceParam},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
</trim>
</insert>
<update id="updateBaseDeviceInfo" parameterType="BaseDeviceInfo">
update base_device_info
<trim prefix="SET" suffixOverrides=",">
<if test="deviceName != null">device_name = #{deviceName},</if>
<if test="deviceTypeName != null">device_type_name = #{deviceTypeName},</if>
<if test="deviceMode != null">device_mode = #{deviceMode},</if>
<if test="deviceSpe != null">device_spe = #{deviceSpe},</if>
<if test="deviceFunction != null">device_function = #{deviceFunction},</if>
<if test="deviceParam != null">device_param = #{deviceParam},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
</trim>
where objid = #{objid}
</update>
<delete id="deleteBaseDeviceInfoById" parameterType="Long">
delete from base_device_info where objid = #{objid}
</delete>
<delete id="deleteBaseDeviceInfoByIds" parameterType="String">
delete from base_device_info where objid in
<foreach item="objid" collection="array" open="(" separator="," close=")">
#{objid}
</foreach>
</delete>
</mapper>

@ -0,0 +1,80 @@
<?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.haiwei.manage.mapper.BaseMonitorInfoMapper">
<resultMap type="BaseMonitorInfo" id="BaseMonitorInfoResult">
<result property="objid" column="objid" />
<result property="monitorName" column="monitor_name" />
<result property="monitorIp" column="monitor_ip" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
</resultMap>
<sql id="selectBaseMonitorInfoVo">
select objid, monitor_name, monitor_ip, create_by, create_time, update_by, update_time from base_monitor_info
</sql>
<select id="selectBaseMonitorInfoList" parameterType="BaseMonitorInfo" resultMap="BaseMonitorInfoResult">
<include refid="selectBaseMonitorInfoVo"/>
<where>
<if test="monitorName != null and monitorName != ''"> and monitor_name = #{monitorName}</if>
<if test="monitorIp != null and monitorIp != ''"> and monitor_ip = #{monitorIp}</if>
</where>
</select>
<select id="selectBaseMonitorInfoById" parameterType="Long" resultMap="BaseMonitorInfoResult">
<include refid="selectBaseMonitorInfoVo"/>
where objid = #{objid}
</select>
<insert id="insertBaseMonitorInfo" parameterType="BaseMonitorInfo">
insert into base_monitor_info
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="objid != null">objid,</if>
<if test="monitorName != null and monitorName != ''">monitor_name,</if>
<if test="monitorIp != null and monitorIp != ''">monitor_ip,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="objid != null">#{objid},</if>
<if test="monitorName != null and monitorName != ''">#{monitorName},</if>
<if test="monitorIp != null and monitorIp != ''">#{monitorIp},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
</trim>
</insert>
<update id="updateBaseMonitorInfo" parameterType="BaseMonitorInfo">
update base_monitor_info
<trim prefix="SET" suffixOverrides=",">
<if test="monitorName != null and monitorName != ''">monitor_name = #{monitorName},</if>
<if test="monitorIp != null and monitorIp != ''">monitor_ip = #{monitorIp},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
</trim>
where objid = #{objid}
</update>
<delete id="deleteBaseMonitorInfoById" parameterType="Long">
delete from base_monitor_info where objid = #{objid}
</delete>
<delete id="deleteBaseMonitorInfoByIds" parameterType="String">
delete from base_monitor_info where objid in
<foreach item="objid" collection="array" open="(" separator="," close=")">
#{objid}
</foreach>
</delete>
</mapper>

@ -0,0 +1,58 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('新增客户信息管理')" />
<th:block th:include="include :: bootstrap-fileinput-css"/>
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-base_customer-add">
<div class="form-group">
<label class="col-sm-3 control-label is-required">客户名称:</label>
<div class="col-sm-8">
<input name="customerName" class="form-control" type="text" required>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label is-required">客户logo</label>
<div class="col-sm-8">
<input type="hidden" name="customerLogo">
<div class="file-loading">
<input class="form-control file-upload" id="customerLogo" name="file" type="file">
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">客户介绍:</label>
<div class="col-sm-8">
<input name="customerInfo" class="form-control" type="text">
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: bootstrap-fileinput-js"/>
<script th:inline="javascript">
var prefix = ctx + "manage/base_customer"
$("#form-base_customer-add").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-base_customer-add').serialize());
}
}
$(".file-upload").fileinput({
uploadUrl: '/common/upload',
maxFileCount: 1,
autoReplace: true
}).on('fileuploaded', function (event, data, previewId, index) {
$("input[name='" + event.currentTarget.id + "']").val(data.response.url)
}).on('fileremoved', function (event, id, index) {
$("input[name='" + event.currentTarget.id + "']").val('')
})
</script>
</body>
</html>

@ -0,0 +1,110 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
<th:block th:include="include :: header('客户信息管理列表')" />
</head>
<body class="gray-bg">
<div class="container-div">
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="formId">
<div class="select-list">
<ul>
<li>
<label>客户名称:</label>
<input type="text" name="customerName"/>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="manage:base_customer:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="manage:base_customer:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="manage:base_customer:remove">
<i class="fa fa-remove"></i> 删除
</a>
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="manage:base_customer:export">
<i class="fa fa-download"></i> 导出
</a>
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('manage:base_customer:edit')}]];
var removeFlag = [[${@permission.hasPermi('manage:base_customer:remove')}]];
var prefix = ctx + "manage/base_customer";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
removeUrl: prefix + "/remove",
exportUrl: prefix + "/export",
modalName: "客户信息管理",
columns: [{
checkbox: true
},
{
field: 'objid',
title: '主键',
visible: false
},
{
field: 'customerName',
title: '客户名称'
},
{
field: 'customerLogo',
title: '客户logo'
},
{
field: 'customerInfo',
title: '客户介绍'
},
{
field: 'createBy',
title: '创建人'
},
{
field: 'createTime',
title: '创建时间'
},
{
field: 'updateBy',
title: '更新人'
},
{
field: 'updateTime',
title: '更新时间'
},
{
title: '操作',
align: 'center',
formatter: function(value, row, index) {
var actions = [];
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.objid + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.objid + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join('');
}
}]
};
$.table.init(options);
});
</script>
</body>
</html>

@ -0,0 +1,65 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('修改客户信息管理')" />
<th:block th:include="include :: bootstrap-fileinput-css"/>
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-base_customer-edit" th:object="${baseCustomer}">
<input name="objid" th:field="*{objid}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label is-required">客户名称:</label>
<div class="col-sm-8">
<input name="customerName" th:field="*{customerName}" class="form-control" type="text" required>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label is-required">客户logo</label>
<div class="col-sm-8">
<input type="hidden" name="customerLogo" th:field="*{customerLogo}">
<div class="file-loading">
<input class="form-control file-upload" id="customerLogo" name="file" type="file">
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">客户介绍:</label>
<div class="col-sm-8">
<input name="customerInfo" th:field="*{customerInfo}" class="form-control" type="text">
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: bootstrap-fileinput-js"/>
<script th:inline="javascript">
var prefix = ctx + "manage/base_customer";
$("#form-base_customer-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-base_customer-edit').serialize());
}
}
$(".file-upload").each(function (i) {
var val = $("input[name='" + this.id + "']").val()
$(this).fileinput({
'uploadUrl': '/common/upload',
initialPreviewAsData: true,
initialPreview: [val],
maxFileCount: 1,
autoReplace: true
}).on('fileuploaded', function (event, data, previewId, index) {
$("input[name='" + event.currentTarget.id + "']").val(data.response.url)
}).on('fileremoved', function (event, id, index) {
$("input[name='" + event.currentTarget.id + "']").val('')
})
$(this).fileinput('_initFileActions');
});
</script>
</body>
</html>

@ -0,0 +1,80 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('新增设备信息维护')" />
<th:block th:include="include :: bootstrap-fileinput-css"/>
<th:block th:include="include :: select2-css" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-base_device_info-add">
<div class="form-group">
<label class="col-sm-3 control-label">设备名称:</label>
<div class="col-sm-8">
<input name="deviceName" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">设备类型:</label>
<div class="col-sm-8">
<select name="deviceTypeName" class="form-control m-b" >
<!-- <option value="">所有</option>-->
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">设备模型图片:</label>
<div class="col-sm-8">
<input type="hidden" name="deviceMode">
<div class="file-loading">
<input class="form-control file-upload" id="deviceMode" name="file" type="file">
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">设备规格:</label>
<div class="col-sm-8">
<input name="deviceSpe" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">功能描述:</label>
<div class="col-sm-8">
<input name="deviceFunction" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">设备参数:</label>
<div class="col-sm-8">
<input name="deviceParam" class="form-control" type="text">
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: select2-js" />
<th:block th:include="include :: bootstrap-fileinput-js"/>
<script th:inline="javascript">
var prefix = ctx + "manage/base_device_info"
$("#form-base_device_info-add").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-base_device_info-add').serialize());
}
}
$(".file-upload").fileinput({
uploadUrl: '/common/upload',
maxFileCount: 1,
autoReplace: true
}).on('fileuploaded', function (event, data, previewId, index) {
$("input[name='" + event.currentTarget.id + "']").val(data.response.url)
}).on('fileremoved', function (event, id, index) {
$("input[name='" + event.currentTarget.id + "']").val('')
})
</script>
</body>
</html>

@ -0,0 +1,121 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
<th:block th:include="include :: header('设备信息维护列表')" />
</head>
<body class="gray-bg">
<div class="container-div">
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="formId">
<div class="select-list">
<ul>
<li>
<label>设备名称:</label>
<input type="text" name="deviceName"/>
</li>
<li>
<label>设备类型:</label>
<select name="deviceTypeName">
<option value="">所有</option>
<option value="-1">代码生成请选择字典属性</option>
</select>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="manage:base_device_info:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="manage:base_device_info:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="manage:base_device_info:remove">
<i class="fa fa-remove"></i> 删除
</a>
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="manage:base_device_info:export">
<i class="fa fa-download"></i> 导出
</a>
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('manage:base_device_info:edit')}]];
var removeFlag = [[${@permission.hasPermi('manage:base_device_info:remove')}]];
var prefix = ctx + "manage/base_device_info";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
removeUrl: prefix + "/remove",
exportUrl: prefix + "/export",
modalName: "设备信息维护",
columns: [{
checkbox: true
},
{
field: 'objid',
title: '主键',
visible: false
},
{
field: 'deviceName',
title: '设备名称'
},
{
field: 'deviceTypeName',
title: '设备类型'
},
{
field: 'deviceMode',
title: '设备模型图片'
},
{
field: 'deviceSpe',
title: '设备规格'
},
{
field: 'deviceFunction',
title: '功能描述'
},
{
field: 'deviceParam',
title: '设备参数'
},
{
field: 'updateBy',
title: '更新人'
},
{
field: 'updateTime',
title: '更新时间'
},
{
title: '操作',
align: 'center',
formatter: function(value, row, index) {
var actions = [];
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.objid + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.objid + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join('');
}
}]
};
$.table.init(options);
});
</script>
</body>
</html>

@ -0,0 +1,86 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('修改设备信息维护')" />
<th:block th:include="include :: bootstrap-fileinput-css"/>
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-base_device_info-edit" th:object="${baseDeviceInfo}">
<input name="objid" th:field="*{objid}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label">设备名称:</label>
<div class="col-sm-8">
<input name="deviceName" th:field="*{deviceName}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">设备类型:</label>
<div class="col-sm-8">
<select name="deviceTypeName" class="form-control m-b">
<option value="">所有</option>
</select>
<span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 代码生成请选择字典属性</span>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">设备模型图片:</label>
<div class="col-sm-8">
<input type="hidden" name="deviceMode" th:field="*{deviceMode}">
<div class="file-loading">
<input class="form-control file-upload" id="deviceMode" name="file" type="file">
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">设备规格:</label>
<div class="col-sm-8">
<input name="deviceSpe" th:field="*{deviceSpe}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">功能描述:</label>
<div class="col-sm-8">
<input name="deviceFunction" th:field="*{deviceFunction}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">设备参数:</label>
<div class="col-sm-8">
<input name="deviceParam" th:field="*{deviceParam}" class="form-control" type="text">
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: bootstrap-fileinput-js"/>
<script th:inline="javascript">
var prefix = ctx + "manage/base_device_info";
$("#form-base_device_info-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-base_device_info-edit').serialize());
}
}
$(".file-upload").each(function (i) {
var val = $("input[name='" + this.id + "']").val()
$(this).fileinput({
'uploadUrl': '/common/upload',
initialPreviewAsData: true,
initialPreview: [val],
maxFileCount: 1,
autoReplace: true
}).on('fileuploaded', function (event, data, previewId, index) {
$("input[name='" + event.currentTarget.id + "']").val(data.response.url)
}).on('fileremoved', function (event, id, index) {
$("input[name='" + event.currentTarget.id + "']").val('')
})
$(this).fileinput('_initFileActions');
});
</script>
</body>
</html>

@ -0,0 +1,37 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('新增视频监控信息管理')" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-base_monitor_info-add">
<div class="form-group">
<label class="col-sm-3 control-label is-required">监控名称:</label>
<div class="col-sm-8">
<input name="monitorName" class="form-control" type="text" required>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label is-required">设备IP</label>
<div class="col-sm-8">
<input name="monitorIp" class="form-control" type="text" required>
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "manage/base_monitor_info"
$("#form-base_monitor_info-add").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-base_monitor_info-add').serialize());
}
}
</script>
</body>
</html>

@ -0,0 +1,110 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
<th:block th:include="include :: header('视频监控信息管理列表')" />
</head>
<body class="gray-bg">
<div class="container-div">
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="formId">
<div class="select-list">
<ul>
<li>
<label>监控名称:</label>
<input type="text" name="monitorName"/>
</li>
<li>
<label>设备IP</label>
<input type="text" name="monitorIp"/>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="manage:base_monitor_info:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="manage:base_monitor_info:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="manage:base_monitor_info:remove">
<i class="fa fa-remove"></i> 删除
</a>
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="manage:base_monitor_info:export">
<i class="fa fa-download"></i> 导出
</a>
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('manage:base_monitor_info:edit')}]];
var removeFlag = [[${@permission.hasPermi('manage:base_monitor_info:remove')}]];
var prefix = ctx + "manage/base_monitor_info";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
removeUrl: prefix + "/remove",
exportUrl: prefix + "/export",
modalName: "视频监控信息管理",
columns: [{
checkbox: true
},
{
field: 'objid',
title: '主键',
visible: false
},
{
field: 'monitorName',
title: '监控名称'
},
{
field: 'monitorIp',
title: '设备IP'
},
{
field: 'createBy',
title: '创建人'
},
{
field: 'createTime',
title: '创建时间'
},
{
field: 'updateBy',
title: '更新人'
},
{
field: 'updateTime',
title: '更新时间'
},
{
title: '操作',
align: 'center',
formatter: function(value, row, index) {
var actions = [];
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.objid + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.objid + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join('');
}
}]
};
$.table.init(options);
});
</script>
</body>
</html>

@ -0,0 +1,38 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('修改视频监控信息管理')" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-base_monitor_info-edit" th:object="${baseMonitorInfo}">
<input name="objid" th:field="*{objid}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label is-required">监控名称:</label>
<div class="col-sm-8">
<input name="monitorName" th:field="*{monitorName}" class="form-control" type="text" required>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label is-required">设备IP</label>
<div class="col-sm-8">
<input name="monitorIp" th:field="*{monitorIp}" class="form-control" type="text" required>
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "manage/base_monitor_info";
$("#form-base_monitor_info-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-base_monitor_info-edit').serialize());
}
}
</script>
</body>
</html>
Loading…
Cancel
Save