Authored by xwx

Merge branch 'master-500-dev' of http://113.200.75.45:82/monitor_v3/hg-monitor-w…

…eb into master-500-dev-xwx
Showing 31 changed files with 624 additions and 154 deletions
... ... @@ -66,6 +66,14 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'xmSelect
time: 1000,
}, function () {
layer.closeAll()
table.reload('table-repair-view', {
where: {
access_token: accessToken,
createtime: "today",
viewMode: 'true',
dateLimit: ""
},
});
})
} else {
layer.msg(res.msg, {
... ... @@ -123,20 +131,6 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'xmSelect
$('#slt-repairadd-res').html(options);
form.render();
})
$.ajax({
url: domainName + '/api-web/workreport/getGroupByAdmin?theirType=1&access_token=' + accessToken,
success: function (res) {
if (!res.map) {
layer.msg("没有上传权限,请去添加权限")
return;
} else {
var map = res.map;
$("#createUser").val(map.admin);
}
fromAssignment()
form.render();
}
})
}
... ... @@ -184,7 +178,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'xmSelect
},
allDone: function (obj) {
//全部上传成功后
saveForm()
//saveForm()
},
error: function (index, upload) {
// 上传失败
... ... @@ -296,7 +290,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'xmSelect
//写入标签内容
function writeTagsInfo(id, name) {
var tags = '<span id="tags_span_' + id + '" data-id="' + id + '"><em>' + name + '</em>' +
'<button type="button" value="' + id + '" class="tagsclose close">×</button></span>';
'<button type="button" value="' + id + '" class="tags close">×</button></span>';
if ($("#tags_span_" + id).length == 0) {
//拼接标签
$("#selecte_content_id").append(tags);
... ...
... ... @@ -16,7 +16,7 @@ layui.define(['table', 'form', 'sessions', 'admin', 'common', 'echarts','laydate
var resTypeChart = echarts.init(document.getElementById('chart-restype-report'));
var dateLimit = ""
var createTime = "thisMonth"
var createTime = "today"
var currentResourceTypeTreeNodeId = ""
var resTypeSelect;
... ...
... ... @@ -169,7 +169,7 @@ layui.define(['common', 'admin', 'echarts', 'common', 'table', 'sessions'], func
grid: {
left: '3%',
right: '4%',
bottom: '3%',
bottom: '12%',//lsq 2022-03-10
top: '20',
containLabel: true
},
... ... @@ -184,7 +184,7 @@ layui.define(['common', 'admin', 'echarts', 'common', 'table', 'sessions'], func
color: '#000000',
show: true,
interval: 0,
rotate: 30,
rotate: 10,//lsq 2022-03-10 x轴标签不需要角度,注释
fontSize: '10',
},
}
... ... @@ -197,7 +197,7 @@ layui.define(['common', 'admin', 'echarts', 'common', 'table', 'sessions'], func
series: [
{
type: 'bar',
barWidth: '40%',
barWidth: '20',//lsq 2022-03-10 柱子宽度更改
data: line,
itemStyle: {
normal: {
... ... @@ -218,7 +218,18 @@ layui.define(['common', 'admin', 'echarts', 'common', 'table', 'sessions'], func
}
}
}
]
],
//start x轴拖动 lsq 2022-03-10
dataZoom: [
{
type: "slider",
realtime: true, //拖动滚动条时是否动态的更新图表数据
height: 25, //滚动条高度
start: 5, //滚动条开始位置(共100等份)
end: 55 //结束位置(共100等份)
}
],
//end lsq 2022-03-10
};
myChart.setOption(option)
}
... ...
... ... @@ -19,7 +19,7 @@ layui.define(['admin', 'form', 'table', 'element', 'sessions', 'common', 'echart
var currSelect = 0;
var list = [];
var dataList = [];
var date = '2021';
var date = new Date().getFullYear();
getChartData();
// loadAlarmOverChart1(alarmTrendChart,null,'24小时趋势表');
... ... @@ -41,7 +41,12 @@ layui.define(['admin', 'form', 'table', 'element', 'sessions', 'common', 'echart
$("#overview_time button").on("click",function () {
$("#overview_time button").removeClass("active");
$(this).addClass("active");
date = $(this).data("years");
// date = $(this).data("years");
if($(this).data("years")=='lastYear'){
date = new Date().getFullYear()-1;
}else if($(this).data("years")=='year'){
date=new Date().getFullYear();
}
if (currSelect === 0) {
loadResourceTable('resType','overviewResTypeTable');
} else if (currSelect === 1) {
... ...
//工作汇报表单
layui.define(['table', 'form', 'admin', 'layer', 'common','sessions','xmSelect'], function (exports) {
var $ = layui.$;
var form = layui.form;
var layer = layui.layer;
var admin = layui.admin;
var table = layui.table;
var common = layui.common;
var session = layui.sessions;
var domainName = common.domainName;
var xmSelect = layui.xmSelect;
//对外暴露的接口
exports('reportConfigAdd', function (data) {
var accessToken = session.getToken()['access_token']
var adminSelect = {}
var userSelect = {}
//下拉列表框初始化
initSelect()
//渲染表单
form.render(null, 'add-config-form');
//所属类型下拉框事件
form.on('select(config_theirType)', function(data){
if(data.value=='1'){
$('#config_receive_user').text('接收人');
}else{
$('#config_receive_user').text('授权用户');
}
});
//保存
form.on('submit(config-form-save-id)',function () {
var data = form.val('add-config-form')
delete data['select']
data.admin = adminSelect.getValue('valueStr')
data.adminName = adminSelect.getValue('nameStr')
data.user = userSelect.getValue('valueStr')
data.userName = userSelect.getValue('nameStr')
data.theirType=$('#config_theirType').val();
admin.req({
url: domainName + '/api-web/bWorkreportGroup/save?access_token=' + accessToken,
data: JSON.stringify(data),
type: 'post',
contentType: "application/json; charset=utf-8",
done: function (res) {
if (res.success) {
layer.msg(res.msg,{
offset: '15px',
icon: 1,
time: 1000,
},function() {
layer.closeAll()
table.reload('workReportConfigTable',{
adminName: '',
name: '',
userName: '',
})
initGroupSelect()
})
} else {
layer.msg(res.msg,{
offset: '15px',
icon: 7,
time: 1000,
})
}
}
})
return false
})
//表单验证
form.verify({
groupName: function(value, item){ //value:表单的值、item:表单的DOM对象
var count = 0
if (value == '') {
return "请输入名称"
}
admin.req({
url: domainName + `/api-web/bWorkreportGroup/checkName/${value}`,
async: false,
done: function (res) {
count = res.count
}
})
if (!data.id && count != 0) {
return "名称重复,请重新输入!!!"
}
}
});
//表单赋值
function fromAssignment() {
/*if (data && data.id) {
admin.req({
url: domainName + `/api-web/bWorkreportGroup/getById/${data.id}`,
done: function (res) {
form.val('add-config-form',res.object)
adminSelect.setValue(res.object.admin.split(","))
userSelect.setValue(res.object.user.split(","))
}
})
}*/
var url = `${domainName}/api-web/bWorkreportGroup/findManufacturerList?access_token=${accessToken}`;
$.ajax({
url:url,
success:function (res) {
var selects = res.data;
var $sel = $("form[name='add-config-form']").find("select[name='manufacturerId']");
$sel.append('<option value="">请选择</option>')
$.each(selects,function (i,e) {
$sel.append('<option value="'+e.id+'">'+e.manufacturerName+'</option>')
})
if (data && data.id) {
admin.req({
url: domainName + `/api-web/bWorkreportGroup/getById/${data.id}`,
done: function (res) {
form.val('add-config-form',res.object)
adminSelect.setValue(res.object.admin.split(","))
userSelect.setValue(res.object.user.split(","))
$('#config_theirType').val(res.object.theirType);
//更改接收人提示
if(res.object.theirType=='1'){
$('#config_receive_user').text('接收人');
}else{
$('#config_receive_user').text('授权用户');
}
}
})
}
form.render();
}
})
}
//初始化组负责人下拉列表框
function initSelect() {
$.ajax({
url: domainName + '/api-user/users/getAll?access_token=' + accessToken,
success: function (res) {
adminSelect = xmSelect.render({
el: '.admin',
radio: true,
clickClose: true,
filterable: true,
tips: '录入关键字模糊查找',
prop: {
name: 'nickname',
value: 'username'
},
layVerify: 'required',
layVerType: 'msg',
data: res,
})
userSelect = xmSelect.render({
el: '.user',
filterable: true,
tips: '录入关键字模糊查找',
prop: {
name: 'nickname',
value: 'username'
},
layVerify: 'required',
layVerType: 'msg',
data: res,
})
fromAssignment()
}
})
}
//初始化所属组列表
function initGroupSelect() {
$.ajax({
url: domainName + '/api-web/bWorkreportGroup/list?access_token=' + accessToken,
success: function (res) {
$("#groupName")[0].options.length=1
$.each(res.data, function (i, v) {
$('#groupName').append(new Option(v.name, v.name))
})
form.render('select')
}
})
}
})
})
\ No newline at end of file
... ...
//工作汇报配置
layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions'], function (exports) {
var $ = layui.$;
var form = layui.form;
var layer = layui.layer;
var admin = layui.admin;
var table = layui.table;
var common = layui.common;
var session = layui.sessions
var domainName = common.domainName;
//对外暴露的接口
exports("reportConfigIndex", function () {
var accessToken = session.getToken()['access_token']
initGroupSelect()
//回车搜索
$('#adminName').keydown(function (e) {
if (e.keyCode === 13) {
reloadConfigTable()
}
})
//回车搜索
$('#userName').keydown(function (e) {
if (e.keyCode === 13) {
reloadConfigTable()
}
})
//所属类型
form.on('select(theirType)', function () {
reloadConfigTable()
})
//绑定所属组
form.on('select(groupName)', function () {
reloadConfigTable()
})
//渲染表单元素
form.render(null, 'workReportConfig-from')
//新增
$('#workReport_config_add').on('click', function () {
openWorkReportConfigForm()
})
//批量删除
$('#workReport_config_delete').on('click', function () {
deleteConfig()
})
//渲染表格
var workReportConfigTable = table.render({
elem: '#workReportConfigTable',
url: domainName + '/api-web/bWorkreportGroup/page',
where: {
access_token: accessToken,
adminName: $('#adminName').val(),
name: $('#groupName').val(),
userName: $('#userName').val(),
theirType: $('#theirType').val(),
},
height: 'full-300',
page: {
layout: ['count', 'prev', 'page', 'next', 'limit', 'skip']
, theme: '#1E9FFF'//自定义分页主题颜色
},
end: function (e) {
form.render()
},
limit: common.limit,
limits: common.limits,
even: true,
cols: [[
{type: 'checkbox'},
{field: 'name', title: '配置名称', align: 'center', width: 150,},
{field: 'manufacturerName', title: '所属厂商', align: 'center', width: 150,},
{field: 'theirType', title: '所属类型', align: 'center', width: 150,
templet: function (d) {
if(d.theirType=='1'){
return '日志类型';
}else{
return '文档类型';
}
}
},
{
field: 'adminName', title: '汇报人', align: 'center', minWith: 300,
templet: '<div><span data-id="{{d.id}}" class="layui-table-link view-config-adminName">{{d.adminName}}</span></div>'
},
/* {
field: 'reportType', title: '汇报类型', align: 'center', width: 120,
templet: function (d) {
var typeName = ''
switch (d.reportType) {
case 'day':
typeName = '日报'
break;
case 'week':
typeName = '周报'
break;
case 'month':
typeName = '月报'
break;
}
return `<div><span>${typeName}</span></div>`
}
},*/
{
field: 'userName', title: '接收人', align: 'center', minWith: 150,
templet: '<div><span data-id="{{d.id}}" class="layui-table-link view-config-userName">{{d.userName}}</span></div>'
},
{
title: '操作', align: "center", width: 120,
templet: '<div><span data-id="{{d.id}}" class="layui-table-link delete-config-btn">删除</span></div>'
}
]],
done: function () {
//点击汇报人编辑表单
$('.view-config-adminName').on('click', function () {
openWorkReportConfigForm($(this).data('id'))
})
//点击获取接收人列表
$('.view-config-userName').on('click', function () {
openWorkReportList($(this).data('id'))
})
//删除事件
$('.delete-config-btn').on('click', function () {
deleteConfig($(this).data("id"))
})
}
})
//刷新表格
function reloadConfigTable() {
workReportConfigTable.reload({
where: {
access_token: accessToken,
adminName: $('#adminName').val(),
name: $('#groupName').val(),
userName: $('#userName').val(),
theirType: $('#theirType').val(),
},
})
}
//删除数据
function deleteConfig(id) {
if (typeof (id) != "string") {
var ids = [];
var data = table.checkStatus('workReportConfigTable').data;
if (data && data.length > 0) {
$.each(data, function (i, obj) {
ids.push(obj.id);
});
}
if (ids.length == 0) {
layer.msg('请选择要删除的数据', {icon: 7, time: 2000});
return;
}
id = ids.toString();
}
//确认提示框
layer.confirm('数据删除后将无法恢复,您确定要删除吗?', {
btn: ['确定', '取消'] //按钮
}, function () {
admin.req({
url: common.domainName + '/api-web/bWorkreportGroup/delete'
, type: "delete"
, data: {ids: id}
}).done(function (res) {
layer.msg('删除成功', {
offset: '15px'
, icon: 1
, time: 1000
}, function () {
reloadConfigTable();
initGroupSelect()
});
}).error(function (error) {
console.log(error);
});
});
}
//新增/编辑表单
function openWorkReportConfigForm(id) {
var title = id ? '编辑' : '新增'
common.openWin('workreport/configAdd', title, {id: id}, ['保存', '取消'], function f() {
$("#config-form-save-id").trigger("click");
});
}
//查看接收人列表
function openWorkReportList(id) {
var title = '接收人'
common.openWin('workreport/configList', title, {id: id}, ['确定', '取消'])
}
//初始化所属组列表
function initGroupSelect() {
$.ajax({
url: domainName + '/api-web/bWorkreportGroup/list?access_token=' + accessToken,
success: function (res) {
$("#groupName")[0].options.length=1
$.each(res.data, function (i, v) {
$('#groupName').append(new Option(v.name, v.name))
})
form.render('select')
}
})
}
//获取页面选中数据
function getCheckStatusData() {
return table.checkStatus('workReportConfigTable').data
}
return {reloadConfigTable, getCheckStatusData}
})
})
\ No newline at end of file
... ...
//工作汇报配置接收人
layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions'], function (exports) {
var $ = layui.$;
var form = layui.form;
var layer = layui.layer;
var admin = layui.admin;
var table = layui.table;
var common = layui.common;
var session = layui.sessions
var domainName = common.domainName;
//对外暴露的接口
exports("reportConfigList", function (d) {
var accessToken = session.getToken()['access_token']
//渲染收件人表格
var reportUserTable = table.render({
elem: '#reportUserTable',
url: domainName + '/api-web/bWorkreportGroup/getUserById',
where: {
access_token: accessToken,
id: d.id
},
height: 'full',
page: {
layout: ['count', 'prev', 'page', 'next', 'limit', 'skip']
, theme: '#1E9FFF'//自定义分页主题颜色
},
end: function (e) {
form.render()
},
limit: common.limit,
limits: common.limits,
even: true,
cols: [[
{type: 'numbers', title: '序号'},
{
field: 'username', title: '用户名', align: 'center', minWith: 120,
},
{
field: 'nickname', title: '姓名', align: 'center', minWith: 120,
},
{
field: 'sex', title: '性别', align: 'center', minWith: 120,
templet: function (d) {
var str = ''
if (d.sex == 0) {
str = '女'
} else {
str = '男'
}
return `<div><span>${str}</span></div>`
}
},
{
field: 'phone', title: '联系方式', align: 'center', minWith: 150,
},
{
field: 'orgName', title: '所属部门', align: 'center', width: 120,
}
]],
done: function () {
}
})
})
})
\ No newline at end of file
... ...
... ... @@ -408,7 +408,16 @@ layui.define(['table', 'form', 'sessions', 'admin', 'common', 'echarts','laydate
barGap: '-100%',
zlevel: 9,
color: '#2094ff'
}]
}],
dataZoom: [
{
type:"slider",
realtime:true,
height: 25,
start: 5,
end: 55
}
]
};
var lastWeekChart = echarts.init(document.getElementById('chart-daily-report'));
lastWeekChart.setOption(option);
... ... @@ -695,7 +704,17 @@ layui.define(['table', 'form', 'sessions', 'admin', 'common', 'echarts','laydate
show: false
}
}],
series: series
series: series,
dataZoom: [
{
type:"slider",
realtime:true,
height: 25,
start: 5,
end: 55
}
]
};
companyChart.setOption(option)
});
... ...
... ... @@ -238,8 +238,9 @@ layui.extend({
let path = router.path.join('/')
if(pathURL.indexOf('/user/login') != -1){
var loginIndex = 'default';
debugger
let loginSkin = sessionStorage.getItem("loginSkin");
if(loginSkin && ["default",'skin1','skin2'].indexOf(loginSkin)){
if(loginSkin && ["default",'skin1','skin2'].indexOf(loginSkin) != -1){
loginIndex = loginSkin;
}
... ... @@ -267,7 +268,7 @@ layui.extend({
// renderUrl = 'layout-nx';
// }
let userLayout = sessionStorage.getItem("userLayout");
if(userLayout && ['layout','layout-nx'].indexOf(userLayout)){
if(userLayout && ['layout','layout-nx'].indexOf(userLayout) != -1){
renderUrl = userLayout;
}
container.render(renderUrl).done(function(){
... ...
/* 首页图标 */
.monitor-home-home{
background: url('../img/menu/首页.png')!important;
width: 14px;
height: 14px;
background: url('../img/menu/home.png')!important;
width: 15px;
height: 15px;
margin-top: -7px !important;
}
.monitor-home-home:before{
... ... @@ -11,9 +11,9 @@
/*我的工作台*/
.monitor-home-template-1{
background: url('../img/menu/我的面板.png')!important;
width: 14px;
height: 14px;
background: url('../img/menu/mycard.png')!important;
width: 12px;
height: 12px;
margin-top: -7px !important;
}
.monitor-home-template-1:before{
... ... @@ -23,9 +23,9 @@
/*告警中心*/
.monitor-home-notice{
background: url('../img/menu/告警中心.png')!important;
width: 14px;
height: 14px;
background: url('../img/menu/warncenter.png')!important;
width: 15px;
height: 15px;
margin-top: -7px !important;
}
.monitor-home-notice:before{
... ... @@ -35,9 +35,9 @@
/*视图中心*/
.monitor-home-console{
background: url('../img/menu/视图中心.png')!important;
width: 14px;
height: 14px;
background: url('../img/menu/viewcenter.png')!important;
width: 15px;
height: 15px;
margin-top: -7px !important;
}
.monitor-home-console:before{
... ... @@ -47,9 +47,9 @@
/*运维管理*/
.monitor-home-release{
background: url('../img/menu/运维管理.png')!important;
width: 14px;
height: 14px;
background: url('../img/menu/ops.png')!important;
width: 15px;
height: 15px;
margin-top: -7px !important;
}
.monitor-home-release:before{
... ... @@ -59,9 +59,9 @@
/*智能巡检*/
.monitor-home-engine{
background: url('../img/menu/巡检.png')!important;
width: 14px;
height: 14px;
background: url('../img/menu/ins.png')!important;
width: 15px;
height: 15px;
margin-top: -7px !important;
}
.monitor-home-engine:before{
... ... @@ -71,9 +71,9 @@
/*综合监控*/
.monitor-home-chart{
background: url('../img/menu/综合监控.png')!important;
width: 14px;
height: 14px;
background: url('../img/menu/monitor.png')!important;
width: 15px;
height: 15px;
margin-top: -7px !important;
}
.monitor-home-chart:before{
... ... @@ -83,9 +83,9 @@
/*统计报表*/
.monitor-home-tabs{
background: url('../img/menu/统计报表.png')!important;
background: url('../img/menu/report.png')!important;
width: 14px;
height: 14px;
height: 16px;
margin-top: -7px !important;
}
.monitor-home-tabs:before{
... ... @@ -95,9 +95,9 @@
/*系统管理*/
.monitor-home-set-fill{
background: url('../img/menu/系统管理.png')!important;
width: 14px;
height: 14px;
background: url('../img/menu/sys.png')!important;
width: 15px;
height: 15px;
margin-top: -7px !important;
}
.monitor-home-set-fill:before{
... ... @@ -107,9 +107,9 @@
/*信息协同管理*/
.monitor-home-cols{
background: url('../img/menu/信息协同管理.png')!important;
width: 14px;
height: 14px;
background: url('../img/menu/mananager.png')!important;
width: 15px;
height: 15px;
margin-top: -7px !important;
}
.monitor-home-cols:before{
... ...
... ... @@ -69,8 +69,8 @@
<li>业务系统</li>
<li>业务域</li>
<div class="layui-btn-group time-group" id="overview_time" style="margin-left: 60%">
<button type="button" class="layui-btn layui-btn-primary layui-btn-sm" data-years="2020">去年</button>
<button type="button" class="layui-btn layui-btn-primary layui-btn-sm active" data-years="2021">今年</button>
<button type="button" class="layui-btn layui-btn-primary layui-btn-sm" data-years="lastYear">去年</button>
<button type="button" class="layui-btn layui-btn-primary layui-btn-sm active" data-years="year">今年</button>
</div>
<button class="layui-btn layui-btn-sm layui-btn-normal tab-button" id="btn_overview_export_excel">
<i class="layui-icon">&#xe60a;</i>导出到Excel
... ...
... ... @@ -12,7 +12,7 @@
<label class="layui-form-label">设备类型</label>
<div class="layui-input-inline">
<select name="resType" id="slt-repairadd-res"
lay-filter="slt-repairadd-res">
lay-filter="slt-repairadd-res" lay-verify="required">
<option value="">=设备类型=</option>
</select>
</div>
... ... @@ -20,7 +20,7 @@
<div class="layui-inline inline-half">
<label class="layui-form-label">设备序列号</label>
<div class="layui-input-inline">
<input type="text" class="layui-input" name="resourceSN" id="resourceSN">
<input type="text" class="layui-input" name="resourceSN" id="resourceSN" lay-verify="required">
</div>
</div>
</div>
... ... @@ -28,13 +28,13 @@
<div class="layui-inline inline-half">
<label class="layui-form-label">故障时间</label>
<div class="layui-input-inline">
<input type="text" class="layui-input" name="hitchtime" id="hitchtime">
<input type="text" class="layui-input" name="hitchtime" id="hitchtime" lay-verify="required">
</div>
</div>
<div class="layui-inline inline-half">
<label class="layui-form-label">维修时间</label>
<div class="layui-input-inline">
<input type="text" class="layui-input" name="createtime" id="createtime">
<input type="text" class="layui-input" name="createtime" id="createtime" lay-verify="required">
</div>
</div>
</div>
... ... @@ -42,13 +42,13 @@
<div class="layui-inline inline-half">
<label class="layui-form-label">标题</label>
<div class="layui-input-inline">
<input type="text" class="layui-input" name="title">
<input type="text" class="layui-input" name="title" >
</div>
</div>
<div class="layui-inline inline-half">
<label class="layui-form-label">汇报人</label>
<div class="layui-input-inline">
<input type="text" class="layui-input" name="createBy" id= "createUser" readonly="readonly">
<input type="text" class="layui-input" name="createBy" id= "createUser" readonly="readonly" >
</div>
</div>
</div>
... ... @@ -57,7 +57,7 @@
<label class="layui-form-label">归属单位</label>
<div class="layui-input-inline">
<select name="orgId" id="slt-repairadd-org"
lay-filter="slt-repairadd-org">
lay-filter="slt-repairadd-org" lay-verify="required">
<option value="">=归属单位=</option>
</select>
</div>
... ... @@ -66,7 +66,7 @@
<label class="layui-form-label">选择厂商</label>
<div class="layui-input-inline">
<select name="manufacturerId" id="slt-repairadd-group"
lay-filter="slt-repairadd-group" >
lay-filter="slt-repairadd-group" lay-verify="required" >
<option value="">=选择厂商=</option>
</select>
</div>
... ... @@ -76,13 +76,13 @@
<div class="layui-inline inline-half">
<label class="layui-form-label">受影响系统</label>
<div class="layui-input-inline">
<input type="text" class="layui-input" name="affected" id="affected">
<input type="text" class="layui-input" name="affected" id="affected" lay-verify="required">
</div>
</div>
<div class="layui-inline inline-half">
<label class="layui-form-label">所属ip</label>
<div class="layui-input-inline">
<input type="text" class="layui-input" name="ip" id="ip">
<input type="text" class="layui-input" name="ip" id="ip" lay-verify="required">
</div>
</div>
</div>
... ... @@ -109,25 +109,25 @@
<div class="layui-form-item">
<label class="layui-form-label textarea-label">故障现象描述</label>
<div class="layui-input-block">
<textarea class="layui-textarea" name="phenomenon"></textarea>
<textarea class="layui-textarea" name="phenomenon" lay-verify="required"></textarea>
</div>
</div>
<div class="layui-form-item">
<label class="layui-form-label textarea-label">解决过程描述</label>
<div class="layui-input-block">
<textarea class="layui-textarea" name="solveprocess"></textarea>
<textarea class="layui-textarea" name="solveprocess" lay-verify="required"></textarea>
</div>
</div>
<div class="layui-form-item">
<label class="layui-form-label textarea-label">处理结果</label>
<div class="layui-input-block">
<textarea class="layui-textarea" name="result"></textarea>
<textarea class="layui-textarea" name="result" lay-verify="required"></textarea>
</div>
</div>
<div class="layui-form-item">
<label class="layui-form-label textarea-label">经验总结</label>
<div class="layui-input-block">
<textarea class="layui-textarea" name="experience"></textarea>
<textarea class="layui-textarea" name="experience" lay-verify="required"></textarea>
</div>
</div>
<button type="submit" lay-submit lay-filter="repair-form-save-id" class="layui-btn hide"
... ...
... ... @@ -187,37 +187,3 @@
})
</script>
<style>
#add-repair-form .layui-form-label {
width: 120px;
/* padding: 8px 12px; */
text-align: left !important;
}
#add-repair-form .layui-input-block{
margin-left: 120px !important;
}
.tags{
margin-top:5px;
}
.tags span {
height: 20px;
margin-right: 10px;
margin-bottom: 3px;
padding: 5px 10px 5px 10px;
float: left;
white-space: nowrap;
color:#fff;
background-color:#009688;
text-shadow: 1px 1px 1px rgba(0, 0, 0, .15);
}
.tags .close {
font-weight: bold;
line-height: 20px;
margin-left:10px;
cursor: pointer;
text-align: center;
color: #fff;
border: 0 none;
background: transparent none repeat scroll 0 0;
}
</style>
... ...
... ... @@ -128,37 +128,4 @@
})
</script>
<style>
#add-repair-form .layui-form-label {
width: 120px;
/* padding: 8px 12px; */
text-align: left !important;
}
#add-repair-form .layui-input-block{
margin-left: 120px !important;
}
.tags{
margin-top:5px;
}
.tags span {
height: 20px;
margin-right: 10px;
margin-bottom: 3px;
padding: 5px 10px 5px 10px;
float: left;
white-space: nowrap;
color:#fff;
background-color:#009688;
text-shadow: 1px 1px 1px rgba(0, 0, 0, .15);
}
.tags .close {
font-weight: bold;
line-height: 20px;
margin-left:10px;
cursor: pointer;
text-align: center;
color: #fff;
border: 0 none;
background: transparent none repeat scroll 0 0;
}
</style>
... ...
... ... @@ -694,10 +694,7 @@ export default {
props.fileIds.push(document.id);
}
// Start Wang 2022/3/8 10:43 在乙方运维中上传文件后不弹出授权框
if(props.viewTypeId && props.viewTypeId != ''){
return;
}
// End Wang 2022/3/8 10:44
if(!props.viewTypeId && props.viewTypeId == ''){
// Start 上传成功后弹出授权弹框 LSQ 2022/1/12
setTimeout(function (){
if(dataList.value && dataList.value.length>0){
... ... @@ -711,6 +708,8 @@ export default {
},1500)
//End LSQ 2022/1/12
}
// End Wang 2022/3/8 10:44
// 执行回调
emit('callback', {document, fileInfo});
}
... ...
... ... @@ -721,6 +721,8 @@ layui.define(['tree', 'laypage', 'laytpl', 'admin', 'form', 'table', 'commonCols
});
commonCols.colsClickEvent();
resTopo();
// vmware 隐藏统计信息
$('#biz_virtual_platform_treeTable').next().find('.layui-table-tool').hide();
}
});
/*bizTableTreeVirtual.on('tool(tableEvent)',function (obj) {
... ...
... ... @@ -186,6 +186,7 @@ layui.define(['common', 'tree', 'laypage', 'laytpl', 'admin', 'form', 'table', '
//不带分页的列表
function renderTableList(resType) {
//渲染表格
var resTableList;
//获取配置的列
... ... @@ -940,7 +941,6 @@ layui.define(['common', 'tree', 'laypage', 'laytpl', 'admin', 'form', 'table', '
if(retCols){
cols = retCols;
}
parentResListTable = table.render({
elem: '#resListTable'
, id: 'resListTable'
... ... @@ -1067,6 +1067,14 @@ layui.define(['common', 'tree', 'laypage', 'laytpl', 'admin', 'form', 'table', '
if (retCols) {
cols = retCols;
}
var url=""
if(resType=='VIRTUALIZATION_VMWARE'){
url=common.domainName + '/api-web/home/virtual-res-list/' + resType
}else{
url =common.domainName + '/api-web/home/res-list/' + resType;
}
resListTable = table.render({
elem: '#resListTable'
, id: 'resListTable'
... ... @@ -1074,7 +1082,7 @@ layui.define(['common', 'tree', 'laypage', 'laytpl', 'admin', 'form', 'table', '
, toolbar: '#resList-top-head-info-tpl' //开启头部工具栏,并为其绑定左侧模板
, defaultToolbar: ['filter']
, drag: {toolbar: false}
, url: common.domainName + '/api-web/home/res-list/' + resType
, url: url
, where: {
access_token: accessToken,
resName: $("#resindex_keyword").val() !== '' ? $("#resindex_keyword").val() : id,
... ... @@ -1101,6 +1109,7 @@ layui.define(['common', 'tree', 'laypage', 'laytpl', 'admin', 'form', 'table', '
, limits: [150, 200, 300]
, cols: [cols]
, done: function (res, curr, count) {
soulTable.render(this)
//调用收藏方法
... ... @@ -1109,7 +1118,7 @@ layui.define(['common', 'tree', 'laypage', 'laytpl', 'admin', 'form', 'table', '
commonCols.colsClickEvent(editFlag);
loadRightResTypeSelectEvent(curTreeNode.id, "normal", res.obj);
loadRightResTypeSelectEvent(curTreeNode.id?curTreeNode.id: curTreeNode.data.id, "normal", res.obj);
//表格排序监听 joke add 20200408
table.on('sort(resListTable)', function (obj) {
... ... @@ -1397,6 +1406,7 @@ layui.define(['common', 'tree', 'laypage', 'laytpl', 'admin', 'form', 'table', '
}
//加载右侧资源类型下拉框
function loadRightResTypeSelectEvent(resType, type, obj) {
layer.closeAll('tips');
var str = '';
var domStr = 'resListContent'
... ...
... ... @@ -66,6 +66,7 @@ export default {
personId: personId,
code: code ? code : props.treeNode.map.nodeType.code
}
proxy.$http.get('/api-web/bOpsFile/search', params, function (res) {
if (res && res.code == 0 && res.data && res.data.length > 0) {
... ... @@ -104,6 +105,7 @@ export default {
fileUrl: document.localPath,
code: props.treeNode.map.nodeType.code
};
proxy.$http.post('/api-web/bOpsFile/fileSynchronization', params, function (res) {
if (res && res.code == 0) {
// proxy.$global.showMsg("");
... ...
... ... @@ -128,7 +128,8 @@ export default {
componentName.value = "DOCUMENT";
docType.value = "THREE_PERSONAGE_NDA";
docTypeName.value = "入场资料";
showDialog(true);
props.parentNode.id = row.id;
// showDialog(true);
},
render: function (row) {
if (row.personalSecrecyBook == "YES") {
... ... @@ -148,7 +149,9 @@ export default {
componentName.value = "DOCUMENT";
docType.value = "THREE_MONTHLY_SUMMARY";
docTypeName.value = "月度总结";
showDialog(true);
props.parentNode.id = row.id;
// showDialog(true);
},
render: function (row) {
if (row.monthlySummary == "YES") {
... ...
... ... @@ -167,7 +167,7 @@
<el-form-item label="配置信息" prop="name">
<el-input :size="$global.elementSize" v-model="treeNodeForm.options" clearable ></el-input>
</el-form-item>
<el-form-item label="CMDB资源类型" prop="name" style="text-align: left">
<el-form-item label="CMDB资源类型" prop="name" style="text-align: left" v-if="cmdbSystemIsOpen">
<el-select style="width: 100%" :size="$global.elementSize" v-model="treeNodeForm.cmdbResTypeId" placeholder="请选择CMDB资源类型!" clearable filterable >
<el-option
v-for="item in cmdbResTypeList"
... ...
... ... @@ -155,6 +155,8 @@ const treeNodeConfig = (currentNode) => {
cmdbResTypeId:''
});
let cmdbSystemIsOpen = Vue.ref(false);
let treeNodeFormRules = Vue.ref({});
let cmdbResTypeList = Vue.ref([]);
... ... @@ -179,12 +181,14 @@ const treeNodeConfig = (currentNode) => {
let getCmdbResTypeList = () =>{
if(cmdbResTypeList.value.length > 0){
if(cmdbResTypeList.value != null && cmdbResTypeList.value.length > 0){
return;
}
proxy.$http.get(`/api-web/v32/res/config/getCmdbResTypeList`, {}, function (res) {
if (res && res.success) {
if (res && res.success && res.data) {
cmdbResTypeList.value = res.data;
cmdbSystemIsOpen.value = true;
}
});
}
... ... @@ -208,7 +212,8 @@ const treeNodeConfig = (currentNode) => {
treeNodeForm,
treeNodeFormRules,
cmdbResTypeList,
getCmdbResTypeList
getCmdbResTypeList,
cmdbSystemIsOpen
}
}
... ... @@ -334,7 +339,8 @@ export default {
treeNodeForm,
treeNodeFormRules,
cmdbResTypeList,
getCmdbResTypeList
getCmdbResTypeList,
cmdbSystemIsOpen
} = treeNodeConfig(currentNode);
const {
... ... @@ -578,6 +584,7 @@ export default {
treeNodeFormRules,
cmdbResTypeList,
getCmdbResTypeList,
cmdbSystemIsOpen,
// 机房配置
machineRoomInfo,
... ...