Merge branch 'master' of http://113.200.75.45:82/monitor_v3/hg-monitor-web into master-V32-XuHaoJie
Showing
6 changed files
with
39 additions
and
74 deletions
@@ -3479,6 +3479,12 @@ layui.define(['laytpl', 'admin', 'form', 'table', 'echarts', 'sessions', 'xmSele | @@ -3479,6 +3479,12 @@ layui.define(['laytpl', 'admin', 'form', 'table', 'echarts', 'sessions', 'xmSele | ||
3479 | var num = res.object?res.object.ignoreCnt:""; | 3479 | var num = res.object?res.object.ignoreCnt:""; |
3480 | layer.prompt({id: "kpi_press_times_id", title: '压制次数', area: ['400px'], formType: 2}, | 3480 | layer.prompt({id: "kpi_press_times_id", title: '压制次数', area: ['400px'], formType: 2}, |
3481 | function (text, index) { | 3481 | function (text, index) { |
3482 | + // Start Wang 2022/2/16 11:15 #298 【告警压制】测试告警压制测试过长后端是否报错 | ||
3483 | + if(text > 10000){ | ||
3484 | + layer.msg("压制次数请设置为0-10000!", { offset: '15px' , icon: 7 , time: 1000 }); | ||
3485 | + return; | ||
3486 | + } | ||
3487 | + // End Wang 2022/2/16 11:16 | ||
3482 | obj['ignoreCnt'] = text | 3488 | obj['ignoreCnt'] = text |
3483 | admin.req({ | 3489 | admin.req({ |
3484 | url : common.domainName + '/api-web/manage/resource/res/kpi/ignore?access_token='+ layui.sessions.getToken().access_token | 3490 | url : common.domainName + '/api-web/manage/resource/res/kpi/ignore?access_token='+ layui.sessions.getToken().access_token |
@@ -386,7 +386,7 @@ layui.define(['table', 'form', 'laydate', 'laytpl','common','sessions','xmSelect | @@ -386,7 +386,7 @@ layui.define(['table', 'form', 'laydate', 'laytpl','common','sessions','xmSelect | ||
386 | var lastRowCell = JSON.parse(data.lastRowCell); | 386 | var lastRowCell = JSON.parse(data.lastRowCell); |
387 | layer.open({ | 387 | layer.open({ |
388 | type: '1' | 388 | type: '1' |
389 | - , title: '新增sheet页' | 389 | + , title: 'sheet页详情' |
390 | , btn: ["保存", "取消"] | 390 | , btn: ["保存", "取消"] |
391 | , area: ['80%', '90%'] | 391 | , area: ['80%', '90%'] |
392 | , shade: 0.3 | 392 | , shade: 0.3 |
@@ -167,7 +167,7 @@ | @@ -167,7 +167,7 @@ | ||
167 | <label class="col-md-4 control-label"><button type="button" class="layui-btn layui-btn-normal" id="contentResult">获取列信息</button></label> | 167 | <label class="col-md-4 control-label"><button type="button" class="layui-btn layui-btn-normal" id="contentResult">获取列信息</button></label> |
168 | </div> | 168 | </div> |
169 | </div> | 169 | </div> |
170 | - <div class="layui-form-item col-show-area"> | 170 | + <div class="layui-form-item col-show-area" style="height: 260px"> |
171 | <form onsubmit="return false" id="colNameForm"> | 171 | <form onsubmit="return false" id="colNameForm"> |
172 | <table class="layui-table"> | 172 | <table class="layui-table"> |
173 | <thead> | 173 | <thead> |
@@ -82,8 +82,8 @@ export default { | @@ -82,8 +82,8 @@ export default { | ||
82 | return arr.join(' / ') | 82 | return arr.join(' / ') |
83 | } | 83 | } |
84 | }, { | 84 | }, { |
85 | - prop: 'email', | ||
86 | - label: '电子邮箱', | 85 | + prop: 'education', |
86 | + label: '学历', | ||
87 | sortable: true, | 87 | sortable: true, |
88 | }, { | 88 | }, { |
89 | prop: 'state', | 89 | prop: 'state', |
@@ -32,30 +32,13 @@ | @@ -32,30 +32,13 @@ | ||
32 | </el-radio-group> | 32 | </el-radio-group> |
33 | </el-form-item> | 33 | </el-form-item> |
34 | </el-col> | 34 | </el-col> |
35 | - <el-col :span="8"> | ||
36 | - <el-form-item label="年龄" prop="age" class="form-class"> | ||
37 | - <el-input v-model="ruleForm.age" type="number" :readonly="isAdmin()"></el-input> | ||
38 | - </el-form-item> | ||
39 | - </el-col> | ||
40 | - </el-row> | ||
41 | 35 | ||
42 | - | ||
43 | - <el-row :gutter="5"> | ||
44 | - <el-col :span="8"> | ||
45 | - <el-form-item label="座机号码" prop="tel" class="form-class"> | ||
46 | - <el-input v-model="ruleForm.tel" :readonly="isAdmin()"></el-input> | ||
47 | - </el-form-item> | ||
48 | - </el-col> | ||
49 | <el-col :span="8"> | 36 | <el-col :span="8"> |
50 | <el-form-item label="手机号" prop="phone" class="form-class"> | 37 | <el-form-item label="手机号" prop="phone" class="form-class"> |
51 | <el-input v-model="ruleForm.phone" :readonly="isAdmin()"></el-input> | 38 | <el-input v-model="ruleForm.phone" :readonly="isAdmin()"></el-input> |
52 | </el-form-item> | 39 | </el-form-item> |
53 | </el-col> | 40 | </el-col> |
54 | - <el-col :span="8"> | ||
55 | - <el-form-item label="电子邮箱" prop="email" class="form-class"> | ||
56 | - <el-input v-model="ruleForm.email" id="email" :readonly="isAdmin()"></el-input> | ||
57 | - </el-form-item> | ||
58 | - </el-col> | 41 | + |
59 | </el-row> | 42 | </el-row> |
60 | 43 | ||
61 | <el-row :gutter="5"> | 44 | <el-row :gutter="5"> |
@@ -88,6 +71,8 @@ | @@ -88,6 +71,8 @@ | ||
88 | <el-date-picker | 71 | <el-date-picker |
89 | :readonly="isAdmin()" | 72 | :readonly="isAdmin()" |
90 | v-model="ruleForm.entryTime" | 73 | v-model="ruleForm.entryTime" |
74 | + format="YYYY-MM-DD" | ||
75 | + value-format="YYYY-MM-DD HH:mm:ss" | ||
91 | type="date" | 76 | type="date" |
92 | placeholder="选择日期"> | 77 | placeholder="选择日期"> |
93 | </el-date-picker> | 78 | </el-date-picker> |
@@ -98,6 +83,8 @@ | @@ -98,6 +83,8 @@ | ||
98 | <el-date-picker | 83 | <el-date-picker |
99 | v-model="ruleForm.quitTime" | 84 | v-model="ruleForm.quitTime" |
100 | :readonly="isAdmin()" | 85 | :readonly="isAdmin()" |
86 | + format="YYYY-MM-DD" | ||
87 | + value-format="YYYY-MM-DD HH:mm:ss" | ||
101 | type="date" | 88 | type="date" |
102 | placeholder="选择日期"> | 89 | placeholder="选择日期"> |
103 | </el-date-picker> | 90 | </el-date-picker> |
@@ -247,10 +247,8 @@ export default { | @@ -247,10 +247,8 @@ export default { | ||
247 | 247 | ||
248 | let ruleForm = Vue.ref({ | 248 | let ruleForm = Vue.ref({ |
249 | nickname: '', | 249 | nickname: '', |
250 | - sex: 0, | ||
251 | education: '', | 250 | education: '', |
252 | phone: '', | 251 | phone: '', |
253 | - email: '', | ||
254 | entryTime: '', | 252 | entryTime: '', |
255 | certificate: '', | 253 | certificate: '', |
256 | university: '', | 254 | university: '', |
@@ -261,7 +259,6 @@ export default { | @@ -261,7 +259,6 @@ export default { | ||
261 | projectId: null, | 259 | projectId: null, |
262 | quitTime: '', | 260 | quitTime: '', |
263 | state: '', | 261 | state: '', |
264 | - tel: '', | ||
265 | idcard:'', | 262 | idcard:'', |
266 | politicsStatus:'' | 263 | politicsStatus:'' |
267 | }) | 264 | }) |
@@ -311,38 +308,19 @@ export default { | @@ -311,38 +308,19 @@ export default { | ||
311 | * @returns {*} | 308 | * @returns {*} |
312 | */ | 309 | */ |
313 | const checkPhone= (rule, tel, callback) => { | 310 | const checkPhone= (rule, tel, callback) => { |
314 | - var mobile = /^1[3|5|8]\d{9}$/; | ||
315 | - if (!mobile.test(tel)) { | ||
316 | - return callback(new Error('请输入正确的手机号!')) | ||
317 | - }else{ | 311 | + var mobile = /^1[0-9]\d{9}$/; |
312 | + if (tel != '' && !mobile.test(tel)) { | ||
313 | + callback(new Error('请输入正确的手机号!')) | ||
314 | + } else { | ||
318 | callback(); | 315 | callback(); |
319 | } | 316 | } |
320 | } | 317 | } |
321 | - /** | ||
322 | - * @Author LH | ||
323 | - * @param rule | ||
324 | - * @param value | ||
325 | - * @param callback | ||
326 | - * @returns {*} | ||
327 | - */ | ||
328 | - const checkEmail= (rule, tel, callback) => { | ||
329 | - var reg = new RegExp("^[a-z0-9]+([._\\-]*[a-z0-9])*@([a-z0-9]+[-a-z0-9]*[a-z0-9]+.){1,63}[a-z0-9]+$"); //正则表达式 | ||
330 | - var obj = document.getElementById("email"); //要验证的对象 | ||
331 | - if(obj.value === ""){ //输入不能为空 | ||
332 | - //return callback(new Error('邮箱不能为空!')); | ||
333 | - callback() | ||
334 | - }else if(!reg.test(obj.value)){ //正则验证不通过,格式不对 | ||
335 | - return callback(new Error('邮箱格式不正确!')); | ||
336 | - }else{ | ||
337 | - callback() | ||
338 | - } | ||
339 | - } | ||
340 | const checkIdCard=(rule, idCard, callback) => { | 318 | const checkIdCard=(rule, idCard, callback) => { |
341 | var pattern = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/; | 319 | var pattern = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/; |
342 | - if (pattern.test(idCard)) { | ||
343 | - callback() | ||
344 | - }else{ | ||
345 | - return callback(new Error('身份证校验失败!')); | 320 | + if (idCard != '' && !pattern.test(idCard)) { |
321 | + callback(new Error('身份证校验失败!')); | ||
322 | + } else { | ||
323 | + callback(); | ||
346 | } | 324 | } |
347 | } | 325 | } |
348 | 326 | ||
@@ -357,18 +335,12 @@ export default { | @@ -357,18 +335,12 @@ export default { | ||
357 | phone: [ | 335 | phone: [ |
358 | { validator: checkPhone, trigger: 'blur' } | 336 | { validator: checkPhone, trigger: 'blur' } |
359 | ], | 337 | ], |
360 | - email: [ | ||
361 | - { validator: checkEmail, trigger: 'blur' } | ||
362 | - ], | ||
363 | company: [ | 338 | company: [ |
364 | { message:'请输入所在公司', trigger: 'blur' } | 339 | { message:'请输入所在公司', trigger: 'blur' } |
365 | ], | 340 | ], |
366 | idcard: [ | 341 | idcard: [ |
367 | - { validator:checkIdCard,message:'请输入身份证号', trigger: 'blur' } | ||
368 | - ], | ||
369 | - entryTime: [ | ||
370 | - { message: '请选择入职时间', trigger: 'blur' }, | ||
371 | - ], | 342 | + { validator:checkIdCard,message:'请输入正确的身份证号', trigger: 'blur'} |
343 | + ] | ||
372 | }); | 344 | }); |
373 | 345 | ||
374 | 346 | ||
@@ -378,21 +350,21 @@ export default { | @@ -378,21 +350,21 @@ export default { | ||
378 | */ | 350 | */ |
379 | // 保存用户信息 | 351 | // 保存用户信息 |
380 | let saveUser = () => { | 352 | let saveUser = () => { |
381 | - proxy.$refs.rule.validate((valid) => { | ||
382 | - if (valid) { | ||
383 | - console.log('submit!!'); | ||
384 | - proxy.$http.post("/api-web/bOpsPerson/saveOrUpdate", ruleForm.value, function (res) { | ||
385 | - if (res && res.code == 0) { | ||
386 | - proxy.$global.showMsg('保存成功!'); | ||
387 | - } | ||
388 | - }); | ||
389 | - } else { | ||
390 | - console.log('error submit!!'); | ||
391 | - return false; | ||
392 | - } | ||
393 | - }); | 353 | + proxy.$refs.rule.validate((valid) => { |
354 | + if (valid) { | ||
355 | + console.log('submit!!'); | ||
356 | + proxy.$http.post("/api-web/bOpsPerson/saveOrUpdate", ruleForm.value, function (res) { | ||
357 | + if (res && res.code == 0) { | ||
358 | + proxy.$global.showMsg('保存成功!'); | ||
359 | + } | ||
360 | + }); | ||
361 | + } else { | ||
362 | + console.log('error submit!!'); | ||
363 | + return false; | ||
364 | + } | ||
365 | + }); | ||
394 | 366 | ||
395 | - } | 367 | + } |
396 | 368 | ||
397 | 369 | ||
398 | let getFile = (param) => { | 370 | let getFile = (param) => { |
-
Please register or login to post a comment