Commit b352a552 authored by 赵啸非's avatar 赵啸非

修改前端页面与后台部分服务

parent a06f95be
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
<mapping directory="" vcs="Git" />
</component>
</project>
\ No newline at end of file
......@@ -29,7 +29,8 @@ CREATE TABLE `mortals_xhx_menu` (
`name` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '菜单名称',
`url` varchar(256) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '连接地址',
`parentId` bigint(20) NULL DEFAULT NULL COMMENT '父菜单ID,一级菜单的该字段值为-1',
`orderId` int(11) NULL DEFAULT NULL COMMENT '排序编号',
`ancestors` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '',
`orderId` int(9) NULL DEFAULT NULL COMMENT '排序编号',
`status` tinyint(2) NULL DEFAULT 1 COMMENT '菜单状态,0:禁用,1:启用,默认1',
`linkType` tinyint(2) NULL DEFAULT 0 COMMENT '链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0',
`groupId` int(11) NULL DEFAULT 1 COMMENT '分组编号,使用菜单分隔符按该值分隔,默认1',
......@@ -49,16 +50,16 @@ CREATE TABLE `mortals_xhx_menu` (
-- ----------------------------
-- Records of mortals_xhx_menu
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (91, '系统管理', '', 0, 9999, 1, 0, 0, NULL, 'setting', '', '', 0, 0, 3, NULL, NULL, '');
INSERT INTO `mortals_xhx_menu` VALUES (108, '区域信息', '/area/list', 91, 65, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9001, '主页', '/index', 90, 10, 1, 0, 1, NULL, '', NULL, NULL, 0, 0, 3, '2019-02-19 16:08:09', 1, 'admin');
INSERT INTO `mortals_xhx_menu` VALUES (9101, '用户信息', '/user/list', 91, 10, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9102, '角色信息', '/role/list', 91, 20, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9103, '资源信息', '/resource/list', 91, 30, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9104, '菜单信息', '/menu/list', 91, 40, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9105, '参数信息', '/param/list', 91, 50, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9106, '任务信息', '/task/list', 91, 60, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9107, '操作日志', '/oper/log/list', 91, 70, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (91, '系统管理', '', 0,'', 9999, 1, 0, 0, NULL, 'setting', '', '', 0, 0, 3, NULL, NULL, '');
INSERT INTO `mortals_xhx_menu` VALUES (108, '区域信息', '/area/list', 91,'', 65, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9001, '主页', '/index', 90,'', 10, 1, 0, 1, NULL, '', NULL, NULL, 0, 0, 3, '2019-02-19 16:08:09', 1, 'admin');
INSERT INTO `mortals_xhx_menu` VALUES (9101, '用户信息', '/user/list', 91,'', 10, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9102, '角色信息', '/role/list', 91,'', 20, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9103, '资源信息', '/resource/list', 91,'', 30, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9104, '菜单信息', '/menu/list', 91,'', 40, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9105, '参数信息', '/param/list', 91,'', 50, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9106, '任务信息', '/task/list', 91,'', 60, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (9107, '操作日志', '/oper/log/list', 91,'', 70, 1, 0, 0, NULL, NULL, NULL, NULL, 0, 0, 3, NULL, NULL, NULL);
-- ----------------------------
......
-- ----------------------------
-- 人员发现记录菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '人员发现记录', '/realtime/dataflow/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '人员发现记录', '/realtime/dataflow/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 人员发现记录资源路径 SQL
......@@ -17,7 +17,7 @@ INSERT INTO `mortals_xhx_param` VALUES (null, '是否预约', 'RealtimeDataflow'
-- ----------------------------
-- 预约签到记录菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '预约签到记录', '/appointment/records/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '预约签到记录', '/appointment/records/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 预约签到记录资源路径 SQL
......@@ -33,7 +33,7 @@ INSERT INTO `mortals_xhx_param` VALUES (null, '签到方式', 'AppointmentRecord
-- ----------------------------
-- 预约关怀记录菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '预约关怀记录', '/care/records/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '预约关怀记录', '/care/records/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 预约关怀记录资源路径 SQL
......@@ -44,13 +44,13 @@ INSERT INTO `mortals_xhx_resource` VALUES (null, '预约关怀记录-菜单管
-- ----------------------------
-- 预约关怀记录参数 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_param` VALUES (null, '办理状态', 'CareRecords', 'processStatus', '排队中.排队中', '排队中.排队中', 1, 4, 0, 'processStatus', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '办理状态', 'CareRecords', 'processStatus', '办理中.办理中', '办理中.办理中', 1, 4, 0, 'processStatus', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '办理状态', 'CareRecords', 'processStatus', '接件结束.接件结束', '接件结束.接件结束', 1, 4, 0, 'processStatus', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '办理状态', 'CareRecords', 'processStatus', '排队中', '排队中', 1, 4, 0, 'processStatus', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '办理状态', 'CareRecords', 'processStatus', '办理中', '办理中', 1, 4, 0, 'processStatus', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '办理状态', 'CareRecords', 'processStatus', '接件结束', '接件结束', 1, 4, 0, 'processStatus', NULL, NULL, NULL);
-- ----------------------------
-- 预约自动签到配置菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '预约自动签到配置', '/appointment/config/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '预约自动签到配置', '/appointment/config/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 预约自动签到配置资源路径 SQL
......@@ -80,7 +80,7 @@ INSERT INTO `mortals_xhx_param` VALUES (null, '周日是否监测', 'Appointment
-- ----------------------------
-- 预约自动签到配置时间段菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '预约自动签到配置时间段', '/appointment/config/times/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '预约自动签到配置时间段', '/appointment/config/times/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 预约自动签到配置时间段资源路径 SQL
......@@ -94,7 +94,7 @@ INSERT INTO `mortals_xhx_resource` VALUES (null, '预约自动签到配置时间
-- ----------------------------
-- 主动关怀配置菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '主动关怀配置', '/care/config/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '主动关怀配置', '/care/config/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 主动关怀配置资源路径 SQL
......@@ -121,12 +121,12 @@ INSERT INTO `mortals_xhx_param` VALUES (null, '周六是否监测', 'CareConfig'
INSERT INTO `mortals_xhx_param` VALUES (null, '周六是否监测', 'CareConfig', 'saturday', '1', '是', 1, 4, 0, 'saturday', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '周日是否监测', 'CareConfig', 'sunday', '0', '否', 1, 4, 0, 'sunday', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '周日是否监测', 'CareConfig', 'sunday', '1', '是', 1, 4, 0, 'sunday', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '消息发送对象', 'CareConfig', 'msgRecipients', '办事群众.办事群众', '办事群众.办事群众', 1, 4, 0, 'msgRecipients', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '消息发送对象', 'CareConfig', 'msgRecipients', '管理员.管理员', '管理员.管理员', 1, 4, 0, 'msgRecipients', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '消息发送对象', 'CareConfig', 'msgRecipients', '办事群众', '办事群众', 1, 4, 0, 'msgRecipients', NULL, NULL, NULL);
INSERT INTO `mortals_xhx_param` VALUES (null, '消息发送对象', 'CareConfig', 'msgRecipients', '管理员', '管理员', 1, 4, 0, 'msgRecipients', NULL, NULL, NULL);
-- ----------------------------
-- 主动关怀时间段菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '主动关怀时间段', '/care/config/times/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '主动关怀时间段', '/care/config/times/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 主动关怀时间段资源路径 SQL
......@@ -140,7 +140,7 @@ INSERT INTO `mortals_xhx_resource` VALUES (null, '主动关怀时间段-菜单
-- ----------------------------
-- 预约自动签到服务约束菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '预约自动签到服务约束', '/appointment/constraint/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '预约自动签到服务约束', '/appointment/constraint/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 预约自动签到服务约束资源路径 SQL
......@@ -158,7 +158,7 @@ INSERT INTO `mortals_xhx_param` VALUES (null, '是否约束 ', 'AppointmentConst
-- ----------------------------
-- 主动关怀服务约束菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '主动关怀服务约束', '/care/constraint/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '主动关怀服务约束', '/care/constraint/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 主动关怀服务约束资源路径 SQL
......@@ -176,7 +176,7 @@ INSERT INTO `mortals_xhx_param` VALUES (null, '是否追踪 ', 'CareConstraint',
-- ----------------------------
-- 主动关怀服务追踪菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '主动关怀服务追踪', '/care/constraint/track/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '主动关怀服务追踪', '/care/constraint/track/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 主动关怀服务追踪资源路径 SQL
......@@ -190,7 +190,7 @@ INSERT INTO `mortals_xhx_resource` VALUES (null, '主动关怀服务追踪-菜
-- ----------------------------
-- 注册人员菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '注册人员', '/person/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '注册人员', '/person/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 注册人员资源路径 SQL
......@@ -212,7 +212,7 @@ INSERT INTO `mortals_xhx_param` VALUES (null, '是否添加到海康人脸库',
-- ----------------------------
-- 设备业务菜单 SQL
-- ----------------------------
INSERT INTO `mortals_xhx_menu` VALUES (null, '设备业务', '/device/list', 0, 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
INSERT INTO `mortals_xhx_menu` VALUES (null, '设备业务', '/device/list', 0,'', 1, 1, 0, 0,'',NULL, NULL, NULL, 0, 0, 1, NULL, NULL, NULL);
-- ----------------------------
-- 设备业务资源路径 SQL
......
......@@ -102,7 +102,7 @@ PRIMARY KEY (`id`)
-- ----------------------------
DROP TABLE IF EXISTS `mortals_xhx_appointment_config_times`;
CREATE TABLE mortals_xhx_appointment_config_times(
`Id` bigint(20) AUTO_INCREMENT COMMENT '序号,主键,自增长',
`id` bigint(20) AUTO_INCREMENT COMMENT '序号,主键,自增长',
`aotoCheckCfgId` bigint(20) COMMENT '自动签到配置id',
`serviceTimeStart` datetime NOT NULL COMMENT '时间段时候开始时间',
`serviceTimeEnd` datetime NOT NULL COMMENT '时间段结束时间',
......@@ -111,7 +111,7 @@ CREATE TABLE mortals_xhx_appointment_config_times(
`createTime` datetime NOT NULL COMMENT '创建时间',
`updateUserId` bigint(20) COMMENT '更新用户',
`updateTime` datetime COMMENT '更新时间',
PRIMARY KEY (`Id`)
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='预约自动签到配置时间段';
-- ----------------------------
-- 主动关怀配置表
......@@ -145,7 +145,7 @@ PRIMARY KEY (`id`)
-- ----------------------------
DROP TABLE IF EXISTS `mortals_xhx_care_config_times`;
CREATE TABLE mortals_xhx_care_config_times(
`Id` bigint(20) AUTO_INCREMENT COMMENT '序号,主键,自增长',
`id` bigint(20) AUTO_INCREMENT COMMENT '序号,主键,自增长',
`careCfgId` bigint(20) COMMENT '主动关怀配置id',
`serviceTimeStart` datetime NOT NULL COMMENT '时间段时候开始时间',
`serviceTimeEnd` datetime NOT NULL COMMENT '时间段结束时间',
......@@ -154,7 +154,7 @@ CREATE TABLE mortals_xhx_care_config_times(
`createTime` datetime NOT NULL COMMENT '创建时间',
`updateUserId` bigint(20) COMMENT '更新用户',
`updateTime` datetime COMMENT '更新时间',
PRIMARY KEY (`Id`)
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='主动关怀时间段';
-- ----------------------------
-- 预约自动签到服务约束表
......
platform-eleme
eleme
delete-solid
delete
s-tools
setting
user-solid
user
phone
phone-outline
more
more-outline
star-on
star-off
s-goods
goods
warning
warning-outline
question
info
remove
circle-plus
success
error
zoom-in
zoom-out
remove-outline
circle-plus-outline
circle-check
circle-close
s-help
help
minus
plus
check
close
picture
picture-outline
picture-outline-round
upload
upload2
download
camera-solid
camera
video-camera-solid
video-camera
message-solid
bell
s-cooperation
s-order
s-platform
s-fold
s-unfold
s-operation
s-promotion
s-home
s-release
s-ticket
s-management
s-open
s-shop
s-marketing
s-flag
s-comment
s-finance
s-claim
s-custom
s-opportunity
s-data
s-check
s-grid
menu
share
d-caret
caret-left
caret-right
caret-bottom
caret-top
bottom-left
bottom-right
back
right
bottom
top
top-left
top-right
arrow-left
arrow-right
arrow-down
arrow-up
d-arrow-left
d-arrow-right
video-pause
video-play
refresh
refresh-right
refresh-left
finished
sort
sort-up
sort-down
rank
loading
view
c-scale-to-original
date
edit
edit-outline
folder
folder-opened
folder-add
folder-remove
folder-delete
folder-checked
tickets
document-remove
document-delete
document-copy
document-checked
document
document-add
printer
paperclip
takeaway-box
search
monitor
attract
mobile
scissors
umbrella
headset
brush
mouse
coordinate
magic-stick
reading
data-line
data-board
pie-chart
data-analysis
collection-tag
film
suitcase
suitcase-1
receiving
collection
files
notebook-1
notebook-2
toilet-paper
office-building
school
table-lamp
house
no-smoking
smoking
shopping-cart-full
shopping-cart-1
shopping-cart-2
shopping-bag-1
shopping-bag-2
sold-out
sell
present
box
bank-card
money
coin
wallet
discount
price-tag
news
guide
male
female
thumb
cpu
link
connection
open
turn-off
set-up
chat-round
chat-line-round
chat-square
chat-dot-round
chat-dot-square
chat-line-square
message
postcard
position
turn-off-microphone
microphone
close-notification
bangzhu
time
odometer
crop
aim
switch-button
full-screen
copy-document
mic
stopwatch
medal-1
medal
trophy
trophy-1
first-aid-kit
discover
place
location
location-outline
location-information
add-location
delete-location
map-location
alarm-clock
timer
watch-1
watch
lock
unlock
key
service
mobile-phone
bicycle
truck
ship
basketball
football
soccer
baseball
wind-power
light-rain
lightning
heavy-rain
sunrise
sunrise-1
sunset
sunny
cloudy
partly-cloudy
cloudy-and-sunny
moon
moon-night
dish
dish-1
food
chicken
fork-spoon
knife-fork
burger
tableware
sugar
dessert
ice-cream
hot-water
water-cup
coffee-cup
cold-drink
goblet
goblet-full
goblet-square
goblet-square-full
refrigerator
grape
watermelon
cherry
apple
pear
orange
coffee
ice-tea
ice-drink
milk-tea
potato-strips
lollipop
ice-cream-square
ice-cream-round
......@@ -47,8 +47,6 @@ export default {
this.form = Object.assign({}, this.form, res.entity);
this.dict = Object.assign({}, this.dict, res.dict);
console.log(this.form)
this.afterRender(res);
})
.catch(error => {
......
......@@ -103,6 +103,33 @@ const find = (list, key, val) => {
}
}
/**
* 构造树型结构数据
* @param {*} data 数据源
* @param {*} id id字段 默认 'id'
* @param {*} parentId 父节点字段 默认 'parentId'
* @param {*} children 孩子节点字段 默认 'children'
* @param {*} rootId 根Id 默认 0
*/
function handleTree(data, id, parentId, children, rootId) {
id = id || 'id'
parentId = parentId || 'parentId'
children = children || 'children'
rootId = rootId || Math.min.apply(Math, data.map(item => { return item[parentId] })) || 0
//对源数据深度克隆
const cloneData = JSON.parse(JSON.stringify(data))
//循环所有项
const treeData = cloneData.filter(father => {
let branchArr = cloneData.filter(child => {
//返回每一项的子级数组
return father[id] === child[parentId]
});
branchArr.length > 0 ? father.children = branchArr : '';
//返回第一层
return father[parentId] === rootId;
});
return treeData != '' ? treeData : data;
};
export {
formatter,
......@@ -110,4 +137,5 @@ export {
formatterDate,
formatterDateOnly,
find,
handleTree
};
......@@ -69,15 +69,15 @@ export default {
let urlArray = this.$route.path.split('/');
const type = urlArray.pop();
group.unshift({
name: "政务在线考试学习系统"
})
if(types[type]) {
group.push({
name: types[type]
})
}
console.log("group",group)
// group.unshift({
// name: "智慧大厅系统"
// })
// if(types[type]) {
// group.push({
// name: types[type]
// })
// }
// console.log("group",group)
return group
},
menu() {
......
......@@ -8,7 +8,7 @@
</template>
<style lang="less">
@media screen and (max-width: 800px){
@media screen and (max-width: 1440px){
.layout-form{
form{
width: 100%!important;
......@@ -25,7 +25,7 @@
border-bottom: 1px solid #ededed;
}
form{
width: 800px;
width: 1440px;
&[loading]{
pointer-events: none;
.el-button{
......
<template>
<!-- 弹出框表单 -->
<el-dialog :title="title" :visible.sync="open" width="90%" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-form ref="form" :model="form" :rules="rules" label-width="200px">
<el-row>
<Field label="站点Id" prop="siteId" v-model="form.siteId" placeholder="请输入站点Id"/>
<Field label="站点名称" prop="siteName" v-model="form.siteName" type="textarea" placeholder="请输入站点名称"/>
<Field label="是否启用该服务" prop="used" v-model="form.used" type="select" :enumData="dict.used" placeholder="请选择是否启用该服务"/>
<Field label="周一是否监测" prop="monday" v-model="form.monday" type="select" :enumData="dict.monday" placeholder="请选择周一是否监测"/>
<Field label="周二是否监测" prop="tuesday" v-model="form.tuesday" type="select" :enumData="dict.tuesday" placeholder="请选择周二是否监测"/>
<Field label="周三是否监测" prop="wednesday" v-model="form.wednesday" type="select" :enumData="dict.wednesday" placeholder="请选择周三是否监测"/>
<Field label="周四是否监测" prop="thursday" v-model="form.thursday" type="select" :enumData="dict.thursday" placeholder="请选择周四是否监测"/>
<Field label="周五是否监测" prop="friday" v-model="form.friday" type="select" :enumData="dict.friday" placeholder="请选择周五是否监测"/>
<Field label="周六是否监测" prop="saturday" v-model="form.saturday" type="select" :enumData="dict.saturday" placeholder="请选择周六是否监测"/>
<Field label="周日是否监测" prop="sunday" v-model="form.sunday" type="select" :enumData="dict.sunday" placeholder="请选择周日是否监测"/>
<Field label="单日服务最大人数设置" prop="maxServicePersonNum" v-model="form.maxServicePersonNum" placeholder="请输入单日服务最大人数设置"/>
<Field label="累计服务频次预警" prop="alertServiceNum" v-model="form.alertServiceNum" placeholder="请输入累计服务频次预警"/>
<Field label="备注" prop="remark" v-model="form.remark" type="textarea" placeholder="请输入备注"/>
<Field :span="20" label="是否启用该服务" prop="used" v-model="form.used" type="radio" :enumData="dict.used" placeholder="请选择是否启用该服务"/>
<Field :span="20" label="监测周期配置">
<el-checkbox
true-label="1"
false-label="0"
v-model="form.monday"
>周一</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.tuesday"
>周二</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.wednesday"
>周三</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.thursday"
>周四</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.friday"
>周五</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.saturday"
>周六</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.sunday"
>周日</el-checkbox>
</Field>
<Field :span="20" label="单日服务最大人数设置" prop="maxServicePersonNum" v-model="form.maxServicePersonNum" placeholder="请输入单日服务最大人数设置"/>
<Field :span="20" label="累计服务频次预警" prop="alertServiceNum" v-model="form.alertServiceNum" placeholder="请输入累计服务频次预警"/>
<Field :span="20" label="备注" prop="remark" v-model="form.remark" type="textarea" placeholder="请输入备注"/>
</el-row>
<el-divider content-position="center">预约自动签到配置时间段信息</el-divider>
<br/>
<el-row :gutter="10" class="mb8">
......@@ -32,14 +72,37 @@
<el-table :data="appointmentConfigTimesList" :row-class-name="rowAppointmentConfigTimesIndex" @selection-change="handleAppointmentConfigTimesSelectionChange" ref="appointmentConfigTimes">
<el-table-column type="selection" width="50" align="center" />
<el-table-column label="序号" align="center" prop="index" width="50"/>
<el-table-column label="时间段时候开始时间" prop="serviceTimeStart">
<el-table-column label="开始时间" prop="serviceTimeStart">
<template slot-scope="scope">
<el-input v-model="scope.row.serviceTimeStart" placeholder="请输入时间段时候开始时间" />
<el-time-select
placeholder="起始时间"
v-model="scope.row.serviceTimeStart"
value-format="yyyy-MM-dd HH:mm:ss"
format="HH:mm"
:picker-options="{
start: '08:00',
step: '00:30',
end: '18:00'
}">
</el-time-select>
<!-- <el-input v-model="scope.row.serviceTimeStart" placeholder="请输入时间段时候开始时间" />-->
</template>
</el-table-column>
<el-table-column label="时间段结束时间" prop="serviceTimeEnd">
<el-table-column label="结束时间" prop="serviceTimeEnd">
<template slot-scope="scope">
<el-input v-model="scope.row.serviceTimeEnd" placeholder="请输入时间段结束时间" />
<el-time-select
placeholder="结束时间"
value-format="yyyy-MM-dd HH:mm:ss"
v-model="scope.row.serviceTimeEnd"
:picker-options="{
start: '08:00',
step: '00:30',
end: '18:00'
}">
</el-time-select>
<!-- <el-input v-model="scope.row.serviceTimeEnd" placeholder="请输入时间段结束时间" />-->
</template>
</el-table-column>
<el-table-column label="备注" prop="remark">
......@@ -47,26 +110,6 @@
<el-input v-model="scope.row.remark" placeholder="请输入备注" />
</template>
</el-table-column>
<el-table-column label="创建用户" prop="createUserId">
<template slot-scope="scope">
<el-input v-model="scope.row.createUserId" placeholder="请输入创建用户" />
</template>
</el-table-column>
<el-table-column label="创建时间" prop="createTime">
<template slot-scope="scope">
<el-input v-model="scope.row.createTime" placeholder="请输入创建时间" />
</template>
</el-table-column>
<el-table-column label="更新用户" prop="updateUserId">
<template slot-scope="scope">
<el-input v-model="scope.row.updateUserId" placeholder="请输入更新用户" />
</template>
</el-table-column>
<el-table-column label="更新时间" prop="updateTime">
<template slot-scope="scope">
<el-input v-model="scope.row.updateTime" placeholder="请输入更新时间" />
</template>
</el-table-column>
</el-table>
</el-form>
......@@ -78,6 +121,7 @@
</template>
<script>
import moment from 'moment';
import form from "@/assets/mixins/formdialog";
import dialogShow from "./dialogshow";
export default {
......@@ -153,6 +197,10 @@
// 渲染前置处理
beforeRender(data) {
if(data.entity.appointmentConfigTimesList) {
data.entity.appointmentConfigTimesList.map(i=>{
i.serviceTimeStart = moment(i.serviceTimeStart).format('HH:mm')
i.serviceTimeEnd = moment(i.serviceTimeEnd).format('HH:mm')
})
this.appointmentConfigTimesList = data.entity.appointmentConfigTimesList;
}
return data
......@@ -191,6 +239,15 @@
afterRender(data) {
this.open = true;
},
beforeSubmit(data) {
data.appointmentConfigTimesList.map(i=>{
const serviceTimeStart = moment(i.serviceTimeStart, 'HH:mm');
const serviceTimeEnd = moment(i.serviceTimeEnd, 'HH:mm');
i.serviceTimeStart = moment().set({hour: serviceTimeStart.hour(), minute: serviceTimeStart.minute()}).format('yyyy-MM-DD HH:mm:ss');
i.serviceTimeEnd = moment().set({hour: serviceTimeEnd.hour(), minute: serviceTimeEnd.minute()}).format('yyyy-MM-DD HH:mm:ss');
})
return data
},
afterSubmit(data) {
this.open = false;
......@@ -211,7 +268,7 @@
saturday : 0,
sunday : 0,
maxServicePersonNum : 0,
alertServiceNum : null,
alertServiceNum : 0,
remark : "",
};
this.resetForm("form");
......
......@@ -68,32 +68,28 @@
{type: "selection", width: 60},
{type: "index",label: "序号",width: 50},
{label: "站点Id", prop: "siteId", formatter: this.formatter},
{label: "启用", prop: "used",formatter: this.formatter},
{label: "站点名称", prop: "siteName"},
{label: "周一", prop: "monday",formatter: this.formatter},
{label: "是否启用该服务", prop: "used",formatter: this.formatter},
{label: "周二", prop: "tuesday",formatter: this.formatter},
{label: "一是否监测", prop: "monday",formatter: this.formatter},
{label: "", prop: "wednesday",formatter: this.formatter},
{label: "二是否监测", prop: "tuesday",formatter: this.formatter},
{label: "", prop: "thursday",formatter: this.formatter},
{label: "三是否监测", prop: "wednesday",formatter: this.formatter},
{label: "", prop: "friday",formatter: this.formatter},
{label: "四是否监测", prop: "thursday",formatter: this.formatter},
{label: "", prop: "saturday",formatter: this.formatter},
{label: "五是否监测", prop: "friday",formatter: this.formatter},
{label: "", prop: "sunday",formatter: this.formatter},
{label: "周六是否监测", prop: "saturday",formatter: this.formatter},
{label: "最大人数", prop: "maxServicePersonNum"},
{label: "周日是否监测", prop: "sunday",formatter: this.formatter},
{label: "累计预警", prop: "alertServiceNum"},
{label: "单日服务最大人数设置", prop: "maxServicePersonNum",formatter: this.formatter},
{label: "累计服务频次预警", prop: "alertServiceNum",formatter: this.formatter},
{label: "创建用户", prop: "createUserId", formatter: this.formatter},
{label: "预约自动签到配置时间段",
{label: "创建时间", prop: "createUserTime", formatter: this.formatterDate},
{label: "配置时间段",
width: 120,
prop: "subColumns",
formatter: (row) => {
......
<template>
<layout-form>
<el-form :model="form" :loading="loading" :rules="rules" size='small' style="width:100%" label-width='120px' ref="form">
<el-row>
<Field :sapn="24" label="是否启用该服务" prop="used" v-model="form.used" type="select" :enumData="dict.used" placeholder="请选择是否启用该服务"/>
<el-row>
<Field :span="4" label="周一">
<el-checkbox
true-label="1"
false-label="0"
v-model="form.monday"
></el-checkbox>
</Field>
<Field :span="4" label="周二">
<el-checkbox
true-label="1"
false-label="0"
v-model="form.tuesday"
></el-checkbox>
</Field>
<Field :span="4" label="周三">
<el-checkbox
true-label="1"
false-label="0"
v-model="form.tuesday"
></el-checkbox>
</Field>
<Field :span="4" label="周四">
<el-checkbox
true-label="1"
false-label="0"
v-model="form.thursday"
></el-checkbox>
</Field>
</el-row>
<Field label="周一是否监测" prop="monday" v-model="form.monday" type="select" :enumData="dict.monday" placeholder="请选择周一是否监测"/>
<Field label="周二是否监测" prop="tuesday" v-model="form.tuesday" type="select" :enumData="dict.tuesday" placeholder="请选择周二是否监测"/>
<Field label="周三是否监测" prop="wednesday" v-model="form.wednesday" type="select" :enumData="dict.wednesday" placeholder="请选择周三是否监测"/>
<Field label="周四是否监测" prop="thursday" v-model="form.thursday" type="select" :enumData="dict.thursday" placeholder="请选择周四是否监测"/>
<Field label="周五是否监测" prop="friday" v-model="form.friday" type="select" :enumData="dict.friday" placeholder="请选择周五是否监测"/>
<Field label="周六是否监测" prop="saturday" v-model="form.saturday" type="select" :enumData="dict.saturday" placeholder="请选择周六是否监测"/>
<Field label="周日是否监测" prop="sunday" v-model="form.sunday" type="select" :enumData="dict.sunday" placeholder="请选择周日是否监测"/>
<Field label="单日服务最大人数设置" prop="maxServicePersonNum" v-model="form.maxServicePersonNum" placeholder="请输入单日服务最大人数设置"/>
<Field label="累计服务频次预警" prop="alertServiceNum" v-model="form.alertServiceNum" placeholder="请输入累计服务频次预警"/>
<Field label="备注" prop="remark" v-model="form.remark" type="textarea" placeholder="请输入备注"/>
</el-row>
<el-divider content-position="center">预约自动签到配置时间段信息</el-divider>
<br/>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-plus" size="mini" @click="handleAddAppointmentConfigTimes">添加</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="danger" icon="el-icon-delete" size="mini" @click="handleDeleteAppointmentConfigTimes">删除</el-button>
</el-col>
</el-row>
<el-table :data="appointmentConfigTimesList" :row-class-name="rowAppointmentConfigTimesIndex" @selection-change="handleAppointmentConfigTimesSelectionChange" ref="appointmentConfigTimes">
<el-table-column type="selection" width="50" align="center" />
<el-table-column label="序号" align="center" prop="index" width="50"/>
<el-table-column label="备注" prop="serviceTimeStart">
<template slot-scope="scope">
<el-input v-model="scope.row.serviceTimeStart" placeholder="请输入备注" />
</template>
</el-table-column>
<el-table-column label="备注" prop="serviceTimeEnd">
<template slot-scope="scope">
<el-input v-model="scope.row.serviceTimeEnd" placeholder="请输入备注" />
</template>
</el-table-column>
<el-table-column label="备注" prop="remark">
<template slot-scope="scope">
<el-input v-model="scope.row.remark" placeholder="请输入备注" />
</template>
</el-table-column>
</el-table>
<form-buttons @submit='submitForm' :noSaveBtn="pageInfo.type === 'view'"/>
</el-form>
</layout-form>
</template>
<script>
import form from "@/assets/mixins/form";
export default {
mixins: [form],
components: {
},
methods: {
/** 预约自动签到配置时间段序号 */
rowAppointmentConfigTimesIndex({ row, rowIndex }) {
row.index = rowIndex + 1;
},
/** 预约自动签到配置时间段添加按钮操作 */
handleAddAppointmentConfigTimes() {
let obj = {};
obj.serviceTimeStart = "";
obj.serviceTimeEnd = "";
obj.remark = "";
obj.createUserId = "";
obj.createTime = "";
obj.updateUserId = "";
obj.updateTime = "";
this.appointmentConfigTimesList.push(obj);
},
/** 预约自动签到配置时间段删除按钮操作 */
handleDeleteAppointmentConfigTimes() {
if (this.checkedAppointmentConfigTimes.length == 0) {
this.$alert("请先选择要删除的预约自动签到配置时间段数据", "提示", { confirmButtonText: "确定", });
} else {
this.appointmentConfigTimesList.splice(this.checkedAppointmentConfigTimes[0].index - 1, 1);
}
},
/** 单选框选中数据 */
handleAppointmentConfigTimesSelectionChange(selection) {
if (selection.length > 1) {
this.$refs.appointmentConfigTimes.clearSelection();
this.$refs.appointmentConfigTimes.toggleRowSelection(selection.pop());
} else {
this.checkedAppointmentConfigTimes = selection;
}
},
// 渲染前置处理
beforeRender(data) {
if(data.entity.appointmentConfigTimesList) {
this.appointmentConfigTimesList = data.entity.appointmentConfigTimesList;
}
return data
},
},
data() {
return {
toString:[
"used",
"monday",
"tuesday",
"wednesday",
"thursday",
"friday",
"saturday",
"sunday",
],
// 子表选中数据
checkedAppointmentConfigTimes: [],
// 预约自动签到配置时间段表格数据
appointmentConfigTimesList: [],
rules: {
createTime: [
{required: true,message: "请选择创建时间" },
],
}
};
}
};
</script>
<template>
<!-- 弹出框表单 -->
<el-dialog :title="title" :visible.sync="open" width="90%" append-to-body>
<el-dialog :title="title" :visible.sync="open" width="50%" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-row>
<Field label="站点Id" prop="siteId" v-model="form.siteId" placeholder="请输入站点Id"/>
<Field label="站点名称" prop="siteName" v-model="form.siteName" type="textarea" placeholder="请输入站点名称"/>
<Field label="个人信息ID" prop="personId" v-model="form.personId" placeholder="请输入个人信息ID"/>
<Field label="姓名" prop="name" v-model="form.name" placeholder="请输入姓名"/>
<Field label="联系方式" prop="contact" v-model="form.contact" placeholder="请输入联系方式"/>
<Field label="证件类型" prop="idCardType" v-model="form.idCardType" placeholder="请输入证件类型"/>
<Field label="证件号码" prop="idCardNo" v-model="form.idCardNo" placeholder="请输入证件号码"/>
<Field label="累计次数" prop="accumulative" v-model="form.accumulative" placeholder="请输入累计次数"/>
<Field label="约束时间" prop="constraintTime" v-model="form.constraintTime" type="date" />
<Field label="创建方式" prop="createMethod" v-model="form.createMethod" type="select" :enumData="dict.createMethod" placeholder="请选择创建方式"/>
<Field label="操作人员" prop="operator" v-model="form.operator" placeholder="请输入操作人员"/>
<Field label="是否约束 " prop="constraint" v-model="form.constraint" type="select" :enumData="dict.constraint" placeholder="请选择是否约束 "/>
<Field :span="20" label="个人信息" prop="personId" v-model="form.personId" style="width:100%" type="select" :enumData="dict.personId" placeholder="请输入个人信息ID"/>
<Field :span="20" label="联系方式" prop="contact" v-model="form.contact" placeholder="请输入联系方式"/>
<Field :span="20" label="证件类型" prop="idCardType" v-model="form.idCardType" type="radio" :enumData="dict.idCardType" placeholder="请输入证件类型"/>
<Field :span="20" label="证件号码" prop="idCardNo" v-model="form.idCardNo" placeholder="请输入证件号码"/>
<!--
<Field :span="20" label="累计次数" prop="accumulative" v-model="form.accumulative" placeholder="请输入累计次数"/>
<Field :span="20" label="约束时间" prop="constraintTime" v-model="form.constraintTime" type="date" />
<Field :span="20" label="创建方式" prop="createMethod" v-model="form.createMethod" type="select" :enumData="dict.createMethod" placeholder="请选择创建方式"/>
<Field :span="20" label="操作人员" prop="operator" v-model="form.operator" placeholder="请输入操作人员"/>
<Field :span="20" label="是否约束" prop="constraint" v-model="form.constraint" type="select" :enumData="dict.constraint" placeholder="请选择是否约束"/>
-->
</el-row>
......@@ -45,6 +45,8 @@
toString:[
"createMethod",
"constraint",
"idCardType",
"personId",
],
// 表单校验
rules: {
......@@ -88,6 +90,11 @@
this.open = true;
},
beforeSubmit(data){
data.name=this.dict['personId'][data.personId];
return data;
},
afterSubmit(data) {
this.open = false;
this.$emit("ok");
......
......@@ -34,6 +34,33 @@
this.$refs.dialogform.view(row);
},
handleConstraint(row,type) {
let _this = this
this.$confirm('取消约束后,系统将不向该群众推送此项服务,是否确认?', "系统服务", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(function () {
//todo
_this.$post("/appointment/constraint/save", {
id: row.id,
constraint: type,
})
.then((res) => {
if (res.code == 1) {
_this.$message.success("更改成功!");
_this.getData();
}
})
.catch((error) => {
this.$message.error(error.message);
});
}).then(response => {
})
}
},
data() {
return {
......@@ -44,12 +71,6 @@
{type: "selection", width: 60},
{type: "index",label: "序号",width: 50},
{label: "站点Id", prop: "siteId", formatter: this.formatter},
{label: "站点名称", prop: "siteName"},
{label: "个人信息ID", prop: "personId", formatter: this.formatter},
{label: "姓名", prop: "name"},
{label: "联系方式", prop: "contact"},
......@@ -64,15 +85,43 @@
{label: "创建方式", prop: "createMethod",formatter: this.formatter},
{label: "约束服务", prop: "constraint",formatter: this.formatter},
{label: "操作人员", prop: "operator"},
{label: "是否约束 ", prop: "constraint",formatter: this.formatter},
{
label: "操作",
width: 240,
formatter: row => {
return (
<table-buttons noAdd row={row} onEdit={this.toEdit} onView={this.toView} onDel={this.toDel} />
<div>
<table-buttons noAdd noView row={row} onEdit={this.toEdit} onView={this.toView} onDel={this.toDel} />
<span> </span>
{row.constraint === 0 ? (
<el-button
size="mini"
type="text"
icon="el-icon-open"
onClick={() => {
this.handleConstraint(row,1);
}}
>
约束
</el-button>
) : (
<el-button
size="mini"
type="text"
icon="el-icon-open"
onClick={() => {
this.handleConstraint(row,0);
}}
>
取消约束
</el-button>
)}
</div>
);
}
}
......
<template>
<!-- 抽屉框表单 -->
<el-drawer
:title="title"
:visible.sync="open"
:direction="direction"
size="90%">
<span>抽屉 表格数据 todo</span>
</el-drawer>
</template>
<script>
export default {
name: "dataDrawerShow",
components: {
},
created() {
},
data() {
return {
// 遮罩层
loading: true,
// 弹出层标题
title: "监测预警",
// 是否显示弹出层
open: false,
direction:"rtl",
toString:[
],
toDate:[
],
};
},
methods: {
view(row) {
this.open=true
},
},
};
</script>
<template>
<div class="page">
<LayoutTable :data="tableData" :config="tableConfig">
<LayoutTable notAdd notDel :data="tableData" :config="tableConfig">
<el-button
slot="table-head-left2"
style="margin-left: 10px"
icon="el-icon-tickets"
size="mini"
type="danger"
@click="monitorWarn"
>监测预警</el-button
>
</LayoutTable>
<drawer-show ref="dataDrawerShow" />
<dialog-show ref="dialogform" @ok="getData" />
</div>
......@@ -11,12 +23,13 @@
<script>
/** 表单弹出框模式需引入 */
import dialogShow from "./dialogshow";
import drawerShow from "./dataDrawerShow";
import table from "@/assets/mixins/table";
export default {
name: "AppointmentRecordsList",
components: {
dialogShow
},
dialogShow,drawerShow
},
mixins: [table],
created() {
},
......@@ -33,21 +46,69 @@
toView(row) {
this.$refs.dialogform.view(row);
},
/** 监测预警 */
monitorWarn(row) {
this.$refs.dataDrawerShow.view(row);
},
serviceConstraint(row) {
let _this=this
this.$confirm('服务约束后,系统将停止向该群众推送此项服务,是否确认?', "系统服务", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(function() {
//todo
_this.$post("/appointment/records", { id: [row.id] })
.then((res) => {
if (res && res.code && res.code == 1) {
_this.getList();
_this.$message.success("停止服务成功");
}
})
.catch((error) => {
_this.$message.error(error.message);
});
}).then(response => {
})
}
},
data() {
return {
config: {
search: [
{
name: "device",
type: "select",
label: "监测设备",
},
{
name: "detectTimeStart",
type: "datetime",
label: "开始时间",
},
{
name: "detectTimeEnd",
type: "datetime",
label: "结束时间",
},
{
name: "name",
type: "text",
label: "姓名",
fuzzy: true,
},
],
columns: [
{type: "selection", width: 60},
{type: "index",label: "序号",width: 50},
{label: "站点Id", prop: "siteId", formatter: this.formatter},
{label: "站点名称", prop: "siteName"},
{label: "姓名", prop: "name"},
{label: "联系方式", prop: "contactInfo"},
......@@ -64,13 +125,34 @@
{label: "签到方式", prop: "checkInMethod",formatter: this.formatter},
{label: "监测凭证", prop: "monitorCertificate"},
{label: "监测凭证", prop: "monitorCertificate",formatter: (row) => {
return row.monitorCertificate != "" ? (
<el-image
style="width: 70px; height: 70px"
src={row.monitorCertificate}
preview-src-list={[row.monitorCertificate]}
></el-image>
) : (
"--"
);
},},
{
label: "操作",
width: 240,
formatter: row => {
return (
<table-buttons noAdd row={row} onEdit={this.toEdit} onView={this.toView} onDel={this.toDel} />
<div>
<el-button
size="mini"
type="text"
icon="el-icon-open"
onClick={() => {
this.serviceConstraint(row);
}}
>
服务约束
</el-button>
</div>
);
}
}
......
<template>
<!-- 弹出框表单 -->
<el-dialog :title="title" :visible.sync="open" width="90%" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-form ref="form" :model="form" :rules="rules" label-width="200px">
<el-row>
<Field label="站点Id" prop="siteId" v-model="form.siteId" placeholder="请输入站点Id"/>
<Field label="站点名称" prop="siteName" v-model="form.siteName" type="textarea" placeholder="请输入站点名称"/>
<Field label="是否启用该服务" prop="used" v-model="form.used" type="select" :enumData="dict.used" placeholder="请选择是否启用该服务"/>
<Field label="周一是否监测" prop="monday" v-model="form.monday" type="select" :enumData="dict.monday" placeholder="请选择周一是否监测"/>
<Field label="周二是否监测" prop="tuesday" v-model="form.tuesday" type="select" :enumData="dict.tuesday" placeholder="请选择周二是否监测"/>
<Field label="周三是否监测" prop="wednesday" v-model="form.wednesday" type="select" :enumData="dict.wednesday" placeholder="请选择周三是否监测"/>
<Field label="周四是否监测" prop="thursday" v-model="form.thursday" type="select" :enumData="dict.thursday" placeholder="请选择周四是否监测"/>
<Field label="周五是否监测" prop="friday" v-model="form.friday" type="select" :enumData="dict.friday" placeholder="请选择周五是否监测"/>
<Field label="周六是否监测" prop="saturday" v-model="form.saturday" type="select" :enumData="dict.saturday" placeholder="请选择周六是否监测"/>
<Field label="周日是否监测" prop="sunday" v-model="form.sunday" type="select" :enumData="dict.sunday" placeholder="请选择周日是否监测"/>
<Field label="单日服务最大人数设置" prop="maxServicePersonNum" v-model="form.maxServicePersonNum" placeholder="请输入单日服务最大人数设置"/>
<Field label="服务阈值设置,单位分钟" prop="serviceThreshold" v-model="form.serviceThreshold" placeholder="请输入服务阈值设置,单位分钟"/>
<Field label="累计服务频次预警" prop="alertServiceNum" v-model="form.alertServiceNum" placeholder="请输入累计服务频次预警"/>
<Field label="消息发送对象" prop="msgRecipients" v-model="form.msgRecipients" type="radio" :enumData="dict.msgRecipients" />
<Field label="备注" prop="remark" v-model="form.remark" type="textarea" placeholder="请输入备注"/>
<!--
<Field :span="20" label="是否启用该服务" prop="used" v-model="form.used" type="radio" :enumData="dict.used" placeholder="请选择是否启用该服务"/>
-->
<Field :span="20" label="启用该服务">
<el-switch
v-model="form.used"
active-color="#13ce66"
inactive-color="#ff4949"
active-value="1"
inactive-value="0">
</el-switch>
</Field>
<Field :span="20" label="监测周期配置">
<el-checkbox
true-label="1"
false-label="0"
v-model="form.monday"
>周一</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.tuesday"
>周二</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.wednesday"
>周三</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.thursday"
>周四</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.friday"
>周五</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.saturday"
>周六</el-checkbox>
<el-checkbox
true-label="1"
false-label="0"
v-model="form.sunday"
>周日</el-checkbox>
</Field>
<Field :span="20" label="单日服务最大人数设置" prop="maxServicePersonNum" v-model="form.maxServicePersonNum" placeholder="请输入单日服务最大人数设置"/>
<Field :span="20" label="服务阈值设置,单位分钟" prop="serviceThreshold" v-model="form.serviceThreshold" placeholder="请输入服务阈值设置,单位分钟"/>
<Field :span="20" label="累计服务频次预警" prop="alertServiceNum" v-model="form.alertServiceNum" placeholder="请输入累计服务频次预警"/>
<Field :span="20" label="消息发送对象" prop="msgRecipients" v-model="form.msgRecipients" type="checkbox" :enumData="dict.msgRecipients" />
<Field :span="20" label="备注" prop="remark" v-model="form.remark" type="textarea" placeholder="请输入备注"/>
</el-row>
<el-divider content-position="center">主动关怀时间段信息</el-divider>
......@@ -34,14 +81,35 @@
<el-table :data="careConfigTimesList" :row-class-name="rowCareConfigTimesIndex" @selection-change="handleCareConfigTimesSelectionChange" ref="careConfigTimes">
<el-table-column type="selection" width="50" align="center" />
<el-table-column label="序号" align="center" prop="index" width="50"/>
<el-table-column label="时间段时候开始时间" prop="serviceTimeStart">
<el-table-column label="开始时间" prop="serviceTimeStart">
<template slot-scope="scope">
<el-input v-model="scope.row.serviceTimeStart" placeholder="请输入时间段时候开始时间" />
<el-time-select
placeholder="起始时间"
v-model="scope.row.serviceTimeStart"
value-format="yyyy-MM-dd HH:mm:ss"
format="HH:mm"
:picker-options="{
start: '08:00',
step: '00:30',
end: '18:00'
}">
</el-time-select>
<!-- <el-input v-model="scope.row.serviceTimeStart" placeholder="请输入时间段时候开始时间" />-->
</template>
</el-table-column>
<el-table-column label="时间段结束时间" prop="serviceTimeEnd">
<el-table-column label="结束时间" prop="serviceTimeEnd">
<template slot-scope="scope">
<el-input v-model="scope.row.serviceTimeEnd" placeholder="请输入时间段结束时间" />
<el-time-select
placeholder="结束时间"
value-format="yyyy-MM-dd HH:mm:ss"
v-model="scope.row.serviceTimeEnd"
:picker-options="{
start: '08:00',
step: '00:30',
end: '18:00'
}">
</el-time-select>
</template>
</el-table-column>
<el-table-column label="备注" prop="remark">
......@@ -49,26 +117,6 @@
<el-input v-model="scope.row.remark" placeholder="请输入备注" />
</template>
</el-table-column>
<el-table-column label="创建用户" prop="createUserId">
<template slot-scope="scope">
<el-input v-model="scope.row.createUserId" placeholder="请输入创建用户" />
</template>
</el-table-column>
<el-table-column label="创建时间" prop="createTime">
<template slot-scope="scope">
<el-input v-model="scope.row.createTime" placeholder="请输入创建时间" />
</template>
</el-table-column>
<el-table-column label="更新用户" prop="updateUserId">
<template slot-scope="scope">
<el-input v-model="scope.row.updateUserId" placeholder="请输入更新用户" />
</template>
</el-table-column>
<el-table-column label="更新时间" prop="updateTime">
<template slot-scope="scope">
<el-input v-model="scope.row.updateTime" placeholder="请输入更新时间" />
</template>
</el-table-column>
</el-table>
</el-form>
......@@ -82,6 +130,7 @@
<script>
import form from "@/assets/mixins/formdialog";
import dialogShow from "./dialogshow";
import moment from "moment/moment";
export default {
mixins: [form],
components: {
......@@ -99,6 +148,7 @@
title: "主动关怀配置",
// 是否显示弹出层
open: false,
toArrays: ["msgRecipients"],
toString:[
"used",
"monday",
......@@ -111,10 +161,7 @@
],
// 表单校验
rules: {
msgRecipients: [
{required: true,message: "请输入消息发送对象", trigger: "blur" },
{max: 255,message: "最多只能录入255个字符",trigger: "blur",},
],
createTime: [
{required: true,message: "请选择创建时间" },
],
......@@ -159,6 +206,10 @@
// 渲染前置处理
beforeRender(data) {
if(data.entity.careConfigTimesList) {
data.entity.careConfigTimesList.map(i=>{
i.serviceTimeStart = moment(i.serviceTimeStart).format('HH:mm')
i.serviceTimeEnd = moment(i.serviceTimeEnd).format('HH:mm')
})
this.careConfigTimesList = data.entity.careConfigTimesList;
}
return data
......@@ -198,6 +249,20 @@
this.open = true;
},
beforeSubmit(data) {
data.careConfigTimesList.map(i=>{
const serviceTimeStart = moment(i.serviceTimeStart, 'HH:mm');
const serviceTimeEnd = moment(i.serviceTimeEnd, 'HH:mm');
i.serviceTimeStart = moment().set({hour: serviceTimeStart.hour(), minute: serviceTimeStart.minute()}).format('yyyy-MM-DD HH:mm:ss');
i.serviceTimeEnd = moment().set({hour: serviceTimeEnd.hour(), minute: serviceTimeEnd.minute()}).format('yyyy-MM-DD HH:mm:ss');
})
if (Array.isArray(data["msgRecipients"])) {
data.msgRecipients = data.msgRecipients.filter(Boolean).join();
}
return data
},
afterSubmit(data) {
this.open = false;
this.$emit("ok");
......
......@@ -68,35 +68,30 @@
{type: "selection", width: 60},
{type: "index",label: "序号",width: 50},
{label: "站点Id", prop: "siteId", formatter: this.formatter},
{label: "启用服务", prop: "used",formatter: this.formatter},
{label: "站点名称", prop: "siteName"},
{label: "周一", prop: "monday",formatter: this.formatter},
{label: "是否启用该服务", prop: "used",formatter: this.formatter},
{label: "周二", prop: "tuesday",formatter: this.formatter},
{label: "一是否监测", prop: "monday",formatter: this.formatter},
{label: "", prop: "wednesday",formatter: this.formatter},
{label: "二是否监测", prop: "tuesday",formatter: this.formatter},
{label: "", prop: "thursday",formatter: this.formatter},
{label: "三是否监测", prop: "wednesday",formatter: this.formatter},
{label: "", prop: "friday",formatter: this.formatter},
{label: "四是否监测", prop: "thursday",formatter: this.formatter},
{label: "", prop: "saturday",formatter: this.formatter},
{label: "周五是否监测", prop: "friday",formatter: this.formatter},
{label: "周六是否监测", prop: "saturday",formatter: this.formatter},
{label: "周日是否监测", prop: "sunday",formatter: this.formatter},
{label: "周日", prop: "sunday",formatter: this.formatter},
{label: "单日服务最大人数设置", prop: "maxServicePersonNum",formatter: this.formatter},
{label: "服务阈值设置,单位分钟", prop: "serviceThreshold", formatter: this.formatter},
{label: "服务阈值设置(分钟)", prop: "serviceThreshold", formatter: this.formatter},
{label: "累计服务频次预警", prop: "alertServiceNum",formatter: this.formatter},
{label: "消息发送对象", prop: "msgRecipients"},
{label: "创建用户", prop: "createUserId", formatter: this.formatter},
{label: "主动关怀时间段",
width: 120,
prop: "subColumns",
......
......@@ -3,6 +3,13 @@
<el-dialog :title="title" :visible.sync="open" width="90%" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-row>
<Field :span="20" label="个人信息" prop="personId" v-model="form.personId" style="width:100%" type="select" :enumData="dict.personId" placeholder="请输入个人信息ID"/>
<Field :span="20" label="联系方式" prop="contact" v-model="form.contact" placeholder="请输入联系方式"/>
<Field :span="20" label="证件类型" prop="idCardType" v-model="form.idCardType" type="radio" :enumData="dict.idCardType" placeholder="请输入证件类型"/>
<Field :span="20" label="证件号码" prop="idCardNo" v-model="form.idCard" placeholder="请输入证件号码"/>
<!--
<Field label="站点Id" prop="siteId" v-model="form.siteId" placeholder="请输入站点Id"/>
<Field label="站点名称" prop="siteName" v-model="form.siteName" type="textarea" placeholder="请输入站点名称"/>
<Field label="人员ID" prop="personId" v-model="form.personId" placeholder="请输入人员ID"/>
......@@ -14,9 +21,10 @@
<Field label="创建方式" prop="createWay" v-model="form.createWay" type="select" :enumData="dict.createWay" placeholder="请选择创建方式"/>
<Field label="操作人员" prop="operator" v-model="form.operator" placeholder="请输入操作人员"/>
<Field label="是否追踪 " prop="track" v-model="form.track" type="select" :enumData="dict.track" placeholder="请选择是否追踪 "/>
-->
</el-row>
<el-divider content-position="center">主动关怀服务追踪信息</el-divider>
<!-- <el-divider content-position="center">主动关怀服务追踪信息</el-divider>
<br/>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
......@@ -75,7 +83,7 @@
<el-input v-model="scope.row.updateUserId" placeholder="请输入更新人ID" />
</template>
</el-table-column>
</el-table>
</el-table>-->
</el-form>
<div slot="footer" class="dialog-footer">
......@@ -108,71 +116,23 @@
toString:[
"createWay",
"track",
"idCardType",
"personId",
],
// 表单校验
rules: {
name: [
{required: true,message: "请输入姓名", trigger: "blur" },
{max: 50,message: "最多只能录入50个字符",trigger: "blur",},
],
contact: [
{required: true,message: "请输入联系方式", trigger: "blur" },
{max: 50,message: "最多只能录入50个字符",trigger: "blur",},
],
idCard: [
{required: true,message: "请输入身份证号码", trigger: "blur" },
{max: 18,message: "最多只能录入18个字符",trigger: "blur",},
],
trackingTime: [
{required: true,message: "请选择跟踪时间" },
],
createWay: [
{required: true,message: "请输入创建方式", trigger: "blur" },
],
operator: [
{required: true,message: "请输入操作人员", trigger: "blur" },
{max: 50,message: "最多只能录入50个字符",trigger: "blur",},
],
}
};
},
methods: {
/** 主动关怀服务追踪序号 */
rowCareConstraintTrackIndex({ row, rowIndex }) {
row.index = rowIndex + 1;
},
/** 主动关怀服务追踪添加按钮操作 */
handleAddCareConstraintTrack() {
let obj = {};
obj.feedbackId = "";
obj.feedbackName = "";
obj.feedback = "";
obj.feedbackTime = "";
obj.createMethod = "";
obj.createTime = "";
obj.createUserId = "";
obj.updateTime = "";
obj.updateUserId = "";
this.careConstraintTrackList.push(obj);
},
/** 主动关怀服务追踪删除按钮操作 */
handleDeleteCareConstraintTrack() {
if (this.checkedCareConstraintTrack.length == 0) {
this.$alert("请先选择要删除的主动关怀服务追踪数据", "提示", { confirmButtonText: "确定", });
} else {
this.careConstraintTrackList.splice(this.checkedCareConstraintTrack[0].index - 1, 1);
}
},
/** 单选框选中数据 */
handleCareConstraintTrackSelectionChange(selection) {
if (selection.length > 1) {
this.$refs.careConstraintTrack.clearSelection();
this.$refs.careConstraintTrack.toggleRowSelection(selection.pop());
} else {
this.checkedCareConstraintTrack = selection;
}
},
// 渲染前置处理
beforeRender(data) {
if(data.entity.careConstraintTrackList) {
......@@ -215,6 +175,11 @@
this.open = true;
},
beforeSubmit(data){
data.name=this.dict['personId'][data.personId]
return data;
},
afterSubmit(data) {
this.open = false;
this.$emit("ok");
......@@ -229,6 +194,7 @@
name : "",
contact : "",
idCard : "",
idCardType : "居民身份证",
serviceFrequency : null,
trackingTime : null,
createWay : null,
......
......@@ -2,7 +2,7 @@
<div class="page">
<LayoutTable :data="tableData" :config="tableConfig">
</LayoutTable>
<track-drawer-show ref="trackDrawerShow" />
<dialog-show ref="dialogform" @ok="getData" />
</div>
......@@ -11,11 +11,12 @@
<script>
/** 表单弹出框模式需引入 */
import dialogShow from "./dialogshow";
import trackDrawerShow from "./trackDrawerShow";
import table from "@/assets/mixins/table";
export default {
name: "CareConstraintList",
components: {
dialogShow
dialogShow,trackDrawerShow
},
mixins: [table],
created() {
......@@ -51,6 +52,39 @@
this.$refs.dialogform.view(row);
},
handleTrack(row) {
this.$refs.trackDrawerShow.view(row);
},
cancelTrack(row) {
let _this = this
this.$confirm('取消跟踪后,系统将从0开始计算服务频次,是否确认?', "系统服务", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
}).then(function () {
//todo
_this.$post("/care/constraint/save", {
id: row.id,
serviceFrequency: 0,
track: 0,
})
.then((res) => {
if (res.code == 1) {
_this.$message.success("取消追踪成功!");
_this.getData();
}
})
.catch((error) => {
_this.$message.error(error.message);
});
}).then(response => {
})
}
},
data() {
return {
......@@ -70,12 +104,6 @@
{type: "selection", width: 60},
{type: "index",label: "序号",width: 50},
{label: "站点Id", prop: "siteId", formatter: this.formatter},
{label: "站点名称", prop: "siteName"},
{label: "人员ID", prop: "personId", formatter: this.formatter},
{label: "姓名", prop: "name"},
{label: "联系方式", prop: "contact"},
......@@ -91,28 +119,38 @@
{label: "操作人员", prop: "operator"},
{label: "是否追踪 ", prop: "track",formatter: this.formatter},
{label: "主动关怀服务追踪",
width: 120,
prop: "subColumns",
formatter: (row) => {
let widthsize = this.columnSet.reduce((pre, cur) => {
return pre + Number(cur.width);
}, 50);
return (
<el-popover placement="right" width={widthsize} trigger="click">
{this.renderTable(row.careConstraintTrackList)}
<el-button type="text" slot="reference">详细</el-button>
</el-popover>
);
},
},
{
label: "操作",
width: 240,
width: 320,
formatter: row => {
return (
<table-buttons noAdd row={row} onEdit={this.toEdit} onView={this.toView} onDel={this.toDel} />
);
<div>
<table-buttons noAdd noView row={row} onEdit={this.toEdit} onView={this.toView} onDel={this.toDel} />
<span> </span>
<el-button
size="mini"
type="text"
icon="el-icon-open"
onClick={() => {
this.handleTrack(row);
}}
>
跟踪反馈
</el-button>
<span> </span>
<el-button
size="mini"
type="text"
icon="el-icon-open"
onClick={() => {
this.cancelTrack(row);
}}
>
取消跟踪
</el-button>
</div>);
}
}
]
......
<template>
<!-- 抽屉框表单 -->
<el-drawer
:title="title"
:visible.sync="open"
:direction="direction"
size="90%">
<span>抽屉 表格数据 todo</span>
</el-drawer>
</template>
<script>
export default {
name: "trackDrawerShow",
components: {
},
created() {
},
data() {
return {
// 遮罩层
loading: true,
// 弹出层标题
title: "跟踪反馈数据",
// 是否显示弹出层
open: false,
direction:"rtl",
toString:[
],
toDate:[
],
};
},
methods: {
view(row) {
this.open=true
},
},
};
</script>
<template>
<!-- 抽屉框表单 -->
<el-drawer
:title="title"
:visible.sync="open"
:direction="direction"
size="90%">
<span>抽屉 表格数据 todo</span>
</el-drawer>
</template>
<script>
export default {
name: "dataDrawerShow",
components: {
},
created() {
},
data() {
return {
// 遮罩层
loading: true,
// 弹出层标题
title: "监测预警",
// 是否显示弹出层
open: false,
direction:"rtl",
toString:[
],
toDate:[
],
};
},
methods: {
view(row) {
this.open=true
},
},
};
</script>
<template>
<div class="page">
<LayoutTable :data="tableData" :config="tableConfig">
</LayoutTable>
<LayoutTable notAdd notDel :data="tableData" :config="tableConfig">
<el-button
slot="table-head-left2"
style="margin-left: 10px"
icon="el-icon-tickets"
size="mini"
type="danger"
@click="monitorWarn"
>监测预警</el-button
>
<drawer-show ref="dataDrawerShow" />
<track-dialog-show ref="trackdialogform" @ok="getData" />
<dialog-show ref="dialogform" @ok="getData" />
</LayoutTable>
</div>
</template>
<script>
/** 表单弹出框模式需引入 */
import dialogShow from "./dialogshow";
import trackdialogShow from "./trackdialogshow";
import drawerShow from "./dataDrawerShow";
import table from "@/assets/mixins/table";
export default {
name: "CareRecordsList",
components: {
dialogShow
},
dialogShow,drawerShow,trackdialogShow},
mixins: [table],
created() {
},
......@@ -33,23 +49,68 @@
toView(row) {
this.$refs.dialogform.view(row);
},
/** 监测预警 */
monitorWarn(row) {
this.$refs.dataDrawerShow.view(row);
},
toNotice(row){
let _this=this
this.$confirm(
'负责人姓名:刘琳琳 联系电话:15244845448',
"通知负责人",
{
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
}
).then(function () {
_this.$post("/care/records/notice", { id: [row.id] })
.then((res) => {
if (res && res.code && res.code == 1) {
_this.getList();
_this.$message.success("通知成功");
}
})
.catch((error) => {
_this.$message.error(error.message);
});
});
},
/** 打开跟踪反馈 */
toTrack(row) {
this.$refs.trackdialogform.view(row);
},
},
data() {
return {
config: {
search: [
{
name: "detectTimeStart",
type: "datetime",
label: "开始时间",
},
{
name: "detectTimeEnd",
type: "datetime",
label: "结束时间",
},
{
name: "name",
type: "text",
label: "姓名",
fuzzy: true,
},
],
columns: [
{type: "selection", width: 60},
{type: "index",label: "序号",width: 50},
{label: "站点Id", prop: "siteId", formatter: this.formatter},
{label: "站点名称", prop: "siteName"},
{label: "个人信息ID", prop: "personId", formatter: this.formatter},
{label: "姓名", prop: "name"},
{label: "联系方式", prop: "contact"},
......@@ -64,7 +125,7 @@
{label: "监测设备", prop: "monitorDevice"},
{label: "最终等待时长,秒", prop: "waitTime", formatter: this.formatter},
{label: "最终等待时长", prop: "waitTime", formatter: this.formatter},
{label: "办理状态", prop: "processStatus"},
{
......@@ -72,7 +133,48 @@
width: 240,
formatter: row => {
return (
<table-buttons noAdd row={row} onEdit={this.toEdit} onView={this.toView} onDel={this.toDel} />
<div>
{row.processStatus === '排队中' ? (<div>
<el-button
size="mini"
type="text"
icon="el-icon-open"
onClick={() => {
this.reCare(row);
}}
>
再次关怀
</el-button>
<span> </span>
<el-button
size="mini"
type="text"
icon="el-icon-open"
onClick={() => {
this.notice(row);
}}
>
通知负责人
</el-button>
</div>
) : (
""
)}
<span> </span>
<el-button
size="mini"
type="text"
icon="el-icon-open"
onClick={() => {
this.toTrack(row);
}}
>
跟踪反馈
</el-button>
</div>
);
}
}
......
<template>
<!-- 弹出框表单 -->
<el-dialog :title="title" :visible.sync="open" width="90%" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-row>
<Field label="站点Id" prop="siteId" v-model="form.siteId" placeholder="请输入站点Id"/>
<Field label="站点名称" prop="siteName" v-model="form.siteName" type="textarea" placeholder="请输入站点名称"/>
<Field label="个人信息ID" prop="personId" v-model="form.personId" placeholder="请输入个人信息ID"/>
<Field label="姓名" prop="name" v-model="form.name" placeholder="请输入姓名"/>
<Field label="联系方式" prop="contact" v-model="form.contact" placeholder="请输入联系方式"/>
<Field label="身份证号码" prop="idCard" v-model="form.idCard" placeholder="请输入身份证号码"/>
<Field label="办理业务" prop="service" v-model="form.service" placeholder="请输入办理业务"/>
<Field label="排队编号" prop="queueNo" v-model="form.queueNo" placeholder="请输入排队编号"/>
<Field label="监测时间" prop="monitorTime" v-model="form.monitorTime" type="date" />
<Field label="监测设备id" prop="monitorDeviceId" v-model="form.monitorDeviceId" placeholder="请输入监测设备id"/>
<Field label="监测设备" prop="monitorDevice" v-model="form.monitorDevice" placeholder="请输入监测设备"/>
<Field label="最终等待时长,秒" prop="waitTime" v-model="form.waitTime" placeholder="请输入最终等待时长,秒"/>
<Field label="办理状态" prop="processStatus" v-model="form.processStatus" type="select" :enumData="dict.processStatus" placeholder="请选择办理状态"/>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" v-if="pageInfo.type !== 'view'" @click="submitForm">确 定</el-button>
<el-button @click="cancel">取 消</el-button>
</div>
</el-dialog>
</template>
<script>
import form from "@/assets/mixins/formdialog";
import dialogShow from "./dialogshow";
export default {
mixins: [form],
components: {
dialogShow ,
},
data() {
return {
// 遮罩层
loading: true,
// 弹出层标题
title: "预约关怀记录",
// 是否显示弹出层
open: false,
toString:[
],
// 表单校验
rules: {
}
};
},
methods: {
/** 编辑 */
edit(row) {
this.reset()
this.query = { id: row.id };
this.urls.currUrl ="care/records/edit";
this.getData();
this.pageInfo.type="edit"
this.title = "修改预约关怀记录";
},
/** 新增 */
add(row) {
this.reset()
this.urls.currUrl = "care/records/add";
this.getData();
this.pageInfo.type="add"
this.title = "新增预约关怀记录";
},
/** 查看*/
view(row) {
this.reset()
this.query = { id: row.id };
this.urls.currUrl ="care/records/view";
this.getData();
this.pageInfo.type="view"
this.title = "预约关怀记录详细";
},
/**取消按钮 */
cancel() {
this.open = false;
},
/**获取数据后弹框 */
afterRender(data) {
this.open = true;
},
afterSubmit(data) {
this.open = false;
this.$emit("ok");
},
// 表单重置
reset() {
this.form = {
siteId : null,
siteName : "",
personId : null,
name : "",
contact : "",
idCard : "",
service : "",
queueNo : "",
monitorTime : null,
monitorDeviceId : null,
monitorDevice : "",
waitTime : null,
processStatus : "",
};
this.resetForm("form");
},
resetForm(refName) {
if (this.$refs[refName]) {
this.$refs[refName].resetFields();
}
},
},
};
</script>
<template>
<div class="page">
<LayoutTable ref="layoutTable" :data="tableData" :config="tableConfig" notDel />
<LayoutTable notPagination ref="layoutTable" :data="tableData" :config="tableConfig" notDel />
<dialog-show ref="dialogform" @ok="getData" />
</div>
......
<template>
<!-- 抽屉框表单 -->
<el-drawer
:title="title"
:visible.sync="open"
:direction="direction"
size="90%">
<span>抽屉 表格数据 todo</span>
</el-drawer>
</template>
<script>
export default {
name: "dataDrawerShow",
components: {
},
created() {
},
data() {
return {
// 遮罩层
loading: true,
// 弹出层标题
title: "监测预警",
// 是否显示弹出层
open: false,
direction:"rtl",
toString:[
],
toDate:[
],
};
},
methods: {
view(row) {
this.open=true
},
},
};
</script>
<template>
<div class="page">
<LayoutTable :data="tableData" :config="tableConfig">
</LayoutTable>
<LayoutTable notAdd notDel :data="tableData" :config="tableConfig">
<el-button
slot="table-head-left2"
style="margin-left: 10px"
icon="el-icon-tickets"
size="mini"
type="danger"
@click="monitorWarn"
>监测预警</el-button
>
</LayoutTable>
<drawer-show ref="dataDrawerShow" />
<dialog-show ref="dialogform" @ok="getData" />
</div>
</template>
......@@ -11,11 +21,13 @@
<script>
/** 表单弹出框模式需引入 */
import dialogShow from "./dialogshow";
import drawerShow from "./dataDrawerShow";
import table from "@/assets/mixins/table";
export default {
name: "RealtimeDataflowList",
components: {
dialogShow
dialogShow,drawerShow
},
mixins: [table],
created() {
......@@ -34,11 +46,32 @@
this.$refs.dialogform.view(row);
},
monitorWarn(row) {
this.$refs.dataDrawerShow.view(row);
},
},
data() {
return {
config: {
search: [
{
name: "device",
type: "select",
label: "监测设备",
},
{
name: "detectTimeStart",
type: "datetime",
label: "开始时间",
},
{
name: "detectTimeEnd",
type: "datetime",
label: "结束时间",
},
],
columns: [
{type: "selection", width: 60},
......
// 添加,编辑设备
<template>
<!-- 弹出框表单 -->
<el-dialog :title="title" :visible.sync="open" width="35%" append-to-body>
<el-form
ref="form"
:model="form"
:rules="rules"
label-width="110px"
label-position="right"
>
<el-dialog :title="title" :visible.sync="open" width="90%" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-row>
<Field
:span="22"
label="ID"
prop="id"
v-model="form.id"
v-if="pageInfo.type !== 'add'"
disabled
/>
<Field :span="22" label="名称" prop="name" v-model="form.name" />
<Field
:span="22"
label="权限类型"
prop="authType"
v-model="form.authType"
:enumData="dict.authType"
type="select"
/>
<Field
:span="22"
label="父级菜单"
prop="parentId"
<el-col :span="24" v-if="form.parentId !== 0">
<el-form-item label="上级节点" prop="parentId">
<treeselect
v-model="form.parentId"
:enumData="menu"
type="select"
/>
<Field :span="22" label="访问地址" prop="url" v-model="form.url" />
<Field
:span="22"
label="状态"
prop="status"
v-model="form.status"
:enumData="dict.status"
type="radio"
:options="menuOptions"
:normalizer="normalizer"
placeholder="选择上级菜单信息"
/>
</el-form-item>
</el-col>
<Field
:span="22"
label="图标"
placeholder="请输入图标名称"
prop="imgPath"
v-model="form.imgPath"
/>
<!-- <Field v-else :span="22" label="图标" prop="imgPath">
<el-radio-group v-model="form.imgPath" class="form-el-radio-group">
<el-radio-button label="">不需要图标</el-radio-button>
<el-radio-button
v-for="(icon, index) in icons"
:key="index"
:label="icon"
>
<i :class="'el-icon-' + icon"></i>
{{ icon }}
<!-- <Field label="ID" prop="id" v-model="form.id" v-if='pageInfo.type !== "add"' disabled />
--> <Field label="名称" prop="name" v-model="form.name"/>
<Field label="权限类型" prop="authType" v-model="form.authType" :enumData='dict.authType' type='select' />
<Field label="访问地址" prop="url" v-model="form.url" />
<Field label="状态" prop="status" v-model="form.status" :enumData='dict.status' type='radio' />
<Field class="radio-group-container" label="图标" prop="imgPath" :span='24'>
<el-radio-group v-model="form.imgPath" class='form-el-radio-group'>
<el-radio-button style="width: 180px" label="">不需要图标</el-radio-button>
<el-radio-button style="width: 180px" v-for='(icon, index) in icons' :key='index' :label="icon">
<i :class="'el-icon-'+icon" style="font-size: 20px"></i>
{{icon}}
</el-radio-button>
</el-radio-group>
</Field> -->
</Field>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button
type="primary"
v-if="pageInfo.type !== 'view'"
@click="submitForm"
>确 定</el-button
>
<el-button type="primary" @click="submitForm">确 定</el-button>
<el-button @click="cancel">取 消</el-button>
</div>
</el-dialog>
......@@ -81,55 +39,84 @@
<script>
import form from "@/assets/mixins/formdialog";
import dialogShow from "./dialogshow";
import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import axios from 'axios'
export default {
mixins: [form],
components: {
dialogShow,
Treeselect,
},
computed: {
menu() {
let menu = { 0: "" };
this.$store.state.userData.barList.forEach((item) => {
menu[item.id + ""] = item.name;
});
return menu;
data() {
return {
fileContent:"",
icons: [
'info', 'error', 'success', 'warning', 'question',
'tickets', 'document', 'goods', 'sold-out', 'news',
'message', 'date', 'printer', 'time', 'bell',
'mobile-phone', 'service', 'view', 'menu', 'star-on',
'location', 'phone', 'picture', 'delete', 'search',
'edit', 'rank', 'refresh', 'share', 'setting',
'upload', 'upload2', 'download', 'loading',
],
menuOptions: [],
// 遮罩层
loading: true,
// 弹出层标题
title: "菜单信息",
// 是否显示弹出层
open: false,
id:null,
toString:[
"status",
"linkType",
"commMenu",
"menuType",
"authType",
],
// 表单校验
rules: {
}
};
},
created() {
axios.get('/icon.txt')
.then(response => {
this.fileContent = response.data
this.icons = this.fileContent.split('\n')
})
},
methods: {
afterSubmit() {
this.$store.dispatch("login");
this.$router.go(-1);
},
/** 编辑 */
edit(row) {
this.reset();
edit(row, menuOptions) {
this.reset()
this.query = { id: row.id };
this.urls.currUrl = this.pageInfo.editUrl;
this.urls.currUrl =this.pageInfo.editUrl;;
this.getData();
this.pageInfo.type = "edit";
this.title = "修改菜单";
this.menuOptions = menuOptions;
this.title = "修改菜单信息";
},
/** 新增 */
add(row) {
this.reset();
async add(row, menuOptions) {
this.reset()
this.query = { id: row.id };
this.urls.currUrl = this.pageInfo.addUrl;
this.getData();
this.pageInfo.type = "add";
this.open = true;
this.title = "新增菜单";
if(row.id){
this.id=row.id
this.form.parentId=row.id
}
this.menuOptions = menuOptions;
this.title = "新增菜单信息";
},
/** 查看*/
view(row) {
this.reset();
view(row, menuOptions) {
this.query = { id: row.id };
this.urls.currUrl = this.pageInfo.viewUrl;
this.urls.currUrl =this.pageInfo.viewUrl;;
this.getData();
this.pageInfo.type = "view";
this.open = true;
this.title = "菜单详细";
this.menuOptions = menuOptions;
this.title = "菜单信息详细";
},
/**取消按钮 */
cancel() {
......@@ -137,16 +124,46 @@ export default {
},
/**获取数据后弹框 */
afterRender(data) {
if(this.id){
this.form.parentId=this.id
}
this.open = true;
},
afterSubmit(data) {
this.open = false;
this.$emit("ok");
},
/** 转换菜单信息数据结构 */
normalizer(node) {
if (node.children && !node.children.length) {
delete node.children;
}
return {
id: node.id,
label: node.name,
children: node.children,
};
},
// 表单重置
reset() {
// this.form={}
this.form = {
name : '',
url : '',
ancestors : '',
parentId : 0,
orderId : 1,
status : 1,
linkType : 0,
groupId : 1,
groupName : '',
imgPath : '',
buttonImgPath : '',
imgCommPath : '',
commMenu : 0,
menuType : 0,
authType : 3,
};
this.resetForm("form");
},
resetForm(refName) {
......@@ -155,74 +172,42 @@ export default {
}
},
},
data() {
return {
// 遮罩层
loading: true,
// 弹出层标题
title: "菜单",
// 是否显示弹出层
open: false,
toString: ["parentId", "authType", "status"],
icons: [
"info",
"error",
"success",
"warning",
"question",
"tickets",
"document",
"goods",
"sold-out",
"news",
"message",
"date",
"printer",
"time",
"bell",
"mobile-phone",
"service",
"view",
"menu",
"star-on",
"location",
"phone",
"picture",
"delete",
"search",
"edit",
"rank",
"refresh",
"share",
"setting",
"upload",
"upload2",
"download",
"loading",
"reading",
],
rules: {
name: [{ required: true, message: "请输入名称", trigger: "blur" }],
},
};
},
};
</script>
<style lang="less">
.el-select {
width: 100%;
}
.el-date-editor.el-input {
width: 100%;
}
.form-el-radio-group.label {
width: 160px;
<style lang="scss">
.ml-row {
margin-bottom: 5px;
}
.el-radio-button__inner {
border: 0;
// width: 82px;
height: 36px;
border-radius: 4px 0px 0px 4px;
border: 1px solid rgba(0, 0, 0, 0) !important;
border-radius: 2px !important;
background-color: rgba(0, 0, 0, 0);
font-size: 14px;
font-weight: 400;
color: #606677;
line-height: 14px;
outline: none;
box-shadow: none;
}
</style>
.el-radio-button__orig-radio:checked+.el-radio-button__inner {
background: rgba(0, 0, 0, 0);
border: 1px solid #3E7BFA !important;
color: #3E7BFA;
line-height: 14px;
outline: none;
box-shadow: none;
}
.ml-top-button {
border-color: #ffffff;
background: rgba(0, 0, 0, 0);
font-size: 16px;
margin: 0 10px 0 10px;
}
</style>
<template>
<div class="page">
<LayoutTable :data='tableData' :config='tableConfig' notPagination />
<dialog-show ref="dialogform" @ok="getData" />
<div className="page">
<LayoutTable notPagination ref="layoutTable" :data="tableData" :config="tableConfig"/>
<dialog-show ref="dialogform" @ok="getData"/>
</div>
</template>
<script>
import table from '@/assets/mixins/table';
import {handleTree} from "@/assets/utils/table";
import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import table from "@/assets/mixins/table";
import dialogShow from "./dialogshow";
export default {
name: "Menu",
mixins: [table],
components: { dialogShow },
methods: {
beforeRender(data) {
this.allMenu = this.sortByGroup(this.util_copy(data.data));
// 存在查询条件,展开全部
if(Object.keys(this.$route.query).length) {
this.select = this.allMenu.filter(i=>!i.parentId).map(i=>i.id);
}
return data;
},
afterRender() {
this.showChild();
},
// 按parentId排序分组
sortByGroup(data) {
return data.filter(i=>!i.parentId).reduce((prev, item)=>{
return prev.concat([item], data.filter(i=>i.parentId == item.id));
}, [])
},
// 查看下级菜单
selectHandler({id}) {
// 如果已展开,则关闭
const index = this.select.indexOf(id);
if(index > -1) {
this.select.splice(index, 1);
}else{
this.select.push(id);
}
this.showChild();
},
showChild() {
this.tableData.data = this.allMenu.filter(item=>{
return !item.parentId || this.select.indexOf(item.parentId) > -1
});
},
// 展示菜单图标
showIcon(row, column) {
return <i class={'el-icon-'+row.imgPath}></i>
},
// 操作菜单状态
changeStatus(row, column) {
return (
<my-switch
confirm
url='/menu/save'
row={row}
onChange={this.statusChange}
value={this.tableData.data}
onInput={(data)=>{
this.tableData.data = data;
}}/>
)
components: {Treeselect, dialogShow},
created() {
this.query={"page":1,"size":-1}
},
afterDel(id) {
this.$store.dispatch('login');
},
statusChange() {
this.$store.dispatch('login');
methods: {
afterRender(data) {
console.log(data)
data.data = handleTree(data.data, "id", "parentId");
console.log("tree data:",data.data)
this.menuOptions = data.data;
this.$refs.layoutTable.showType = "treetable"
},
handleUp(data) {
let type = 0;
let url = "/menu/upOrDown";
......@@ -92,7 +51,6 @@ export default {
if (res && res.code && res.code == 1) {
this.getData()
this.loading = false;
this.$message.success("更新排序成功!");
}
})
......@@ -101,54 +59,79 @@ export default {
this.$message.error(error.message);
});
},
handleAdd(row) {
this.$refs.dialogform.add(row, this.menuOptions);
},
handleRowClick(row){
console.log(row)
//if(row.children || row.children.length === 0) return ;
//this.$refs.layoutTable.toggleRowExpansion(row,true)
},
/** 重写新增方法 */
// toAdd(row) {
// this.$refs.dialogform.add(row);
// },
// /** 重写编辑方法 */
// toEdit(row) {
// this.$refs.dialogform.edit(row);
// },
// /** 重写查看方法 */
// toView(row) {
// this.$refs.dialogform.view(row);
// },
toAdd(row) {
this.$refs.dialogform.add(row, this.menuOptions);
},
/** 重写编辑方法 */
toEdit(row) {
this.loading = true;
this.$post(this.pageInfo.exclude, {id: row.id})
.then((res) => {
if (res && res.code && res.code == 1) {
this.menuOptions = handleTree(res.data.data);
this.$refs.dialogform.edit(row, this.menuOptions);
this.loading = false;
}
})
.catch((error) => {
this.$message.error(error.message);
});
},
/** 重写查看方法 */
toView(row) {
this.$refs.dialogform.view(row, this.menuOptions);
},
// 展示菜单图标
showIcon(row, column) {
return <i class={'el-icon-'+row.imgPath}></i>
},
// 操作菜单状态
changeStatus(row, column) {
return (
<my-switch
confirm
url='/menu/save'
row={row}
onChange={this.statusChange}
value={this.tableData.data}
onInput={(data)=>{
this.tableData.data = data;
}}/>
)
},
statusChange() {
this.$store.dispatch('login');
},
},
data() {
return {
allMenu: [], // 经过分组排序的表格数据
select: [], // 当前展开的树节点
query: {
'size': -1
},
config: {
search: [
{
name: 'name',
type: 'text',
label: '菜单名称',
},
],
/** 树表是否默认展开 */
expand: false,
showType: "treetable",
search: [],
columns: [
{ type: "selection",reserveSelection:true, width: 60 },
{ type: "index", label: "序号",align:"center", width: 50 },
{
type: 'selection',
width: 60,
formatter: row => {
const icon = this.select.indexOf(row.id) === -1 ? 'right' : 'down';
return (
!row.parentId
? <div onClick={()=>{this.selectHandler(row)}}>
<i class={'el-icon-arrow-'+icon}></i>
</div>
: ''
)
}
},
{
prop: 'id',
label: 'ID',
width: 60,
width: 120,
},
{
prop: 'name',
......@@ -158,8 +141,8 @@ export default {
{
prop: 'imgPath',
label: '图标',
width: 120,
// formatter: this.showIcon,
width: 50,
formatter: this.showIcon,
},
{
prop: 'authType',
......@@ -180,11 +163,28 @@ export default {
width: 100,
formatter: this.changeStatus,
},
// {label: "菜单名称", prop: "name"},
// {label: "连接地址", prop: "url"},
// {label: "当前节点父id路径,“,”分割,服务端生成", prop: "ancestors"},
// {label: "父菜单ID,一级菜单的该字段值为-1", prop: "parentId", formatter: this.formatterString},
// {label: "排序编号", prop: "orderId"},
// {label: "菜单状态,0:禁用,1:启用,默认1", prop: "status"},
// {label: "链接方式,0:普通,1:弹出,2:脚本", prop: "linkType"},
// {label: "分组编号,使用菜单分隔符按该值分隔,默认1", prop: "groupId", formatter: this.formatterString},
// {label: "", prop: "groupName"},
// {label: "主菜单图标,主菜单图标的css样式名", prop: "imgPath"},
// {label: "按钮图标,按钮图标的css样式名", prop: "buttonImgPath"},
// {label: "常用菜单图标,常用菜单图标的css样式名", prop: "imgCommPath"},
// {label: "是否常用菜单,0:非常用,1:常用,默认0", prop: "commMenu"},
// {label: "菜单类型,0:主菜单,1:非主菜单", prop: "menuType"},
// {label: "权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3", prop: "authType"},
// {label: "创建用户名称", prop: "createUserName"},
{
label: '操作',
formatter: (row)=> {
label: "操作",
width: 280,
formatter: row => {
return (
<div>
<el-link
style="margin-right:5px;margin-left:5px"
......@@ -203,17 +203,31 @@ export default {
></el-link>
<table-buttons noView row={row} onEdit={this.toEdit} onDel={this.toDel} />
<el-button
size="mini"
type="text"
icon="el-icon-edit-outline"
onClick={() => {
this.handleAdd(row);
}}
>
新增
</el-button>
<table-buttons
noAdd
noView
row={row}
onEdit={this.toEdit}
onView={this.toView}
onDel={this.toDel}
/>
</div>
)
},
},
],
},
);
}
}
]
}
}
};
}
};
</script>
<template>
<layout-form>
<layout-form >
<el-form
:model="form"
:loading="loading"
......@@ -8,7 +8,7 @@
label-width='100px'
ref="form"
>
<el-row>
<el-row :span='20'>
<Field label="ID" prop="id" v-model="form.id" v-if='pageInfo.type !== "add"' disabled />
<Field label="名称" prop="name" v-model="form.name"/>
<Field label="权限类型" prop="authType" v-model="form.authType" :enumData='dict.authType' type='select' />
......@@ -19,7 +19,7 @@
<el-radio-group v-model="form.imgPath" class='form-el-radio-group'>
<el-radio-button label="">不需要图标</el-radio-button>
<el-radio-button v-for='(icon, index) in icons' :key='index' :label="icon">
<i :class="'el-icon-'+icon"></i>
<i :class="'el-icon-'+icon" style="font-size: 20px"></i>
{{icon}}
</el-radio-button>
</el-radio-group>
......@@ -32,7 +32,7 @@
<script>
import form from '@/assets/mixins/form';
import axios from 'axios'
export default {
mixins: [form],
methods: {
......@@ -41,6 +41,15 @@ export default {
this.$router.go(-1);
},
},
created() {
axios.get('/icon.txt')
.then(response => {
this.fileContent = response.data
this.icons = this.fileContent.split('\n')
//this.lines.map(i=>console.log(i))
})
},
computed: {
menu() {
let menu = {'0': ''};
......@@ -50,8 +59,17 @@ export default {
return menu;
}
},
// mounted() {
// axios.get('/icon.txt')
// .then(response => {
// this.fileContent = response.data
// this.lines = this.fileContent.split('\n')
// this.lines.map(i=>console.log(i))
// })
// },
data() {
return {
fileContent:"",
toString: ['parentId', 'authType', 'status'],
icons: [
'info', 'error', 'success', 'warning', 'question',
......
/**
* 文件:MenuDao.java
* 版本:1.0.0
* 日期:
* Copyright &reg;
* All right reserved.
*/
package com.mortals.xhx.base.system.menu.dao;
import com.mortals.framework.dao.ICRUDDao;
import com.mortals.xhx.base.system.menu.model.MenuEntity;
import java.util.List;
/**
* <p>Title: 菜单信息</p>
* <p>Description: MenuDao DAO接口 </p>
* <p>Copyright: Copyright &reg; </p>
* <p>Company: </p>
* @author
* @version 1.0.0
*/
* 菜单信息Dao
* 菜单信息 DAO接口
*
* @author zxfei
* @date 2023-04-10
*/
public interface MenuDao extends ICRUDDao<MenuEntity,Long> {
public interface MenuDao extends ICRUDDao<MenuEntity,Long>{
/**
* 查询子节点
*
* @param
* @return
*/
List<MenuEntity> selectChildrenMenuById(String menuId);
}
/**
* 文件:MenuDaoImpl.java
* 版本:1.0.0
* 日期:
* Copyright &reg;
* All right reserved.
*/
package com.mortals.xhx.base.system.menu.dao.ibatis;
import com.mortals.framework.dao.ibatis.BaseCRUDDaoMybatis;
import com.mortals.xhx.base.system.menu.dao.MenuDao;
import com.mortals.xhx.base.system.menu.model.MenuEntity;
import org.springframework.stereotype.Repository;
import com.mortals.xhx.base.system.menu.dao.MenuDao;
import com.mortals.xhx.base.system.menu.model.MenuEntity;
import com.mortals.framework.dao.ibatis.BaseCRUDDaoMybatis;
import java.util.List;
/**
* <p>Title: 菜单信息</p>
* <p>Description: MenuDaoImpl DAO接口 </p>
* <p>Copyright: Copyright &reg; </p>
* <p>Company: </p>
* @author
* @version 1.0.0
*/
* 菜单信息DaoImpl DAO接口
*
* @author zxfei
* @date 2023-04-10
*/
@Repository("menuDao")
public class MenuDaoImpl extends BaseCRUDDaoMybatis<MenuEntity,Long> implements MenuDao {
@Override
public List<MenuEntity> selectChildrenMenuById(String menuId) {
return getSqlSession().selectList(getSqlId("selectChildrenMenuById"), menuId);
}
}
/**
* 文件:MenuEntity.java
* 版本:1.0.0
* 日期:
* Copyright &reg;
* All right reserved.
*/
package com.mortals.xhx.base.system.menu.model;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.ArrayList;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.mortals.framework.annotation.Excel;
import com.mortals.framework.model.BaseEntityLong;
import com.mortals.xhx.base.system.menu.model.vo.MenuVo;
/**
* <p>Title: 菜单信息</p>
* <p>Description: MenuEntity </p>
* <p>Copyright: Copyright &reg; </p>
* <p>Company: </p>
* @author
* @version 1.0.0
*/
public class MenuEntity extends BaseEntityLong{
private static final long serialVersionUID = 1547777703328L;
* 菜单信息实体对象
*
* @author zxfei
* @date 2023-04-10
*/
/** 菜单名称 */
private String name;
public class MenuEntity extends MenuVo {
private static final long serialVersionUID = 1L;
/** 连接地址 */
/**
* 菜单名称
*/
private String name;
/**
* 连接地址
*/
private String url;
/** 父菜单ID,一级菜单的该字段值为-1 */
/**
* 当前节点父id路径,“,”分割,服务端生成
*/
private String ancestors;
/**
* 父菜单ID,一级菜单的该字段值为-1
*/
private Long parentId;
/** 排序编号 */
/**
* 排序编号
*/
private Integer orderId;
/** 菜单状态,0:禁用,1:启用,默认1 */
/**
* 菜单状态,0:禁用,1:启用,默认1
*/
private Integer status;
/** 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0 */
/**
* 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
*/
private Integer linkType;
/** 分组编号,使用菜单分隔符按该值分隔,默认1 */
private Integer groupId;
/** 分组名称 */
private Integer groupName;
/** 主菜单图标,主菜单图标的css样式名 */
/**
* 分组编号,使用菜单分隔符按该值分隔,默认1
*/
private Long groupId;
/**
*
*/
private String groupName;
/**
* 主菜单图标,主菜单图标的css样式名
*/
private String imgPath;
/** 按钮图标,按钮图标的css样式名 */
/**
* 按钮图标,按钮图标的css样式名
*/
private String buttonImgPath;
/** 常用菜单图标,常用菜单图标的css样式名 */
/**
* 常用菜单图标,常用菜单图标的css样式名
*/
private String imgCommPath;
/** 是否常用菜单,0:非常用,1:常用,默认0 */
/**
* 是否常用菜单,0:非常用,1:常用,默认0
*/
private Integer commMenu;
/** 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0 */
/**
* 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
*/
private Integer menuType;
/** 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3 */
/**
* 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
*/
private Integer authType;
/** 创建时间 */
private Date createTime;
/** 创建用户 */
private String createUser;
/** 创建用户名称 */
/**
* 创建用户名称
*/
private String createUserName;
private Integer type;
private List<MenuEntity> childList = new ArrayList<MenuEntity>();
public MenuEntity() {
}
public Integer getType() {
return type;
}
public void setType(Integer type) {
this.type = type;
}
public MenuEntity(){}
/**
* 获取 菜单名称
* @return name
* @return String
*/
public String getName() {
return this.name;
public String getName(){
return name;
}
/**
* 设置 菜单名称
* @param name
*/
public void setName(String name) {
public void setName(String name){
this.name = name;
}
/**
* 获取 连接地址
* @return url
* @return String
*/
public String getUrl() {
return this.url;
public String getUrl(){
return url;
}
/**
* 设置 连接地址
* @param url
*/
public void setUrl(String url) {
public void setUrl(String url){
this.url = url;
}
/**
* 获取 当前节点父id路径,“,”分割,服务端生成
* @return String
*/
public String getAncestors(){
return ancestors;
}
/**
* 设置 当前节点父id路径,“,”分割,服务端生成
* @param ancestors
*/
public void setAncestors(String ancestors){
this.ancestors = ancestors;
}
/**
* 获取 父菜单ID,一级菜单的该字段值为-1
* @return parentId
* @return Long
*/
public Long getParentId() {
return this.parentId;
public Long getParentId(){
return parentId;
}
/**
* 设置 父菜单ID,一级菜单的该字段值为-1
* @param parentId
*/
public void setParentId(Long parentId) {
public void setParentId(Long parentId){
this.parentId = parentId;
}
/**
* 获取 排序编号
* @return orderId
* @return Integer
*/
public Integer getOrderId() {
return this.orderId;
public Integer getOrderId(){
return orderId;
}
/**
* 设置 排序编号
* @param orderId
*/
public void setOrderId(Integer orderId) {
public void setOrderId(Integer orderId){
this.orderId = orderId;
}
/**
* 获取 菜单状态,0:禁用,1:启用,默认1
* @return status
* @return Integer
*/
public Integer getStatus() {
return this.status;
public Integer getStatus(){
return status;
}
/**
* 设置 菜单状态,0:禁用,1:启用,默认1
* @param status
*/
public void setStatus(Integer status) {
public void setStatus(Integer status){
this.status = status;
}
/**
* 获取 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @return linkType
* @return Integer
*/
public Integer getLinkType() {
return this.linkType;
public Integer getLinkType(){
return linkType;
}
/**
* 设置 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @param linkType
*/
public void setLinkType(Integer linkType) {
public void setLinkType(Integer linkType){
this.linkType = linkType;
}
/**
* 获取 分组编号,使用菜单分隔符按该值分隔,默认1
* @return groupId
* @return Long
*/
public Integer getGroupId() {
return this.groupId;
public Long getGroupId(){
return groupId;
}
/**
* 设置 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupId
*/
public void setGroupId(Integer groupId) {
public void setGroupId(Long groupId){
this.groupId = groupId;
}
public Integer getGroupName() {
/**
* 获取
* @return String
*/
public String getGroupName(){
return groupName;
}
public void setGroupName(Integer groupName) {
/**
* 设置
* @param groupName
*/
public void setGroupName(String groupName){
this.groupName = groupName;
}
/**
* 获取 主菜单图标,主菜单图标的css样式名
* @return imgPath
* @return String
*/
public String getImgPath() {
return this.imgPath;
public String getImgPath(){
return imgPath;
}
/**
* 设置 主菜单图标,主菜单图标的css样式名
* @param imgPath
*/
public void setImgPath(String imgPath) {
public void setImgPath(String imgPath){
this.imgPath = imgPath;
}
/**
* 获取 按钮图标,按钮图标的css样式名
* @return buttonImgPath
* @return String
*/
public String getButtonImgPath() {
return this.buttonImgPath;
public String getButtonImgPath(){
return buttonImgPath;
}
/**
* 设置 按钮图标,按钮图标的css样式名
* @param buttonImgPath
*/
public void setButtonImgPath(String buttonImgPath) {
public void setButtonImgPath(String buttonImgPath){
this.buttonImgPath = buttonImgPath;
}
/**
* 获取 常用菜单图标,常用菜单图标的css样式名
* @return imgCommPath
* @return String
*/
public String getImgCommPath() {
return this.imgCommPath;
public String getImgCommPath(){
return imgCommPath;
}
/**
* 设置 常用菜单图标,常用菜单图标的css样式名
* @param imgCommPath
*/
public void setImgCommPath(String imgCommPath) {
public void setImgCommPath(String imgCommPath){
this.imgCommPath = imgCommPath;
}
/**
* 获取 是否常用菜单,0:非常用,1:常用,默认0
* @return commMenu
* @return Integer
*/
public Integer getCommMenu() {
return this.commMenu;
public Integer getCommMenu(){
return commMenu;
}
/**
* 设置 是否常用菜单,0:非常用,1:常用,默认0
* @param commMenu
*/
public void setCommMenu(Integer commMenu) {
public void setCommMenu(Integer commMenu){
this.commMenu = commMenu;
}
/**
* 获取 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @return menuType
* @return Integer
*/
public Integer getMenuType() {
return this.menuType;
public Integer getMenuType(){
return menuType;
}
/**
* 设置 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @param menuType
*/
public void setMenuType(Integer menuType) {
public void setMenuType(Integer menuType){
this.menuType = menuType;
}
/**
* 获取 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @return authType
* @return Integer
*/
public Integer getAuthType() {
return this.authType;
public Integer getAuthType(){
return authType;
}
/**
* 设置 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @param authType
*/
public void setAuthType(Integer authType) {
public void setAuthType(Integer authType){
this.authType = authType;
}
/**
* 获取 创建时间
* @return createTime
*/
@Override
public Date getCreateTime() {
return this.createTime;
}
/**
* 设置 创建时间
* @param createTime
*/
@Override
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
/**
* 获取 创建用户
* @return createUser
*/
@Override
public String getCreateUser() {
return this.createUser;
}
/**
* 设置 创建用户
* @param createUser
*/
@Override
public void setCreateUser(String createUser) {
this.createUser = createUser;
}
/**
* 获取 创建用户名称
* @return createUserName
* @return String
*/
@Override
public String getCreateUserName() {
return this.createUserName;
public String getCreateUserName(){
return createUserName;
}
/**
* 设置 创建用户名称
* @param createUserName
*/
@Override
public void setCreateUserName(String createUserName) {
public void setCreateUserName(String createUserName){
this.createUserName = createUserName;
}
public List<MenuEntity> getChildList() {
return childList;
}
public void setChildList(List<MenuEntity> childList) {
this.childList = childList;
}
@Override
public int hashCode() {
return this.getId().hashCode();
}
@Override
public boolean equals(Object obj) {
if (obj == null) {
return false;
}
if (obj == null) return false;
if (obj instanceof MenuEntity) {
MenuEntity tmp = (MenuEntity) obj;
if (this.getId().longValue() == tmp.getId().longValue()) {
if (this.getId() == tmp.getId()) {
return true;
}
}
return false;
}
@Override
public String toString() {
public String toString(){
StringBuilder sb = new StringBuilder("");
sb.append("id:").append(getId())
.append(",name:").append(getName())
.append(",url:").append(getUrl())
.append(",parentId:").append(getParentId())
.append(",orderId:").append(getOrderId())
.append(",status:").append(getStatus())
.append(",linkType:").append(getLinkType())
.append(",groupId:").append(getGroupId())
.append(",groupName:").append(getGroupName())
.append(",imgPath:").append(getImgPath())
.append(",buttonImgPath:").append(getButtonImgPath())
.append(",imgCommPath:").append(getImgCommPath())
.append(",commMenu:").append(getCommMenu())
.append(",menuType:").append(getMenuType())
.append(",authType:").append(getAuthType())
.append(",createTime:").append(getCreateTime())
.append(",createUser:").append(getCreateUser())
.append(",createUserName:").append(getCreateUserName());
sb.append(",name:").append(getName());
sb.append(",url:").append(getUrl());
sb.append(",ancestors:").append(getAncestors());
sb.append(",parentId:").append(getParentId());
sb.append(",orderId:").append(getOrderId());
sb.append(",status:").append(getStatus());
sb.append(",linkType:").append(getLinkType());
sb.append(",groupId:").append(getGroupId());
sb.append(",groupName:").append(getGroupName());
sb.append(",imgPath:").append(getImgPath());
sb.append(",buttonImgPath:").append(getButtonImgPath());
sb.append(",imgCommPath:").append(getImgCommPath());
sb.append(",commMenu:").append(getCommMenu());
sb.append(",menuType:").append(getMenuType());
sb.append(",authType:").append(getAuthType());
sb.append(",createUserName:").append(getCreateUserName());
return sb.toString();
}
@Override
public void initAttrValue() {
this.name = null;
this.url = null;
this.parentId = null;
this.orderId = 0;
public void initAttrValue(){
this.name = "";
this.url = "";
this.ancestors = "";
this.parentId = 0L;
this.orderId = 1;
this.status = 1;
this.linkType = 0;
this.groupId = 1;
this.imgPath = null;
this.buttonImgPath = null;
this.imgCommPath = null;
this.groupId = 1L;
this.groupName = "";
this.imgPath = "";
this.buttonImgPath = "";
this.imgCommPath = "";
this.commMenu = 0;
this.menuType = 0;
this.authType = 3;
this.createTime = null;
this.createUser = null;
this.createUserName = null;
}
}
\ No newline at end of file
/**
* 文件:MenuQuery.java
* 版本:1.0.0
* 日期:
* Copyright &reg;
* All right reserved.
*/
package com.mortals.xhx.base.system.menu.model;
import java.util.List;
/**
* <p>Title: 菜单信息</p>
* <p>Description: MenuQuery </p>
* <p>Copyright: Copyright &reg; </p>
* <p>Company: </p>
* @author
* @version 1.0.0
*/
public class MenuQuery extends MenuEntity{
private static final long serialVersionUID = 1547777703329L;
* 菜单信息查询对象
*
* @author zxfei
* @date 2023-04-10
*/
public class MenuQuery extends MenuEntity {
/** 开始 菜单ID,主键,自增长 */
private Long idStart;
......@@ -27,15 +17,27 @@ public class MenuQuery extends MenuEntity{
/** 增加 菜单ID,主键,自增长 */
private Long idIncrement;
/** 菜单ID,主键,自增长 */
private List<Long> idList;
/** 菜单ID,主键,自增长列表 */
private List <Long> idList;
/** 菜单ID,主键,自增长排除列表 */
private List <Long> idNotList;
/** 菜单名称 */
private List<String> nameList;
/** 菜单名称排除列表 */
private List <String> nameNotList;
/** 连接地址 */
private List<String> urlList;
/** 连接地址排除列表 */
private List <String> urlNotList;
/** 当前节点父id路径,“,”分割,服务端生成 */
private List<String> ancestorsList;
/** 当前节点父id路径,“,”分割,服务端生成排除列表 */
private List <String> ancestorsNotList;
/** 开始 父菜单ID,一级菜单的该字段值为-1 */
private Long parentIdStart;
......@@ -45,8 +47,11 @@ public class MenuQuery extends MenuEntity{
/** 增加 父菜单ID,一级菜单的该字段值为-1 */
private Long parentIdIncrement;
/** 父菜单ID,一级菜单的该字段值为-1 */
private List<Long> parentIdList;
/** 父菜单ID,一级菜单的该字段值为-1列表 */
private List <Long> parentIdList;
/** 父菜单ID,一级菜单的该字段值为-1排除列表 */
private List <Long> parentIdNotList;
/** 开始 排序编号 */
private Integer orderIdStart;
......@@ -57,8 +62,11 @@ public class MenuQuery extends MenuEntity{
/** 增加 排序编号 */
private Integer orderIdIncrement;
/** 排序编号 */
private List<Integer> orderIdList;
/** 排序编号列表 */
private List <Integer> orderIdList;
/** 排序编号排除列表 */
private List <Integer> orderIdNotList;
/** 开始 菜单状态,0:禁用,1:启用,默认1 */
private Integer statusStart;
......@@ -69,8 +77,11 @@ public class MenuQuery extends MenuEntity{
/** 增加 菜单状态,0:禁用,1:启用,默认1 */
private Integer statusIncrement;
/** 菜单状态,0:禁用,1:启用,默认1 */
private List<Integer> statusList;
/** 菜单状态,0:禁用,1:启用,默认1列表 */
private List <Integer> statusList;
/** 菜单状态,0:禁用,1:启用,默认1排除列表 */
private List <Integer> statusNotList;
/** 开始 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0 */
private Integer linkTypeStart;
......@@ -81,33 +92,47 @@ public class MenuQuery extends MenuEntity{
/** 增加 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0 */
private Integer linkTypeIncrement;
/** 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0 */
private List<Integer> linkTypeList;
/** 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0列表 */
private List <Integer> linkTypeList;
/** 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0排除列表 */
private List <Integer> linkTypeNotList;
/** 开始 分组编号,使用菜单分隔符按该值分隔,默认1 */
private Integer groupIdStart;
private Long groupIdStart;
/** 结束 分组编号,使用菜单分隔符按该值分隔,默认1 */
private Integer groupIdEnd;
private Long groupIdEnd;
/** 增加 分组编号,使用菜单分隔符按该值分隔,默认1 */
private Integer groupIdIncrement;
private Long groupIdIncrement;
/** 分组编号,使用菜单分隔符按该值分隔,默认1 */
private List<Integer> groupIdList;
/** 分组编号,使用菜单分隔符按该值分隔,默认1列表 */
private List <Long> groupIdList;
/** 分组名称 */
/** 分组编号,使用菜单分隔符按该值分隔,默认1排除列表 */
private List <Long> groupIdNotList;
/** */
private List<String> groupNameList;
/** 排除列表 */
private List <String> groupNameNotList;
/** 主菜单图标,主菜单图标的css样式名 */
private List<String> imgPathList;
/** 主菜单图标,主菜单图标的css样式名排除列表 */
private List <String> imgPathNotList;
/** 按钮图标,按钮图标的css样式名 */
private List<String> buttonImgPathList;
/** 按钮图标,按钮图标的css样式名排除列表 */
private List <String> buttonImgPathNotList;
/** 常用菜单图标,常用菜单图标的css样式名 */
private List<String> imgCommPathList;
/** 常用菜单图标,常用菜单图标的css样式名排除列表 */
private List <String> imgCommPathNotList;
/** 开始 是否常用菜单,0:非常用,1:常用,默认0 */
private Integer commMenuStart;
......@@ -117,8 +142,11 @@ public class MenuQuery extends MenuEntity{
/** 增加 是否常用菜单,0:非常用,1:常用,默认0 */
private Integer commMenuIncrement;
/** 是否常用菜单,0:非常用,1:常用,默认0 */
private List<Integer> commMenuList;
/** 是否常用菜单,0:非常用,1:常用,默认0列表 */
private List <Integer> commMenuList;
/** 是否常用菜单,0:非常用,1:常用,默认0排除列表 */
private List <Integer> commMenuNotList;
/** 开始 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0 */
private Integer menuTypeStart;
......@@ -129,8 +157,11 @@ public class MenuQuery extends MenuEntity{
/** 增加 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0 */
private Integer menuTypeIncrement;
/** 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0 */
private List<Integer> menuTypeList;
/** 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0列表 */
private List <Integer> menuTypeList;
/** 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0排除列表 */
private List <Integer> menuTypeNotList;
/** 开始 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3 */
private Integer authTypeStart;
......@@ -141,8 +172,11 @@ public class MenuQuery extends MenuEntity{
/** 增加 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3 */
private Integer authTypeIncrement;
/** 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3 */
private List<Integer> authTypeList;
/** 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3列表 */
private List <Integer> authTypeList;
/** 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3排除列表 */
private List <Integer> authTypeNotList;
/** 开始 创建时间 */
private String createTimeStart;
......@@ -159,15 +193,25 @@ public class MenuQuery extends MenuEntity{
/** 增加 创建用户 */
private Long createUserIdIncrement;
/** 创建用户 */
private List<Long> createUserIdList;
/** 创建用户列表 */
private List <Long> createUserIdList;
/** 创建用户排除列表 */
private List <Long> createUserIdNotList;
/** 创建用户名称 */
private List<String> createUserNameList;
/** 创建用户名称排除列表 */
private List <String> createUserNameNotList;
/** OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4) */
private List<MenuQuery> orConditionList;
/** AND条件集合,列表项之间是AND,项内容之间是OR,如:(list[0].1 or list[0].2) and (list[1].3 or list[1].4) */
private List<MenuQuery> andConditionList;
public MenuQuery(){}
public MenuQuery(){
}
/**
* 获取 开始 菜单ID,主键,自增长
* @return idStart
......@@ -186,7 +230,7 @@ public class MenuQuery extends MenuEntity{
/**
* 获取 结束 菜单ID,主键,自增长
* @return idEnd
* @return $idEnd
*/
public Long getIdEnd(){
return this.idEnd;
......@@ -232,6 +276,23 @@ public class MenuQuery extends MenuEntity{
this.idList = idList;
}
/**
* 获取 菜单ID,主键,自增长
* @return idNotList
*/
public List<Long> getIdNotList(){
return this.idNotList;
}
/**
* 设置 菜单ID,主键,自增长
* @param idNotList
*/
public void setIdNotList(List<Long> idNotList){
this.idNotList = idNotList;
}
/**
* 获取 菜单名称
* @return nameList
......@@ -248,6 +309,22 @@ public class MenuQuery extends MenuEntity{
this.nameList = nameList;
}
/**
* 获取 菜单名称
* @return nameNotList
*/
public List<String> getNameNotList(){
return this.nameNotList;
}
/**
* 设置 菜单名称
* @param nameNotList
*/
public void setNameNotList(List<String> nameNotList){
this.nameNotList = nameNotList;
}
/**
* 获取 连接地址
* @return urlList
......@@ -264,6 +341,54 @@ public class MenuQuery extends MenuEntity{
this.urlList = urlList;
}
/**
* 获取 连接地址
* @return urlNotList
*/
public List<String> getUrlNotList(){
return this.urlNotList;
}
/**
* 设置 连接地址
* @param urlNotList
*/
public void setUrlNotList(List<String> urlNotList){
this.urlNotList = urlNotList;
}
/**
* 获取 当前节点父id路径,“,”分割,服务端生成
* @return ancestorsList
*/
public List<String> getAncestorsList(){
return this.ancestorsList;
}
/**
* 设置 当前节点父id路径,“,”分割,服务端生成
* @param ancestorsList
*/
public void setAncestorsList(List<String> ancestorsList){
this.ancestorsList = ancestorsList;
}
/**
* 获取 当前节点父id路径,“,”分割,服务端生成
* @return ancestorsNotList
*/
public List<String> getAncestorsNotList(){
return this.ancestorsNotList;
}
/**
* 设置 当前节点父id路径,“,”分割,服务端生成
* @param ancestorsNotList
*/
public void setAncestorsNotList(List<String> ancestorsNotList){
this.ancestorsNotList = ancestorsNotList;
}
/**
* 获取 开始 父菜单ID,一级菜单的该字段值为-1
* @return parentIdStart
......@@ -282,7 +407,7 @@ public class MenuQuery extends MenuEntity{
/**
* 获取 结束 父菜单ID,一级菜单的该字段值为-1
* @return parentIdEnd
* @return $parentIdEnd
*/
public Long getParentIdEnd(){
return this.parentIdEnd;
......@@ -328,6 +453,23 @@ public class MenuQuery extends MenuEntity{
this.parentIdList = parentIdList;
}
/**
* 获取 父菜单ID,一级菜单的该字段值为-1
* @return parentIdNotList
*/
public List<Long> getParentIdNotList(){
return this.parentIdNotList;
}
/**
* 设置 父菜单ID,一级菜单的该字段值为-1
* @param parentIdNotList
*/
public void setParentIdNotList(List<Long> parentIdNotList){
this.parentIdNotList = parentIdNotList;
}
/**
* 获取 开始 排序编号
* @return orderIdStart
......@@ -346,7 +488,7 @@ public class MenuQuery extends MenuEntity{
/**
* 获取 结束 排序编号
* @return orderIdEnd
* @return $orderIdEnd
*/
public Integer getOrderIdEnd(){
return this.orderIdEnd;
......@@ -392,6 +534,23 @@ public class MenuQuery extends MenuEntity{
this.orderIdList = orderIdList;
}
/**
* 获取 排序编号
* @return orderIdNotList
*/
public List<Integer> getOrderIdNotList(){
return this.orderIdNotList;
}
/**
* 设置 排序编号
* @param orderIdNotList
*/
public void setOrderIdNotList(List<Integer> orderIdNotList){
this.orderIdNotList = orderIdNotList;
}
/**
* 获取 开始 菜单状态,0:禁用,1:启用,默认1
* @return statusStart
......@@ -410,7 +569,7 @@ public class MenuQuery extends MenuEntity{
/**
* 获取 结束 菜单状态,0:禁用,1:启用,默认1
* @return statusEnd
* @return $statusEnd
*/
public Integer getStatusEnd(){
return this.statusEnd;
......@@ -456,6 +615,23 @@ public class MenuQuery extends MenuEntity{
this.statusList = statusList;
}
/**
* 获取 菜单状态,0:禁用,1:启用,默认1
* @return statusNotList
*/
public List<Integer> getStatusNotList(){
return this.statusNotList;
}
/**
* 设置 菜单状态,0:禁用,1:启用,默认1
* @param statusNotList
*/
public void setStatusNotList(List<Integer> statusNotList){
this.statusNotList = statusNotList;
}
/**
* 获取 开始 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @return linkTypeStart
......@@ -474,7 +650,7 @@ public class MenuQuery extends MenuEntity{
/**
* 获取 结束 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @return linkTypeEnd
* @return $linkTypeEnd
*/
public Integer getLinkTypeEnd(){
return this.linkTypeEnd;
......@@ -520,11 +696,28 @@ public class MenuQuery extends MenuEntity{
this.linkTypeList = linkTypeList;
}
/**
* 获取 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @return linkTypeNotList
*/
public List<Integer> getLinkTypeNotList(){
return this.linkTypeNotList;
}
/**
* 设置 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @param linkTypeNotList
*/
public void setLinkTypeNotList(List<Integer> linkTypeNotList){
this.linkTypeNotList = linkTypeNotList;
}
/**
* 获取 开始 分组编号,使用菜单分隔符按该值分隔,默认1
* @return groupIdStart
*/
public Integer getGroupIdStart(){
public Long getGroupIdStart(){
return this.groupIdStart;
}
......@@ -532,15 +725,15 @@ public class MenuQuery extends MenuEntity{
* 设置 开始 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupIdStart
*/
public void setGroupIdStart(Integer groupIdStart){
public void setGroupIdStart(Long groupIdStart){
this.groupIdStart = groupIdStart;
}
/**
* 获取 结束 分组编号,使用菜单分隔符按该值分隔,默认1
* @return groupIdEnd
* @return $groupIdEnd
*/
public Integer getGroupIdEnd(){
public Long getGroupIdEnd(){
return this.groupIdEnd;
}
......@@ -548,7 +741,7 @@ public class MenuQuery extends MenuEntity{
* 设置 结束 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupIdEnd
*/
public void setGroupIdEnd(Integer groupIdEnd){
public void setGroupIdEnd(Long groupIdEnd){
this.groupIdEnd = groupIdEnd;
}
......@@ -556,7 +749,7 @@ public class MenuQuery extends MenuEntity{
* 获取 增加 分组编号,使用菜单分隔符按该值分隔,默认1
* @return groupIdIncrement
*/
public Integer getGroupIdIncrement(){
public Long getGroupIdIncrement(){
return this.groupIdIncrement;
}
......@@ -564,7 +757,7 @@ public class MenuQuery extends MenuEntity{
* 设置 增加 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupIdIncrement
*/
public void setGroupIdIncrement(Integer groupIdIncrement){
public void setGroupIdIncrement(Long groupIdIncrement){
this.groupIdIncrement = groupIdIncrement;
}
......@@ -572,7 +765,7 @@ public class MenuQuery extends MenuEntity{
* 获取 分组编号,使用菜单分隔符按该值分隔,默认1
* @return groupIdList
*/
public List<Integer> getGroupIdList(){
public List<Long> getGroupIdList(){
return this.groupIdList;
}
......@@ -580,12 +773,29 @@ public class MenuQuery extends MenuEntity{
* 设置 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupIdList
*/
public void setGroupIdList(List<Integer> groupIdList){
public void setGroupIdList(List<Long> groupIdList){
this.groupIdList = groupIdList;
}
/**
* 获取 分组名称
* 获取 分组编号,使用菜单分隔符按该值分隔,默认1
* @return groupIdNotList
*/
public List<Long> getGroupIdNotList(){
return this.groupIdNotList;
}
/**
* 设置 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupIdNotList
*/
public void setGroupIdNotList(List<Long> groupIdNotList){
this.groupIdNotList = groupIdNotList;
}
/**
* 获取
* @return groupNameList
*/
public List<String> getGroupNameList(){
......@@ -593,13 +803,29 @@ public class MenuQuery extends MenuEntity{
}
/**
* 设置 分组名称
* 设置
* @param groupNameList
*/
public void setGroupNameList(List<String> groupNameList){
this.groupNameList = groupNameList;
}
/**
* 获取
* @return groupNameNotList
*/
public List<String> getGroupNameNotList(){
return this.groupNameNotList;
}
/**
* 设置
* @param groupNameNotList
*/
public void setGroupNameNotList(List<String> groupNameNotList){
this.groupNameNotList = groupNameNotList;
}
/**
* 获取 主菜单图标,主菜单图标的css样式名
* @return imgPathList
......@@ -616,6 +842,22 @@ public class MenuQuery extends MenuEntity{
this.imgPathList = imgPathList;
}
/**
* 获取 主菜单图标,主菜单图标的css样式名
* @return imgPathNotList
*/
public List<String> getImgPathNotList(){
return this.imgPathNotList;
}
/**
* 设置 主菜单图标,主菜单图标的css样式名
* @param imgPathNotList
*/
public void setImgPathNotList(List<String> imgPathNotList){
this.imgPathNotList = imgPathNotList;
}
/**
* 获取 按钮图标,按钮图标的css样式名
* @return buttonImgPathList
......@@ -632,6 +874,22 @@ public class MenuQuery extends MenuEntity{
this.buttonImgPathList = buttonImgPathList;
}
/**
* 获取 按钮图标,按钮图标的css样式名
* @return buttonImgPathNotList
*/
public List<String> getButtonImgPathNotList(){
return this.buttonImgPathNotList;
}
/**
* 设置 按钮图标,按钮图标的css样式名
* @param buttonImgPathNotList
*/
public void setButtonImgPathNotList(List<String> buttonImgPathNotList){
this.buttonImgPathNotList = buttonImgPathNotList;
}
/**
* 获取 常用菜单图标,常用菜单图标的css样式名
* @return imgCommPathList
......@@ -648,6 +906,22 @@ public class MenuQuery extends MenuEntity{
this.imgCommPathList = imgCommPathList;
}
/**
* 获取 常用菜单图标,常用菜单图标的css样式名
* @return imgCommPathNotList
*/
public List<String> getImgCommPathNotList(){
return this.imgCommPathNotList;
}
/**
* 设置 常用菜单图标,常用菜单图标的css样式名
* @param imgCommPathNotList
*/
public void setImgCommPathNotList(List<String> imgCommPathNotList){
this.imgCommPathNotList = imgCommPathNotList;
}
/**
* 获取 开始 是否常用菜单,0:非常用,1:常用,默认0
* @return commMenuStart
......@@ -666,7 +940,7 @@ public class MenuQuery extends MenuEntity{
/**
* 获取 结束 是否常用菜单,0:非常用,1:常用,默认0
* @return commMenuEnd
* @return $commMenuEnd
*/
public Integer getCommMenuEnd(){
return this.commMenuEnd;
......@@ -712,6 +986,23 @@ public class MenuQuery extends MenuEntity{
this.commMenuList = commMenuList;
}
/**
* 获取 是否常用菜单,0:非常用,1:常用,默认0
* @return commMenuNotList
*/
public List<Integer> getCommMenuNotList(){
return this.commMenuNotList;
}
/**
* 设置 是否常用菜单,0:非常用,1:常用,默认0
* @param commMenuNotList
*/
public void setCommMenuNotList(List<Integer> commMenuNotList){
this.commMenuNotList = commMenuNotList;
}
/**
* 获取 开始 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @return menuTypeStart
......@@ -730,7 +1021,7 @@ public class MenuQuery extends MenuEntity{
/**
* 获取 结束 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @return menuTypeEnd
* @return $menuTypeEnd
*/
public Integer getMenuTypeEnd(){
return this.menuTypeEnd;
......@@ -776,6 +1067,23 @@ public class MenuQuery extends MenuEntity{
this.menuTypeList = menuTypeList;
}
/**
* 获取 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @return menuTypeNotList
*/
public List<Integer> getMenuTypeNotList(){
return this.menuTypeNotList;
}
/**
* 设置 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @param menuTypeNotList
*/
public void setMenuTypeNotList(List<Integer> menuTypeNotList){
this.menuTypeNotList = menuTypeNotList;
}
/**
* 获取 开始 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @return authTypeStart
......@@ -794,7 +1102,7 @@ public class MenuQuery extends MenuEntity{
/**
* 获取 结束 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @return authTypeEnd
* @return $authTypeEnd
*/
public Integer getAuthTypeEnd(){
return this.authTypeEnd;
......@@ -840,6 +1148,23 @@ public class MenuQuery extends MenuEntity{
this.authTypeList = authTypeList;
}
/**
* 获取 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @return authTypeNotList
*/
public List<Integer> getAuthTypeNotList(){
return this.authTypeNotList;
}
/**
* 设置 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @param authTypeNotList
*/
public void setAuthTypeNotList(List<Integer> authTypeNotList){
this.authTypeNotList = authTypeNotList;
}
/**
* 获取 开始 创建时间
* @return createTimeStart
......@@ -890,7 +1215,7 @@ public class MenuQuery extends MenuEntity{
/**
* 获取 结束 创建用户
* @return createUserIdEnd
* @return $createUserIdEnd
*/
public Long getCreateUserIdEnd(){
return this.createUserIdEnd;
......@@ -936,6 +1261,23 @@ public class MenuQuery extends MenuEntity{
this.createUserIdList = createUserIdList;
}
/**
* 获取 创建用户
* @return createUserIdNotList
*/
public List<Long> getCreateUserIdNotList(){
return this.createUserIdNotList;
}
/**
* 设置 创建用户
* @param createUserIdNotList
*/
public void setCreateUserIdNotList(List<Long> createUserIdNotList){
this.createUserIdNotList = createUserIdNotList;
}
/**
* 获取 创建用户名称
* @return createUserNameList
......@@ -952,5 +1294,745 @@ public class MenuQuery extends MenuEntity{
this.createUserNameList = createUserNameList;
}
/**
* 获取 创建用户名称
* @return createUserNameNotList
*/
public List<String> getCreateUserNameNotList(){
return this.createUserNameNotList;
}
/**
* 设置 创建用户名称
* @param createUserNameNotList
*/
public void setCreateUserNameNotList(List<String> createUserNameNotList){
this.createUserNameNotList = createUserNameNotList;
}
/**
* 设置 菜单ID,主键,自增长
* @param id
*/
public MenuQuery id(Long id){
setId(id);
return this;
}
/**
* 设置 开始 菜单ID,主键,自增长
* @param idStart
*/
public MenuQuery idStart(Long idStart){
this.idStart = idStart;
return this;
}
/**
* 设置 结束 菜单ID,主键,自增长
* @param idEnd
*/
public MenuQuery idEnd(Long idEnd){
this.idEnd = idEnd;
return this;
}
/**
* 设置 增加 菜单ID,主键,自增长
* @param idIncrement
*/
public MenuQuery idIncrement(Long idIncrement){
this.idIncrement = idIncrement;
return this;
}
/**
* 设置 菜单ID,主键,自增长
* @param idList
*/
public MenuQuery idList(List<Long> idList){
this.idList = idList;
return this;
}
/**
* 设置 菜单ID,主键,自增长
* @param idNotList
*/
public MenuQuery idNotList(List<Long> idNotList){
this.idNotList = idNotList;
return this;
}
/**
* 设置 菜单名称
* @param name
*/
public MenuQuery name(String name){
setName(name);
return this;
}
/**
* 设置 菜单名称
* @param nameList
*/
public MenuQuery nameList(List<String> nameList){
this.nameList = nameList;
return this;
}
/**
* 设置 连接地址
* @param url
*/
public MenuQuery url(String url){
setUrl(url);
return this;
}
/**
* 设置 连接地址
* @param urlList
*/
public MenuQuery urlList(List<String> urlList){
this.urlList = urlList;
return this;
}
/**
* 设置 当前节点父id路径,“,”分割,服务端生成
* @param ancestors
*/
public MenuQuery ancestors(String ancestors){
setAncestors(ancestors);
return this;
}
/**
* 设置 当前节点父id路径,“,”分割,服务端生成
* @param ancestorsList
*/
public MenuQuery ancestorsList(List<String> ancestorsList){
this.ancestorsList = ancestorsList;
return this;
}
/**
* 设置 父菜单ID,一级菜单的该字段值为-1
* @param parentId
*/
public MenuQuery parentId(Long parentId){
setParentId(parentId);
return this;
}
/**
* 设置 开始 父菜单ID,一级菜单的该字段值为-1
* @param parentIdStart
*/
public MenuQuery parentIdStart(Long parentIdStart){
this.parentIdStart = parentIdStart;
return this;
}
/**
* 设置 结束 父菜单ID,一级菜单的该字段值为-1
* @param parentIdEnd
*/
public MenuQuery parentIdEnd(Long parentIdEnd){
this.parentIdEnd = parentIdEnd;
return this;
}
/**
* 设置 增加 父菜单ID,一级菜单的该字段值为-1
* @param parentIdIncrement
*/
public MenuQuery parentIdIncrement(Long parentIdIncrement){
this.parentIdIncrement = parentIdIncrement;
return this;
}
/**
* 设置 父菜单ID,一级菜单的该字段值为-1
* @param parentIdList
*/
public MenuQuery parentIdList(List<Long> parentIdList){
this.parentIdList = parentIdList;
return this;
}
/**
* 设置 父菜单ID,一级菜单的该字段值为-1
* @param parentIdNotList
*/
public MenuQuery parentIdNotList(List<Long> parentIdNotList){
this.parentIdNotList = parentIdNotList;
return this;
}
/**
* 设置 排序编号
* @param orderId
*/
public MenuQuery orderId(Integer orderId){
setOrderId(orderId);
return this;
}
/**
* 设置 开始 排序编号
* @param orderIdStart
*/
public MenuQuery orderIdStart(Integer orderIdStart){
this.orderIdStart = orderIdStart;
return this;
}
/**
* 设置 结束 排序编号
* @param orderIdEnd
*/
public MenuQuery orderIdEnd(Integer orderIdEnd){
this.orderIdEnd = orderIdEnd;
return this;
}
/**
* 设置 增加 排序编号
* @param orderIdIncrement
*/
public MenuQuery orderIdIncrement(Integer orderIdIncrement){
this.orderIdIncrement = orderIdIncrement;
return this;
}
/**
* 设置 排序编号
* @param orderIdList
*/
public MenuQuery orderIdList(List<Integer> orderIdList){
this.orderIdList = orderIdList;
return this;
}
/**
* 设置 排序编号
* @param orderIdNotList
*/
public MenuQuery orderIdNotList(List<Integer> orderIdNotList){
this.orderIdNotList = orderIdNotList;
return this;
}
/**
* 设置 菜单状态,0:禁用,1:启用,默认1
* @param status
*/
public MenuQuery status(Integer status){
setStatus(status);
return this;
}
/**
* 设置 开始 菜单状态,0:禁用,1:启用,默认1
* @param statusStart
*/
public MenuQuery statusStart(Integer statusStart){
this.statusStart = statusStart;
return this;
}
/**
* 设置 结束 菜单状态,0:禁用,1:启用,默认1
* @param statusEnd
*/
public MenuQuery statusEnd(Integer statusEnd){
this.statusEnd = statusEnd;
return this;
}
/**
* 设置 增加 菜单状态,0:禁用,1:启用,默认1
* @param statusIncrement
*/
public MenuQuery statusIncrement(Integer statusIncrement){
this.statusIncrement = statusIncrement;
return this;
}
/**
* 设置 菜单状态,0:禁用,1:启用,默认1
* @param statusList
*/
public MenuQuery statusList(List<Integer> statusList){
this.statusList = statusList;
return this;
}
/**
* 设置 菜单状态,0:禁用,1:启用,默认1
* @param statusNotList
*/
public MenuQuery statusNotList(List<Integer> statusNotList){
this.statusNotList = statusNotList;
return this;
}
/**
* 设置 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @param linkType
*/
public MenuQuery linkType(Integer linkType){
setLinkType(linkType);
return this;
}
/**
* 设置 开始 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @param linkTypeStart
*/
public MenuQuery linkTypeStart(Integer linkTypeStart){
this.linkTypeStart = linkTypeStart;
return this;
}
/**
* 设置 结束 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @param linkTypeEnd
*/
public MenuQuery linkTypeEnd(Integer linkTypeEnd){
this.linkTypeEnd = linkTypeEnd;
return this;
}
/**
* 设置 增加 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @param linkTypeIncrement
*/
public MenuQuery linkTypeIncrement(Integer linkTypeIncrement){
this.linkTypeIncrement = linkTypeIncrement;
return this;
}
/**
* 设置 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @param linkTypeList
*/
public MenuQuery linkTypeList(List<Integer> linkTypeList){
this.linkTypeList = linkTypeList;
return this;
}
/**
* 设置 链接方式,0:普通,1:弹出,2:脚本(JavaScript),默认0
* @param linkTypeNotList
*/
public MenuQuery linkTypeNotList(List<Integer> linkTypeNotList){
this.linkTypeNotList = linkTypeNotList;
return this;
}
/**
* 设置 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupId
*/
public MenuQuery groupId(Long groupId){
setGroupId(groupId);
return this;
}
/**
* 设置 开始 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupIdStart
*/
public MenuQuery groupIdStart(Long groupIdStart){
this.groupIdStart = groupIdStart;
return this;
}
/**
* 设置 结束 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupIdEnd
*/
public MenuQuery groupIdEnd(Long groupIdEnd){
this.groupIdEnd = groupIdEnd;
return this;
}
/**
* 设置 增加 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupIdIncrement
*/
public MenuQuery groupIdIncrement(Long groupIdIncrement){
this.groupIdIncrement = groupIdIncrement;
return this;
}
/**
* 设置 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupIdList
*/
public MenuQuery groupIdList(List<Long> groupIdList){
this.groupIdList = groupIdList;
return this;
}
/**
* 设置 分组编号,使用菜单分隔符按该值分隔,默认1
* @param groupIdNotList
*/
public MenuQuery groupIdNotList(List<Long> groupIdNotList){
this.groupIdNotList = groupIdNotList;
return this;
}
/**
* 设置
* @param groupName
*/
public MenuQuery groupName(String groupName){
setGroupName(groupName);
return this;
}
/**
* 设置
* @param groupNameList
*/
public MenuQuery groupNameList(List<String> groupNameList){
this.groupNameList = groupNameList;
return this;
}
/**
* 设置 主菜单图标,主菜单图标的css样式名
* @param imgPath
*/
public MenuQuery imgPath(String imgPath){
setImgPath(imgPath);
return this;
}
/**
* 设置 主菜单图标,主菜单图标的css样式名
* @param imgPathList
*/
public MenuQuery imgPathList(List<String> imgPathList){
this.imgPathList = imgPathList;
return this;
}
/**
* 设置 按钮图标,按钮图标的css样式名
* @param buttonImgPath
*/
public MenuQuery buttonImgPath(String buttonImgPath){
setButtonImgPath(buttonImgPath);
return this;
}
/**
* 设置 按钮图标,按钮图标的css样式名
* @param buttonImgPathList
*/
public MenuQuery buttonImgPathList(List<String> buttonImgPathList){
this.buttonImgPathList = buttonImgPathList;
return this;
}
/**
* 设置 常用菜单图标,常用菜单图标的css样式名
* @param imgCommPath
*/
public MenuQuery imgCommPath(String imgCommPath){
setImgCommPath(imgCommPath);
return this;
}
/**
* 设置 常用菜单图标,常用菜单图标的css样式名
* @param imgCommPathList
*/
public MenuQuery imgCommPathList(List<String> imgCommPathList){
this.imgCommPathList = imgCommPathList;
return this;
}
/**
* 设置 是否常用菜单,0:非常用,1:常用,默认0
* @param commMenu
*/
public MenuQuery commMenu(Integer commMenu){
setCommMenu(commMenu);
return this;
}
/**
* 设置 开始 是否常用菜单,0:非常用,1:常用,默认0
* @param commMenuStart
*/
public MenuQuery commMenuStart(Integer commMenuStart){
this.commMenuStart = commMenuStart;
return this;
}
/**
* 设置 结束 是否常用菜单,0:非常用,1:常用,默认0
* @param commMenuEnd
*/
public MenuQuery commMenuEnd(Integer commMenuEnd){
this.commMenuEnd = commMenuEnd;
return this;
}
/**
* 设置 增加 是否常用菜单,0:非常用,1:常用,默认0
* @param commMenuIncrement
*/
public MenuQuery commMenuIncrement(Integer commMenuIncrement){
this.commMenuIncrement = commMenuIncrement;
return this;
}
/**
* 设置 是否常用菜单,0:非常用,1:常用,默认0
* @param commMenuList
*/
public MenuQuery commMenuList(List<Integer> commMenuList){
this.commMenuList = commMenuList;
return this;
}
/**
* 设置 是否常用菜单,0:非常用,1:常用,默认0
* @param commMenuNotList
*/
public MenuQuery commMenuNotList(List<Integer> commMenuNotList){
this.commMenuNotList = commMenuNotList;
return this;
}
/**
* 设置 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @param menuType
*/
public MenuQuery menuType(Integer menuType){
setMenuType(menuType);
return this;
}
/**
* 设置 开始 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @param menuTypeStart
*/
public MenuQuery menuTypeStart(Integer menuTypeStart){
this.menuTypeStart = menuTypeStart;
return this;
}
/**
* 设置 结束 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @param menuTypeEnd
*/
public MenuQuery menuTypeEnd(Integer menuTypeEnd){
this.menuTypeEnd = menuTypeEnd;
return this;
}
/**
* 设置 增加 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @param menuTypeIncrement
*/
public MenuQuery menuTypeIncrement(Integer menuTypeIncrement){
this.menuTypeIncrement = menuTypeIncrement;
return this;
}
/**
* 设置 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @param menuTypeList
*/
public MenuQuery menuTypeList(List<Integer> menuTypeList){
this.menuTypeList = menuTypeList;
return this;
}
/**
* 设置 菜单类型,0:主菜单,1:非主菜单(功能操作组),默认0
* @param menuTypeNotList
*/
public MenuQuery menuTypeNotList(List<Integer> menuTypeNotList){
this.menuTypeNotList = menuTypeNotList;
return this;
}
/**
* 设置 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @param authType
*/
public MenuQuery authType(Integer authType){
setAuthType(authType);
return this;
}
/**
* 设置 开始 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @param authTypeStart
*/
public MenuQuery authTypeStart(Integer authTypeStart){
this.authTypeStart = authTypeStart;
return this;
}
/**
* 设置 结束 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @param authTypeEnd
*/
public MenuQuery authTypeEnd(Integer authTypeEnd){
this.authTypeEnd = authTypeEnd;
return this;
}
/**
* 设置 增加 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @param authTypeIncrement
*/
public MenuQuery authTypeIncrement(Integer authTypeIncrement){
this.authTypeIncrement = authTypeIncrement;
return this;
}
/**
* 设置 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @param authTypeList
*/
public MenuQuery authTypeList(List<Integer> authTypeList){
this.authTypeList = authTypeList;
return this;
}
/**
* 设置 权限类型,0:无限制,1:无需登录查看,2:需要登录查看,3:需要角色权限查看,默认3
* @param authTypeNotList
*/
public MenuQuery authTypeNotList(List<Integer> authTypeNotList){
this.authTypeNotList = authTypeNotList;
return this;
}
/**
* 设置 创建用户
* @param createUserId
*/
public MenuQuery createUserId(Long createUserId){
setCreateUserId(createUserId);
return this;
}
/**
* 设置 开始 创建用户
* @param createUserIdStart
*/
public MenuQuery createUserIdStart(Long createUserIdStart){
this.createUserIdStart = createUserIdStart;
return this;
}
/**
* 设置 结束 创建用户
* @param createUserIdEnd
*/
public MenuQuery createUserIdEnd(Long createUserIdEnd){
this.createUserIdEnd = createUserIdEnd;
return this;
}
/**
* 设置 增加 创建用户
* @param createUserIdIncrement
*/
public MenuQuery createUserIdIncrement(Long createUserIdIncrement){
this.createUserIdIncrement = createUserIdIncrement;
return this;
}
/**
* 设置 创建用户
* @param createUserIdList
*/
public MenuQuery createUserIdList(List<Long> createUserIdList){
this.createUserIdList = createUserIdList;
return this;
}
/**
* 设置 创建用户
* @param createUserIdNotList
*/
public MenuQuery createUserIdNotList(List<Long> createUserIdNotList){
this.createUserIdNotList = createUserIdNotList;
return this;
}
/**
* 设置 创建用户名称
* @param createUserName
*/
public MenuQuery createUserName(String createUserName){
setCreateUserName(createUserName);
return this;
}
/**
* 设置 创建用户名称
* @param createUserNameList
*/
public MenuQuery createUserNameList(List<String> createUserNameList){
this.createUserNameList = createUserNameList;
return this;
}
/**
* 获取 OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4)
* @return orConditionList
*/
public List<MenuQuery> getOrConditionList(){
return this.orConditionList;
}
/**
* 设置 OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4)
* @param orConditionList
*/
public void setOrConditionList(List<MenuQuery> orConditionList){
this.orConditionList = orConditionList;
}
/**
* 获取 AND条件集合,列表项之间是AND,项内容之间是OR,如:(list[0].1 or list[0].2) and (list[1].3 or list[1].4)
* @return andConditionList
*/
public List<MenuQuery> getAndConditionList(){
return this.andConditionList;
}
/**
* 设置 AND条件集合,列表项之间是AND,项内容之间是OR,如:(list[0].1 or list[0].2) and (list[1].3 or list[1].4)
* @param andConditionList
*/
public void setAndConditionList(List<MenuQuery> andConditionList){
this.andConditionList = andConditionList;
}
}
\ No newline at end of file
package com.mortals.xhx.base.system.menu.model;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.Data;
import java.io.Serializable;
import java.util.stream.Collectors;
/**
* 菜单信息前端映射树结构实体类
*
* @author zxfei
* @date 2023-04-10
*/
@Data
public class MenuTreeSelect implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 节点ID
*/
private Long id;
/**
* 节点名称
*/
private String label;
/**
* 子节点
*/
@JsonInclude(JsonInclude.Include.NON_EMPTY)
private List<MenuTreeSelect> children;
public MenuTreeSelect(MenuEntity entity) {
this.id = entity.getId();
this.label = entity.getName();
this.children = entity.getChildList().stream().map(MenuTreeSelect::new).collect(Collectors.toList());
}
}
\ No newline at end of file
package com.mortals.xhx.base.system.menu.model.vo;
import com.mortals.framework.model.BaseEntityLong;
import com.mortals.xhx.base.system.menu.model.MenuEntity;
import java.util.ArrayList;
import java.util.List;
import lombok.Data;
/**
* 菜单信息视图对象
*
* @author zxfei
* @date 2023-04-10
*/
@Data
public class MenuVo extends BaseEntityLong {
/** 子菜单信息 */
private List<MenuEntity> childList = new ArrayList<>();
private Integer type;
}
\ No newline at end of file
/**
* 文件:MenuService.java
* 版本:1.0.0
* 日期:
* Copyright &reg;
* All right reserved.
*/
package com.mortals.xhx.base.system.menu.service;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.service.ICRUDService;
import com.mortals.framework.service.IUser;
import com.mortals.xhx.base.system.menu.model.MenuEntity;
import com.mortals.xhx.base.system.menu.model.MenuTreeSelect;
import java.util.List;
import java.util.Set;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.model.Context;
/**
* <p>Title: 菜单信息</p>
* <p>Description: MenuService service接口 </p>
* <p>Copyright: Copyright &reg; </p>
* <p>Company: </p>
* @author
* @version 1.0.0
* MenuService
* <p>
* 菜单信息 service接口
*
* @author zxfei
* @date 2023-04-10
*/
public interface MenuService extends ICRUDService<MenuEntity, Long> {
public interface MenuService extends ICRUDService<MenuEntity,Long> {
/**
* 获取所有可用菜单
*
......@@ -56,8 +50,47 @@ public interface MenuService extends ICRUDService<MenuEntity,Long> {
/**
* 更新排列顺序
*
* @param id
* @param type
*/
void upOrDown(Long id, Integer type);
/**
* 是否存在菜单信息节点
*
* @param menuId 菜单信息ID
* @return 结果
*/
boolean hasChildByMenuId(Long menuId);
/**
* 查询菜单信息数据
*
* @param menu 菜单信息
* @return 菜单信息集合
*/
List<MenuEntity> selectMenuList(MenuEntity menu);
/**
* 构建前端所需要下拉树结构
*
* @param menuList 菜单信息列表
* @return 下拉树结构列表
*/
List<MenuTreeSelect> buildMenuTreeSelect(List<MenuEntity> menuList);
/**
* 根据父id查询子节点
*
* @param parentId
* @param context
* @return
*/
List<MenuTreeSelect> getListByParentId(Long parentId, Context context);
Set<Long> getPathSetById(Long id, Context context);
}
\ No newline at end of file
/**
* 文件:MenuServiceImpl.java
* 版本:1.0.0
* 日期:
* Copyright &reg;
* All right reserved.
*/
package com.mortals.xhx.base.system.menu.service.impl;
import com.mortals.framework.common.code.YesNo;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.model.Context;
import com.mortals.framework.model.OrderCol;
import com.mortals.framework.service.IUser;
import com.mortals.framework.service.impl.AbstractCRUDServiceImpl;
import com.mortals.framework.util.StringUtils;
import com.mortals.xhx.common.code.YesNoEnum;
import org.springframework.stereotype.Service;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.model.Context;
import com.mortals.xhx.common.code.SatusEnum;
import com.mortals.framework.service.impl.AbstractCRUDServiceImpl;
import com.mortals.xhx.base.system.menu.dao.MenuDao;
import com.mortals.xhx.base.system.menu.model.MenuEntity;
import com.mortals.xhx.base.system.menu.model.MenuQuery;
import com.mortals.xhx.base.system.menu.service.MenuService;
import com.mortals.xhx.common.code.YesNoEnum;
import org.springframework.stereotype.Service;
import com.mortals.xhx.base.system.menu.model.MenuTreeSelect;
import org.springframework.util.ObjectUtils;
import java.util.*;
import java.util.stream.Collectors;
/**
* <p>Title: 菜单信息</p>
* <p>Description: MenuServiceImpl service接口 </p>
* <p>Copyright: Copyright &reg; </p>
* <p>Company: </p>
*
* @author
* @version 1.0.0
*/
* MenuService
* 菜单信息 service实现
*
* @author zxfei
* @date 2023-04-10
*/
@Service("menuService")
public class MenuServiceImpl extends AbstractCRUDServiceImpl<MenuDao, MenuEntity, Long> implements MenuService {
......@@ -168,16 +157,203 @@ public class MenuServiceImpl extends AbstractCRUDServiceImpl<MenuDao, MenuEntity
}
@Override
protected void saveBefore(MenuEntity entity, Context context) throws AppException {
MenuQuery query = new MenuQuery();
query.setParentId(entity.getParentId());
Comparator<Integer> comparator = Comparator.comparing(Integer::intValue);
Optional<Integer> maxOptional = this.find(query).stream().map(MenuEntity::getOrderId).filter(f->f!=9999).max(comparator);
Optional<Integer> maxOptional = this.find(query).stream().map(item->{
if(ObjectUtils.isEmpty(item.getOrderId())) return 1;
return item.getOrderId();
}).filter(f->f!=9999).max(comparator);
maxOptional.ifPresent(e -> {
e=e+1;
entity.setOrderId(e);
});
MenuEntity parentMenuEntity = this.get(entity.getParentId());
if (!ObjectUtils.isEmpty(parentMenuEntity) && SatusEnum.DISENABLE.getValue() == parentMenuEntity.getStatus()) {
throw new AppException("菜单信息停用,不允许新增");
}
if (!ObjectUtils.isEmpty(parentMenuEntity)) {
entity.setAncestors(parentMenuEntity.getAncestors() + "," + entity.getParentId());
}
super.saveBefore(entity, context);
}
@Override
protected void updateBefore(MenuEntity entity, Context context) throws AppException {
MenuEntity newParentEntity = this.get(entity.getParentId());
MenuEntity oldEntity = this.get(entity.getId());
if (!ObjectUtils.isEmpty(newParentEntity) && !ObjectUtils.isEmpty(oldEntity)) {
String newAncestors = newParentEntity.getAncestors() + "," + newParentEntity.getId();
String oldAncestors = oldEntity.getAncestors();
entity.setAncestors(newAncestors);
updateMenuChildren(entity.getId(), newAncestors, oldAncestors, context);
}
super.updateBefore(entity, context);
}
@Override
protected void updateAfter(MenuEntity entity, Context context) throws AppException {
if (SatusEnum.ENABLE.getValue() == entity.getStatus()) {
entity= this.get(entity.getId());
updateParentMenuStatus(entity, context);
}
super.updateAfter(entity, context);
}
/**
* 修改该菜单信息的父级菜单信息状态
*
* @param menu 当前菜单信息
*/
private void updateParentMenuStatus(MenuEntity menu, Context context) {
MenuEntity menuEntity = this.get(menu.getParentId());
if(!ObjectUtils.isEmpty(menuEntity)){
menuEntity.setStatus(SatusEnum.ENABLE.getValue());
menuEntity.setUpdateTime(new Date());
menuEntity.setUpdateUser(context.getUser().getLoginName());
MenuEntity condition = new MenuEntity();
condition.setId(menuEntity.getId());
this.updateBatch(menuEntity, condition, context);
}
}
/**
* 修改子元素关系
*
* @param menuId 被修改的菜单信息ID
* @param newAncestors 新的父ID集合
* @param oldAncestors 旧的父ID集合
*/
public void updateMenuChildren(Long menuId, String newAncestors, String oldAncestors, Context context) {
List<MenuEntity> children = getDao().selectChildrenMenuById(menuId.toString());
for (MenuEntity child : children) {
child.setAncestors(child.getAncestors().replace(oldAncestors, newAncestors));
}
if (children.size() > 0) {
this.updateAfter(children, context);
}
}
@Override
protected void removeBefore(Long[] ids, Context context) throws AppException {
//有子节点 禁止删除
if (hasChildByMenuId(ids[0])) {
throw new AppException("存在下级菜单信息,不允许删除");
}
super.removeBefore(ids, context);
}
@Override
public boolean hasChildByMenuId(Long menuId) {
List<MenuEntity> list = this.find(new MenuQuery().parentId(menuId));
return list.size() > 0 ? true : false;
}
@Override
public List<MenuEntity> selectMenuList(MenuEntity menu) {
return this.find(new MenuQuery());
}
@Override
public List<MenuTreeSelect> buildMenuTreeSelect(List<MenuEntity> list) {
List<MenuEntity> returnList = new ArrayList<>();
List<Long> tempList = list.stream().map(MenuEntity::getId).collect(Collectors.toList());
for (Iterator<MenuEntity> iterator = list.iterator(); iterator.hasNext(); ) {
MenuEntity menuEntity = iterator.next();
if (!tempList.contains(menuEntity.getParentId())) {
recursionFn(list, menuEntity);
returnList.add(menuEntity);
}
}
if (returnList.isEmpty()) {
returnList = list;
}
return returnList.stream().map(MenuTreeSelect::new).collect(Collectors.toList());
}
/**
* 递归列表
*/
private void recursionFn(List<MenuEntity> list, MenuEntity t) {
// 得到子节点列表
List<MenuEntity> childList = getChildList(list, t);
t.setChildList(childList);
for (MenuEntity tChild : childList) {
if (hasChild(list, tChild)) {
recursionFn(list, tChild);
}
}
}
/**
* 判断是否有子节点
*/
private boolean hasChild(List<MenuEntity> list, MenuEntity t) {
return getChildList(list, t).size() > 0 ? true : false;
}
/**
* 得到子节点列表
*/
private List<MenuEntity> getChildList(List<MenuEntity> list, MenuEntity t) {
return list.stream().map(item->{
if (!ObjectUtils.isEmpty(item.getParentId()) && item.getParentId() == t.getId()) {
return item;
}
return null;
}).filter(f->f!=null).collect(Collectors.toList());
}
@Override
public List<MenuTreeSelect> getListByParentId(Long parentId, Context context) {
if (ObjectUtils.isEmpty(parentId)) {
parentId = 0L;
}
//只做一层
List<MenuTreeSelect> collect = this.find(new MenuQuery().parentId(parentId), context).stream().map(item -> new MenuTreeSelect(item)
).collect(Collectors.toList());
if ("0".equals(parentId)) {
return collect;
}
return collect;
}
@Override
public Set<Long> getPathSetById(Long id, Context context) {
Set<Long> idSet = new HashSet<>();
//idSet.add(id);
MenuEntity menuEntity = this.get(id, context);
if(!ObjectUtils.isEmpty(menuEntity)){
return extracted(context, idSet, menuEntity);
}
return idSet;
}
private Set<Long> extracted(Context context, Set<Long> idSet, MenuEntity menuEntity) {
MenuEntity parentMenu = this.get(menuEntity.getParentId(), context);
if(!ObjectUtils.isEmpty(parentMenu)){
idSet.add(parentMenu.getId());
return extracted(context,idSet,parentMenu);
}
return idSet;
}
}
\ No newline at end of file
package com.mortals.xhx.base.system.menu.web;
import com.alibaba.fastjson.JSONObject;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.model.Context;
import com.mortals.framework.model.OrderCol;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.base.system.param.service.ParamService;
import com.mortals.xhx.common.code.*;
import com.mortals.xhx.base.system.menu.model.MenuQuery;
import org.apache.commons.lang3.ObjectUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.*;
import com.mortals.framework.web.BaseCRUDJsonMappingController;
import com.mortals.framework.model.Context;
import com.mortals.xhx.base.system.menu.model.MenuEntity;
import com.mortals.xhx.base.system.menu.service.MenuService;
import com.mortals.xhx.common.code.DataSatus;
import com.mortals.xhx.common.code.MenuAuthType;
import com.mortals.xhx.common.code.MenuComm;
import com.mortals.xhx.common.code.MenuLinkType;
import com.mortals.xhx.common.code.MenuType;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.mortals.xhx.base.system.menu.model.MenuTreeSelect;
import org.apache.commons.lang3.ArrayUtils;
import com.mortals.framework.util.StringUtils;
import java.util.*;
import java.util.stream.Collectors;
import com.alibaba.fastjson.JSONObject;
import static com.mortals.framework.ap.SysConstains.*;
/**
* 菜单信息
*
* @author: zxfei
* @date: 2021/11/30 10:02
*/
*
* 菜单信息
*
* @author zxfei
* @date 2023-04-10
*/
@RestController
@RequestMapping("menu")
public class MenuController extends BaseCRUDJsonBodyMappingController<MenuService, MenuEntity, Long> {
public class MenuController extends BaseCRUDJsonBodyMappingController<MenuService,MenuEntity,Long> {
public MenuController() {
super.setModuleDesc("菜单信息");
}
@Autowired
private ParamService paramService;
@Override
......@@ -65,7 +60,7 @@ public class MenuController extends BaseCRUDJsonBodyMappingController<MenuServic
* 改变状态
*/
@RequestMapping(value = "change/status")
public String changeStatus(@RequestBody MenuEntity query) {
public String changeStatus(@RequestBody com.mortals.xhx.base.system.menu.model.MenuEntity query) {
JSONObject ret = new JSONObject();
Context context = getContext();
try {
......@@ -110,4 +105,88 @@ public class MenuController extends BaseCRUDJsonBodyMappingController<MenuServic
}
return ret.toJSONString();
}
@PostMapping("list/exclude")
public String excludeList(@RequestBody MenuEntity query) {
Map<String, Object> model = new HashMap<>();
JSONObject ret = new JSONObject();
String busiDesc = "查询" + this.getModuleDesc();
int code=VALUE_RESULT_SUCCESS;
try {
//查询所有菜单 排除当前菜单路径
Set<Long> idSet = new HashSet<>();
idSet.add(query.getId());
//Set<Long> idSets = this.service.getPathSetById(query.getId(), getContext());
List<MenuEntity> collect = this.service.find(new MenuQuery()).stream().map(item -> {
if(idSet.contains(item.getId())) return null;
//if(idSets.contains(item.getId())) return null;
//ArrayUtils.contains()
// if(ObjectUtils.isEmpty(item.getAncestors())){
// return null;
// }
// if (item.getId().intValue() == id || ArrayUtils.contains(StringUtils.split(item.getAncestors(), ","), id + "")) {
// return null;
// }
return item;
}).filter(f -> f != null).collect(Collectors.toList());
model.put("data", collect);
recordSysLog(request, busiDesc + " 【成功】");
} catch (Exception e) {
code = VALUE_RESULT_FAILURE;
this.doException(request, busiDesc, model, e);
}
ret.put(KEY_RESULT_DATA, model);
ret.put(KEY_RESULT_CODE, code);
return ret.toJSONString();
}
/**
* 获取站点下拉树列表
*/
@PostMapping("treeselect")
public String treeselect(MenuEntity query) {
Map<String, Object> model = new HashMap<>();
JSONObject ret = new JSONObject();
String busiDesc = "查询" + this.getModuleDesc();
int code=VALUE_RESULT_SUCCESS;
try {
List<MenuEntity> list = this.service.find(new MenuQuery());
List<MenuTreeSelect> treeSelects = this.service.buildMenuTreeSelect(list);
model.put("result", treeSelects);
recordSysLog(request, busiDesc + " 【成功】");
} catch (Exception e) {
code = VALUE_RESULT_FAILURE;
this.doException(request, busiDesc, model, e);
}
ret.put(KEY_RESULT_DATA, model);
ret.put(KEY_RESULT_CODE, code);
return ret.toJSONString();
}
/**
* 根据parentId查询子信息
*/
@GetMapping(value = "getListByParentId")
public String getListByParentId(Long parentId) {
JSONObject ret = new JSONObject();
Map<String, Object> model = new HashMap<>();
String busiDesc = "查询" + this.getModuleDesc()+"子节点";
try {
List<MenuTreeSelect> treeList = this.service.getListByParentId(parentId, getContext());
model.put(RESULT_KEY,treeList);
ret.put(KEY_RESULT_CODE, VALUE_RESULT_SUCCESS);
ret.put(KEY_RESULT_DATA, model);
recordSysLog(request, busiDesc+"【成功】");
} catch (Exception e) {
log.error("根据parentId查询子信息错误", e);
this.doException(request, busiDesc, model, e);
ret.put(KEY_RESULT_CODE, VALUE_RESULT_FAILURE);
ret.put(KEY_RESULT_MSG, e.getMessage());
}
return ret.toJSONString();
}
}
\ No newline at end of file
/**
* 文件:MenuForm.java
* 版本:1.0.0
* 日期:
* Copyright &reg;
* All right reserved.
*/
package com.mortals.xhx.base.system.menu.web;
import com.mortals.framework.web.BaseCRUDFormLong;
import com.mortals.xhx.base.system.menu.model.MenuEntity;
import com.mortals.xhx.base.system.menu.model.MenuQuery;
/**
* <p>Title: 菜单信息</p>
* <p>Description: MenuForm </p>
* <p>Copyright: Copyright &reg; </p>
* <p>Company: </p>
* @author
* @version 1.0.0
*/
public class MenuForm extends BaseCRUDFormLong<MenuEntity> {
private MenuEntity entity = new MenuEntity();
private MenuQuery query = new MenuQuery();
public MenuForm(){
}
@Override
public MenuEntity getEntity() {
return entity;
}
public void setEntity(MenuEntity entity) {
this.entity = entity;
}
@Override
public MenuQuery getQuery() {
return query;
}
public void setQuery(MenuQuery query) {
this.query = query;
}
}
\ No newline at end of file
......@@ -4,24 +4,23 @@ import java.util.LinkedHashMap;
import java.util.Map;
/**
* 项目类型(0.法律法规,1.业务知识,2.行业知识,3.通用知识)枚举类
* 证件类型()枚举类
*
* @author zxfei
*/
public enum ProjectTypeEnum {
法律法规(0, "法律法规"),
业务知识(1, "业务知识"),
行业知识(2, "行业知识"),
通用知识(3, "通用知识");
private Integer value;
public enum IdCardTypeEnum {
身份证("居民身份证", "居民身份证"),
军官证("军官证", "军官证"),
;
private String value;
private String desc;
ProjectTypeEnum(Integer value, String desc) {
IdCardTypeEnum(String value, String desc) {
this.value = value;
this.desc = desc;
}
public Integer getValue() {
public String getValue() {
return this.value;
}
......@@ -29,10 +28,10 @@ public enum ProjectTypeEnum {
return this.desc;
}
public static ProjectTypeEnum getByValue(Integer value) {
for (ProjectTypeEnum projectTypeEnum : ProjectTypeEnum.values()) {
if (projectTypeEnum.getValue() == value) {
return projectTypeEnum;
public static IdCardTypeEnum getByValue(String value) {
for (IdCardTypeEnum processStatusEnum : IdCardTypeEnum.values()) {
if (processStatusEnum.getValue() == value) {
return processStatusEnum;
}
}
return null;
......@@ -44,12 +43,12 @@ public enum ProjectTypeEnum {
* @param eItem 不包含项
* @return
*/
public static Map<String, String> getEnumMap(Integer... eItem) {
public static Map<String, String> getEnumMap(String... eItem) {
Map<String, String> resultMap = new LinkedHashMap<>();
for (ProjectTypeEnum item : ProjectTypeEnum.values()) {
for (IdCardTypeEnum item : IdCardTypeEnum.values()) {
try {
boolean hasE = false;
for (Integer e : eItem) {
for (String e : eItem) {
if (item.getValue() == e) {
hasE = true;
break;
......
package com.mortals.xhx.common.code;
/**
* @author karlhoo
*/
public enum OneThingRespCodeEnum {
/** 接收成功 */
SUCCESS(200, "成功"),
/** 执行失败 */
FAILED(400,"执行失败"),
;
private final Integer value;
private final String label;
OneThingRespCodeEnum(Integer value, String label) {
this.value = value;
this.label = label;
}
public int getValue() {
return this.value;
}
public String getLabel() {
return this.label;
}
}
package com.mortals.xhx.common.code;
import java.util.LinkedHashMap;
import java.util.Map;
/**
* @author: finegirl
* @date: 2021/7/16 11:50
* @description: //TODO 请完善注释信息
**/
public enum OneThingTypeEnum {
UNSUBMIT(1, "资料上传"),
SUBMIT(2, "确认提交");
private int value;
private String desc;
private OneThingTypeEnum(int value, String desc) {
this.value = value;
this.desc = desc;
}
public int getValue() {
return this.value;
}
public String getDesc() {
return this.desc;
}
public static OneThingTypeEnum getByValue(int value) {
OneThingTypeEnum[] var1 = values();
int var2 = var1.length;
for(int var3 = 0; var3 < var2; ++var3) {
OneThingTypeEnum examStatus = var1[var3];
if (examStatus.getValue() == value) {
return examStatus;
}
}
return null;
}
public static Map<String, String> getEnumMap(int... eItem) {
Map<String, String> resultMap = new LinkedHashMap();
OneThingTypeEnum[] var2 = values();
int var3 = var2.length;
for(int var4 = 0; var4 < var3; ++var4) {
OneThingTypeEnum item = var2[var4];
try {
boolean hasE = false;
int[] var7 = eItem;
int var8 = eItem.length;
for(int var9 = 0; var9 < var8; ++var9) {
int e = var7[var9];
if (item.getValue() == e) {
hasE = true;
break;
}
}
if (!hasE) {
resultMap.put(item.getValue() + "", item.getDesc());
}
} catch (Exception var11) {
}
}
return resultMap;
}
}
\ No newline at end of file
package com.mortals.xhx.common.code;
import com.mortals.framework.common.IBaseEnum;
import java.util.LinkedHashMap;
import java.util.Map;
public enum PublishStatusEnum implements IBaseEnum{
PRODUCT_PENDING(0, "待发布"),
PRODUCT_AUDITING(1, "审核中"),
PRODUCT_SUCESS(2, "审核通过"),
PRODUCT_REJECT(3, "审核拒绝");
private int value;
private String desc;
PublishStatusEnum(int value, String desc) {
this.value = value;
this.desc = desc;
}
@Override
public int getValue() {
return this.value;
}
public String getDesc() {
return desc;
}
public static PublishStatusEnum getByValue(int value) {
for (PublishStatusEnum YesNoEnum : PublishStatusEnum.values()) {
if (YesNoEnum.getValue() == value) {
return YesNoEnum;
}
}
return null;
}
/**
* 获取Map集合
* @param eItem 不包含项
* @return
*/
public static Map<String,String> getEnumMap(int... eItem) {
Map<String,String> resultMap= new LinkedHashMap<String,String>();
for (PublishStatusEnum item : PublishStatusEnum.values()) {
try{
boolean hasE = false;
for (int e : eItem){
if(item.getValue()==e){
hasE = true;
break;
}
}
if(!hasE){
resultMap.put(item.getValue()+"", item.getDesc());
}
}catch(Exception ex){
}
}
return resultMap;
}
}
package com.mortals.xhx.common.code;
import com.mortals.framework.common.IBaseEnum;
import java.util.LinkedHashMap;
import java.util.Map;
public enum OneThingStatusEnum implements IBaseEnum{
BOM_EDIT(401, "修订中"),
BOM_AUDIT(402, "审核中"),
BOM_PUBLISH(403, "已发布");
/**
* 状态
* @author
*
*/
public enum SatusEnum {
DISENABLE(0, "禁用"),
ENABLE(1, "启用");
private int value;
private String desc;
OneThingStatusEnum(int value, String desc) {
SatusEnum(int value, String desc) {
this.value = value;
this.desc = desc;
}
@Override
public int getValue() {
return this.value;
}
......@@ -28,10 +30,10 @@ public enum OneThingStatusEnum implements IBaseEnum{
return desc;
}
public static OneThingStatusEnum getByValue(int value) {
for (OneThingStatusEnum YesNoEnum : OneThingStatusEnum.values()) {
if (YesNoEnum.getValue() == value) {
return YesNoEnum;
public static SatusEnum getByValue(int value) {
for (SatusEnum examStatus : SatusEnum.values()) {
if (examStatus.getValue() == value) {
return examStatus;
}
}
return null;
......@@ -42,8 +44,9 @@ public enum OneThingStatusEnum implements IBaseEnum{
* @return
*/
public static Map<String,String> getEnumMap(int... eItem) {
Map<String,String> resultMap= new LinkedHashMap<String,String>();
for (OneThingStatusEnum item : OneThingStatusEnum.values()) {
for (SatusEnum item : SatusEnum.values()) {
try{
boolean hasE = false;
for (int e : eItem){
......@@ -60,5 +63,4 @@ public enum OneThingStatusEnum implements IBaseEnum{
}
return resultMap;
}
}
......@@ -8,11 +8,11 @@ import com.mortals.framework.annotation.Excel;
import com.mortals.framework.model.BaseEntityLong;
import com.mortals.xhx.module.appointment.model.vo.AppointmentConfigTimesVo;
/**
* 预约自动签到配置时间段实体对象
*
* @author zxfei
* @date 2023-04-09
*/
* 预约自动签到配置时间段实体对象
*
* @author zxfei
* @date 2023-04-11
*/
public class AppointmentConfigTimesEntity extends AppointmentConfigTimesVo {
private static final long serialVersionUID = 1L;
......
......@@ -4,26 +4,26 @@ import java.util.Date;
import java.util.List;
import com.mortals.xhx.module.appointment.model.AppointmentConfigTimesEntity;
/**
* 预约自动签到配置时间段查询对象
*
* @author zxfei
* @date 2023-04-09
*/
* 预约自动签到配置时间段查询对象
*
* @author zxfei
* @date 2023-04-11
*/
public class AppointmentConfigTimesQuery extends AppointmentConfigTimesEntity {
/** 开始 序号,主键,自增长 */
private Long IdStart;
private Long idStart;
/** 结束 序号,主键,自增长 */
private Long IdEnd;
private Long idEnd;
/** 增加 序号,主键,自增长 */
private Long IdIncrement;
private Long idIncrement;
/** 序号,主键,自增长列表 */
private List <Long> IdList;
private List <Long> idList;
/** 序号,主键,自增长排除列表 */
private List <Long> IdNotList;
private List <Long> idNotList;
/** 开始 自动签到配置id */
private Long aotoCheckCfgIdStart;
......@@ -109,82 +109,82 @@ public class AppointmentConfigTimesQuery extends AppointmentConfigTimesEntity {
/**
* 获取 开始 序号,主键,自增长
* @return IdStart
* @return idStart
*/
public Long getIdStart(){
return this.IdStart;
return this.idStart;
}
/**
* 设置 开始 序号,主键,自增长
* @param IdStart
* @param idStart
*/
public void setIdStart(Long IdStart){
this.IdStart = IdStart;
public void setIdStart(Long idStart){
this.idStart = idStart;
}
/**
* 获取 结束 序号,主键,自增长
* @return $IdEnd
* @return $idEnd
*/
public Long getIdEnd(){
return this.IdEnd;
return this.idEnd;
}
/**
* 设置 结束 序号,主键,自增长
* @param IdEnd
* @param idEnd
*/
public void setIdEnd(Long IdEnd){
this.IdEnd = IdEnd;
public void setIdEnd(Long idEnd){
this.idEnd = idEnd;
}
/**
* 获取 增加 序号,主键,自增长
* @return IdIncrement
* @return idIncrement
*/
public Long getIdIncrement(){
return this.IdIncrement;
return this.idIncrement;
}
/**
* 设置 增加 序号,主键,自增长
* @param IdIncrement
* @param idIncrement
*/
public void setIdIncrement(Long IdIncrement){
this.IdIncrement = IdIncrement;
public void setIdIncrement(Long idIncrement){
this.idIncrement = idIncrement;
}
/**
* 获取 序号,主键,自增长
* @return IdList
* @return idList
*/
public List<Long> getIdList(){
return this.IdList;
return this.idList;
}
/**
* 设置 序号,主键,自增长
* @param IdList
* @param idList
*/
public void setIdList(List<Long> IdList){
this.IdList = IdList;
public void setIdList(List<Long> idList){
this.idList = idList;
}
/**
* 获取 序号,主键,自增长
* @return IdNotList
* @return idNotList
*/
public List<Long> getIdNotList(){
return this.IdNotList;
return this.idNotList;
}
/**
* 设置 序号,主键,自增长
* @param IdNotList
* @param idNotList
*/
public void setIdNotList(List<Long> IdNotList){
this.IdNotList = IdNotList;
public void setIdNotList(List<Long> idNotList){
this.idNotList = idNotList;
}
......@@ -593,55 +593,55 @@ public class AppointmentConfigTimesQuery extends AppointmentConfigTimesEntity {
/**
* 设置 序号,主键,自增长
* @param Id
* @param id
*/
public AppointmentConfigTimesQuery Id(Long Id){
setId(Id);
public AppointmentConfigTimesQuery id(Long id){
setId(id);
return this;
}
/**
* 设置 开始 序号,主键,自增长
* @param IdStart
* @param idStart
*/
public AppointmentConfigTimesQuery IdStart(Long IdStart){
this.IdStart = IdStart;
public AppointmentConfigTimesQuery idStart(Long idStart){
this.idStart = idStart;
return this;
}
/**
* 设置 结束 序号,主键,自增长
* @param IdEnd
* @param idEnd
*/
public AppointmentConfigTimesQuery IdEnd(Long IdEnd){
this.IdEnd = IdEnd;
public AppointmentConfigTimesQuery idEnd(Long idEnd){
this.idEnd = idEnd;
return this;
}
/**
* 设置 增加 序号,主键,自增长
* @param IdIncrement
* @param idIncrement
*/
public AppointmentConfigTimesQuery IdIncrement(Long IdIncrement){
this.IdIncrement = IdIncrement;
public AppointmentConfigTimesQuery idIncrement(Long idIncrement){
this.idIncrement = idIncrement;
return this;
}
/**
* 设置 序号,主键,自增长
* @param IdList
* @param idList
*/
public AppointmentConfigTimesQuery IdList(List<Long> IdList){
this.IdList = IdList;
public AppointmentConfigTimesQuery idList(List<Long> idList){
this.idList = idList;
return this;
}
/**
* 设置 序号,主键,自增长
* @param IdNotList
* @param idNotList
*/
public AppointmentConfigTimesQuery IdNotList(List<Long> IdNotList){
this.IdNotList = IdNotList;
public AppointmentConfigTimesQuery idNotList(List<Long> idNotList){
this.idNotList = idNotList;
return this;
}
......
......@@ -296,7 +296,7 @@ public class AppointmentConstraintEntity extends AppointmentConstraintVo {
this.contact = "";
this.idCardType = "";
this.idCardType = "居民身份证";
this.idCardNo = "";
......@@ -304,7 +304,7 @@ public class AppointmentConstraintEntity extends AppointmentConstraintVo {
this.constraintTime = null;
this.createMethod = null;
this.createMethod = 1;
this.operator = "";
......
package com.mortals.xhx.module.appointment.service;
import com.mortals.framework.common.Rest;
import com.mortals.framework.model.Context;
import com.mortals.framework.service.ICRUDService;
import com.mortals.xhx.module.appointment.model.AppointmentConstraintEntity;
import com.mortals.xhx.module.appointment.model.AppointmentRecordsEntity;
/**
* AppointmentConstraintService
*
......@@ -11,4 +15,7 @@ import com.mortals.xhx.module.appointment.model.AppointmentConstraintEntity;
*/
public interface AppointmentConstraintService extends ICRUDService<AppointmentConstraintEntity,Long>{
Rest<String> constraintService(AppointmentConstraintEntity appointmentConstraintEntity, Context context);
}
\ No newline at end of file
package com.mortals.xhx.module.appointment.service;
import com.mortals.framework.common.Rest;
import com.mortals.framework.model.Context;
import com.mortals.framework.service.ICRUDService;
import com.mortals.xhx.module.appointment.model.AppointmentRecordsEntity;
import org.springframework.web.bind.annotation.RequestBody;
/**
* AppointmentRecordsService
*
......@@ -11,4 +15,12 @@ import com.mortals.xhx.module.appointment.model.AppointmentRecordsEntity;
*/
public interface AppointmentRecordsService extends ICRUDService<AppointmentRecordsEntity,Long>{
/**
* 停止群众预约推送服务
* @param appointmentRecordsEntity
* @param context
* @return
*/
Rest<String> stopService(AppointmentRecordsEntity appointmentRecordsEntity, Context context);
}
\ No newline at end of file
package com.mortals.xhx.module.appointment.service.impl;
import com.mortals.framework.common.Rest;
import com.mortals.xhx.module.person.model.PersonEntity;
import com.mortals.xhx.module.person.service.PersonService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.mortals.framework.service.impl.AbstractCRUDServiceImpl;
import com.mortals.framework.exception.AppException;
......@@ -6,14 +11,38 @@ import com.mortals.framework.model.Context;
import com.mortals.xhx.module.appointment.dao.AppointmentConstraintDao;
import com.mortals.xhx.module.appointment.model.AppointmentConstraintEntity;
import com.mortals.xhx.module.appointment.service.AppointmentConstraintService;
import org.springframework.util.ObjectUtils;
/**
* AppointmentConstraintService
* 预约自动签到服务约束 service实现
*
* @author zxfei
* @date 2023-04-09
*/
* AppointmentConstraintService
* 预约自动签到服务约束 service实现
*
* @author zxfei
* @date 2023-04-09
*/
@Service("appointmentConstraintService")
public class AppointmentConstraintServiceImpl extends AbstractCRUDServiceImpl<AppointmentConstraintDao, AppointmentConstraintEntity, Long> implements AppointmentConstraintService {
@Autowired
private PersonService personService;
@Override
protected void saveBefore(AppointmentConstraintEntity entity, Context context) throws AppException {
entity.setOperator(context.getUser()==null?"":context.getUser().getRealName());
super.saveBefore(entity, context);
}
@Override
protected void updateBefore(AppointmentConstraintEntity entity, Context context) throws AppException {
entity.setOperator(context.getUser()==null?"":context.getUser().getRealName());
super.updateBefore(entity, context);
}
@Override
public Rest<String> constraintService(AppointmentConstraintEntity appointmentConstraintEntity, Context context) {
//取消或者开启约束服务
return Rest.ok("修改成功");
}
}
\ No newline at end of file
package com.mortals.xhx.module.appointment.service.impl;
import com.mortals.framework.common.Rest;
import org.springframework.stereotype.Service;
import com.mortals.framework.service.impl.AbstractCRUDServiceImpl;
import com.mortals.framework.exception.AppException;
......@@ -16,4 +17,9 @@ import com.mortals.xhx.module.appointment.service.AppointmentRecordsService;
@Service("appointmentRecordsService")
public class AppointmentRecordsServiceImpl extends AbstractCRUDServiceImpl<AppointmentRecordsDao, AppointmentRecordsEntity, Long> implements AppointmentRecordsService {
@Override
public Rest<String> stopService(AppointmentRecordsEntity appointmentRecordsEntity, Context context) {
//todo 停止群众推送服务
return Rest.ok("服务停止成功");
}
}
\ No newline at end of file
package com.mortals.xhx.module.appointment.web;
import com.mortals.framework.common.Rest;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.base.system.param.service.ParamService;
import com.mortals.xhx.common.code.YesNoEnum;
import com.mortals.xhx.module.appointment.model.AppointmentRecordsEntity;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
......@@ -54,4 +58,7 @@ public class AppointmentConfigController extends BaseCRUDJsonBodyMappingControll
}
}
\ No newline at end of file
package com.mortals.xhx.module.appointment.web;
import cn.hutool.core.util.StrUtil;
import com.mortals.framework.common.Rest;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.base.system.param.service.ParamService;
import com.mortals.xhx.base.system.user.model.UserQuery;
import com.mortals.xhx.base.system.user.service.UserService;
import com.mortals.xhx.common.code.IdCardTypeEnum;
import com.mortals.xhx.common.code.YesNoEnum;
import com.mortals.xhx.module.appointment.model.AppointmentRecordsEntity;
import com.mortals.xhx.module.person.model.PersonQuery;
import com.mortals.xhx.module.person.service.PersonService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.*;
import com.mortals.framework.model.Context;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.module.appointment.model.AppointmentConstraintEntity;
import com.mortals.xhx.module.appointment.service.AppointmentConstraintService;
import org.apache.commons.lang3.ArrayUtils;
import com.mortals.framework.util.StringUtils;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
import com.alibaba.fastjson.JSONObject;
import java.util.Arrays;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import static com.mortals.framework.ap.SysConstains.*;
/**
*
* 预约自动签到服务约束
*
* @author zxfei
* @date 2023-04-09
*/
* 预约自动签到服务约束
*
* @author zxfei
* @date 2023-04-09
*/
@RestController
@RequestMapping("appointment/constraint")
public class AppointmentConstraintController extends BaseCRUDJsonBodyMappingController<AppointmentConstraintService,AppointmentConstraintEntity,Long> {
public class AppointmentConstraintController extends BaseCRUDJsonBodyMappingController<AppointmentConstraintService, AppointmentConstraintEntity, Long> {
@Autowired
private ParamService paramService;
@Autowired
private PersonService personService;
@Autowired
private UserService userService;
public AppointmentConstraintController(){
super.setModuleDesc( "预约自动签到服务约束");
public AppointmentConstraintController() {
super.setModuleDesc("预约自动签到服务约束");
}
@Override
protected void init(Map<String, Object> model, Context context) {
this.addDict(model, "createMethod", paramService.getParamBySecondOrganize("AppointmentConstraint","createMethod"));
this.addDict(model, "constraint", paramService.getParamBySecondOrganize("AppointmentConstraint","constraint"));
this.addDict(model, "createMethod", paramService.getParamBySecondOrganize("AppointmentConstraint", "createMethod"));
this.addDict(model, "idCardType", IdCardTypeEnum.getEnumMap());
this.addDict(model, "constraint", paramService.getParamBySecondOrganize("AppointmentConstraint", "constraint"));
Map<String, String> personCollect = personService.find(new PersonQuery()).stream()
.collect(Collectors.toMap(x -> x.getId().toString(), y -> y.getName(), (o, n) -> n));
this.addDict(model, "personId", personCollect);
Map<String, String> collect = userService.find(new UserQuery(), getContext()).stream()
.collect(Collectors.toMap(x -> x.getId().toString(), y -> y.getRealName(), (o, n) -> n));
this.addDict(model, "operator", collect);
this.addDict(model, "createUserId", collect);
super.init(model, context);
}
/**
* 约束开关
*/
@PostMapping(value = "constraint")
public String constraintService(@RequestBody AppointmentConstraintEntity appointmentConstraintEntity) {
JSONObject jsonObject = new JSONObject();
Map<String, Object> model = new HashMap<>();
String busiDesc = this.getModuleDesc() + "停止服务";
try {
Rest<String> rest = this.service.constraintService(appointmentConstraintEntity, getContext());
if (YesNoEnum.YES.getValue() == rest.getCode()) {
recordSysLog(request, busiDesc + " 【成功】");
jsonObject.put(KEY_RESULT_DATA, model);
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_SUCCESS);
jsonObject.put(KEY_RESULT_MSG, rest.getMsg());
} else {
throw new AppException(rest.getMsg());
}
} catch (Exception e) {
log.error(busiDesc, e);
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_FAILURE);
jsonObject.put(KEY_RESULT_MSG, super.convertException(e));
}
return jsonObject.toJSONString();
}
@Override
protected int doListAfter(AppointmentConstraintEntity query, Map<String, Object> model, Context context) throws AppException {
List<AppointmentConstraintEntity> list = (List<AppointmentConstraintEntity>) model.get(KEY_RESULT_DATA);
list.forEach(item -> {
String maskedIdNumber = StrUtil.hide(item.getIdCardNo(), 4, item.getIdCardNo().length() - 4);
item.setIdCardNo(maskedIdNumber);
});
return super.doListAfter(query, model, context);
}
}
\ No newline at end of file
package com.mortals.xhx.module.appointment.web;
import com.mortals.framework.common.Rest;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.base.system.param.service.ParamService;
import com.mortals.xhx.common.code.EnabledEnum;
import com.mortals.xhx.common.code.YesNoEnum;
import com.mortals.xhx.module.device.model.DeviceEntity;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
......@@ -47,4 +52,31 @@ public class AppointmentRecordsController extends BaseCRUDJsonBodyMappingControl
}
/**
* 群众停止服务
*/
@PostMapping(value = "stopService")
public String stopService(@RequestBody AppointmentRecordsEntity appointmentRecordsEntity) {
JSONObject jsonObject = new JSONObject();
Map<String, Object> model = new HashMap<>();
String busiDesc = this.getModuleDesc() + "停止服务";
try {
Rest<String> rest = this.service.stopService(appointmentRecordsEntity, getContext());
if(YesNoEnum.YES.getValue()==rest.getCode()){
recordSysLog(request, busiDesc + " 【成功】");
jsonObject.put(KEY_RESULT_DATA, model);
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_SUCCESS);
jsonObject.put(KEY_RESULT_MSG, rest.getMsg());
}else {
throw new AppException(rest.getMsg());
}
} catch (Exception e) {
log.error(busiDesc, e);
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_FAILURE);
jsonObject.put(KEY_RESULT_MSG, super.convertException(e));
}
return jsonObject.toJSONString();
}
}
\ No newline at end of file
......@@ -370,7 +370,7 @@ public class CareConfigEntity extends CareConfigVo {
this.serviceThreshold = 0L;
this.alertServiceNum = null;
this.alertServiceNum = 0;
this.msgRecipients = "";
......
......@@ -290,11 +290,11 @@ public class CareConstraintEntity extends CareConstraintVo {
this.idCard = "";
this.serviceFrequency = null;
this.serviceFrequency = 0L;
this.trackingTime = null;
this.createWay = null;
this.createWay = 1;
this.operator = "";
......
package com.mortals.xhx.module.care.service;
import com.mortals.framework.common.Rest;
import com.mortals.framework.model.Context;
import com.mortals.framework.service.ICRUDService;
import com.mortals.xhx.module.care.model.CareRecordsEntity;
import org.springframework.web.bind.annotation.RequestBody;
/**
* CareRecordsService
*
......@@ -11,4 +15,9 @@ import com.mortals.xhx.module.care.model.CareRecordsEntity;
*/
public interface CareRecordsService extends ICRUDService<CareRecordsEntity,Long>{
Rest<String> notice(CareRecordsEntity careRecordsEntity, Context context);
Rest<String> toCare(CareRecordsEntity careRecordsEntity, Context context);
}
\ No newline at end of file
......@@ -27,6 +27,19 @@ public class CareConstraintServiceImpl extends AbstractCRUDServiceImpl<CareConst
@Autowired
private CareConstraintTrackService careConstraintTrackService;
@Override
protected void saveBefore(CareConstraintEntity entity, Context context) throws AppException {
entity.setOperator(context.getUser()==null?"":context.getUser().getRealName());
super.saveBefore(entity, context);
}
@Override
protected void updateBefore(CareConstraintEntity entity, Context context) throws AppException {
entity.setOperator(context.getUser()==null?"":context.getUser().getRealName());
super.updateBefore(entity, context);
}
@Override
protected void saveAfter(CareConstraintEntity entity, Context context) throws AppException {
if(!ObjectUtils.isEmpty(entity.getCareConstraintTrackList())){
......
package com.mortals.xhx.module.care.service.impl;
import com.mortals.framework.common.Rest;
import org.springframework.stereotype.Service;
import com.mortals.framework.service.impl.AbstractCRUDServiceImpl;
import com.mortals.framework.exception.AppException;
......@@ -16,4 +17,15 @@ import com.mortals.xhx.module.care.service.CareRecordsService;
@Service("careRecordsService")
public class CareRecordsServiceImpl extends AbstractCRUDServiceImpl<CareRecordsDao, CareRecordsEntity, Long> implements CareRecordsService {
@Override
public Rest<String> notice(CareRecordsEntity careRecordsEntity, Context context) {
//todo 通知负责人
return Rest.ok("通知负责人成功");
}
@Override
public Rest<String> toCare(CareRecordsEntity careRecordsEntity, Context context) {
//todo 短信通知群众
return Rest.ok("通知群众成功");
}
}
\ No newline at end of file
package com.mortals.xhx.module.care.web;
import cn.hutool.core.util.StrUtil;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.base.system.param.service.ParamService;
import com.mortals.xhx.base.system.user.model.UserQuery;
import com.mortals.xhx.base.system.user.service.UserService;
import com.mortals.xhx.common.code.IdCardTypeEnum;
import com.mortals.xhx.module.appointment.model.AppointmentConstraintEntity;
import com.mortals.xhx.module.person.model.PersonQuery;
import com.mortals.xhx.module.person.service.PersonService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
......@@ -35,6 +43,10 @@ public class CareConstraintController extends BaseCRUDJsonBodyMappingController<
@Autowired
private ParamService paramService;
@Autowired
private PersonService personService;
@Autowired
private UserService userService;
public CareConstraintController(){
super.setModuleDesc( "主动关怀服务约束");
......@@ -44,8 +56,29 @@ public class CareConstraintController extends BaseCRUDJsonBodyMappingController<
protected void init(Map<String, Object> model, Context context) {
this.addDict(model, "createWay", paramService.getParamBySecondOrganize("CareConstraint","createWay"));
this.addDict(model, "track", paramService.getParamBySecondOrganize("CareConstraint","track"));
this.addDict(model, "idCardType", IdCardTypeEnum.getEnumMap());
Map<String, String> personCollect = personService.find(new PersonQuery()).stream()
.collect(Collectors.toMap(x -> x.getId().toString(), y -> y.getName(), (o, n) -> n));
this.addDict(model, "personId", personCollect);
Map<String, String> collect = userService.find(new UserQuery(), getContext()).stream()
.collect(Collectors.toMap(x -> x.getId().toString(), y -> y.getRealName(), (o, n) -> n));
this.addDict(model, "operator", collect);
this.addDict(model, "createUserId", collect);
super.init(model, context);
}
@Override
protected int doListAfter(CareConstraintEntity query, Map<String, Object> model, Context context) throws AppException {
List<CareConstraintEntity> list = (List<CareConstraintEntity>) model.get(KEY_RESULT_DATA);
list.forEach(item -> {
String maskedIdNumber = StrUtil.hide(item.getIdCard(), 4, item.getIdCard().length() - 4);
item.setIdCard(maskedIdNumber);
});
return super.doListAfter(query, model, context);
}
}
\ No newline at end of file
package com.mortals.xhx.module.care.web;
import com.mortals.framework.common.Rest;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.base.system.param.service.ParamService;
import com.mortals.xhx.common.code.YesNoEnum;
import com.mortals.xhx.module.appointment.model.AppointmentRecordsEntity;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
......@@ -47,4 +51,59 @@ public class CareRecordsController extends BaseCRUDJsonBodyMappingController<Car
}
/**
* 通知负责人
*/
@PostMapping(value = "notice")
public String notice(@RequestBody CareRecordsEntity careRecordsEntity) {
JSONObject jsonObject = new JSONObject();
Map<String, Object> model = new HashMap<>();
String busiDesc = this.getModuleDesc() + "通知负责人";
try {
Rest<String> rest = this.service.notice(careRecordsEntity, getContext());
if(YesNoEnum.YES.getValue()==rest.getCode()){
recordSysLog(request, busiDesc + " 【成功】");
jsonObject.put(KEY_RESULT_DATA, model);
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_SUCCESS);
jsonObject.put(KEY_RESULT_MSG, rest.getMsg());
}else {
throw new AppException(rest.getMsg());
}
} catch (Exception e) {
log.error(busiDesc, e);
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_FAILURE);
jsonObject.put(KEY_RESULT_MSG, super.convertException(e));
}
return jsonObject.toJSONString();
}
/**
* 手动关怀
*/
@PostMapping(value = "toCare")
public String toCare(@RequestBody CareRecordsEntity careRecordsEntity) {
JSONObject jsonObject = new JSONObject();
Map<String, Object> model = new HashMap<>();
String busiDesc = this.getModuleDesc() + "toCare";
try {
Rest<String> rest = this.service.notice(careRecordsEntity, getContext());
if(YesNoEnum.YES.getValue()==rest.getCode()){
recordSysLog(request, busiDesc + " 【成功】");
jsonObject.put(KEY_RESULT_DATA, model);
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_SUCCESS);
jsonObject.put(KEY_RESULT_MSG, rest.getMsg());
}else {
throw new AppException(rest.getMsg());
}
} catch (Exception e) {
log.error(busiDesc, e);
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_FAILURE);
jsonObject.put(KEY_RESULT_MSG, super.convertException(e));
}
return jsonObject.toJSONString();
}
}
\ No newline at end of file
package com.mortals.xhx.module.person.service;
import com.mortals.framework.service.ICRUDCacheService;
import com.mortals.framework.service.ICRUDService;
import com.mortals.xhx.module.person.model.PersonEntity;
/**
......@@ -9,6 +10,6 @@ import com.mortals.xhx.module.person.model.PersonEntity;
* @author zxfei
* @date 2023-04-09
*/
public interface PersonService extends ICRUDService<PersonEntity,Long>{
public interface PersonService extends ICRUDCacheService<PersonEntity,Long>{
}
\ No newline at end of file
package com.mortals.xhx.module.person.service.impl;
import com.mortals.framework.service.impl.AbstractCRUDCacheServiceImpl;
import org.springframework.stereotype.Service;
import com.mortals.framework.service.impl.AbstractCRUDServiceImpl;
import com.mortals.framework.exception.AppException;
......@@ -14,6 +15,10 @@ import com.mortals.xhx.module.person.service.PersonService;
* @date 2023-04-09
*/
@Service("personService")
public class PersonServiceImpl extends AbstractCRUDServiceImpl<PersonDao, PersonEntity, Long> implements PersonService {
public class PersonServiceImpl extends AbstractCRUDCacheServiceImpl<PersonDao, PersonEntity, Long> implements PersonService {
@Override
protected String getExtKey(PersonEntity data) {
return data.getIdCard();
}
}
\ No newline at end of file
......@@ -17,8 +17,8 @@ spring:
serialization:
WRITE_DATES_AS_TIMESTAMPS: true
default-property-inclusion: NON_NULL
# time-zone: GMT+8
# date-format: yyyy-MM-dd HH:mm:ss
time-zone: GMT+8
date-format: yyyy-MM-dd HH:mm:ss
dao:
exceptiontranslation:
enabled: false
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"mybatis-3-mapper.dtd">
"mybatis-3-mapper.dtd">
<mapper namespace="com.mortals.xhx.base.system.menu.dao.ibatis.MenuDaoImpl">
<!-- 字段和属性映射 -->
<resultMap type="MenuEntity" id="MenuEntity-Map">
<result property="id" column="id" />
<id property="id" column="id" />
<result property="name" column="name" />
<result property="url" column="url" />
<result property="ancestors" column="ancestors" />
<result property="parentId" column="parentId" />
<result property="orderId" column="orderId" />
<result property="status" column="status" />
......@@ -23,97 +24,91 @@
<result property="createTime" column="createTime" />
<result property="createUserId" column="createUserId" />
<result property="createUserName" column="createUserName" />
</resultMap>
</resultMap>
<!-- 表所有列 -->
<sql id="_columns">
<trim suffixOverrides="," suffix="">
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('id') or colPickMode == 1 and data.containsKey('id')))">
a.id as id,
a.id,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('name') or colPickMode == 1 and data.containsKey('name')))">
a.name as name,
a.name,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('url') or colPickMode == 1 and data.containsKey('url')))">
a.url as url,
a.url,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('ancestors') or colPickMode == 1 and data.containsKey('ancestors')))">
a.ancestors,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('parentId') or colPickMode == 1 and data.containsKey('parentId')))">
a.parentId as parentId,
a.parentId,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('orderId') or colPickMode == 1 and data.containsKey('orderId')))">
a.orderId as orderId,
a.orderId,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('status') or colPickMode == 1 and data.containsKey('status')))">
a.status as status,
a.status,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('linkType') or colPickMode == 1 and data.containsKey('linkType')))">
a.linkType as linkType,
a.linkType,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('groupId') or colPickMode == 1 and data.containsKey('groupId')))">
a.groupId as groupId,
a.groupId,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('groupName') or colPickMode == 1 and data.containsKey('groupName')))">
a.groupName as groupName,
a.groupName,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('imgPath') or colPickMode == 1 and data.containsKey('imgPath')))">
a.imgPath as imgPath,
a.imgPath,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('buttonImgPath') or colPickMode == 1 and data.containsKey('buttonImgPath')))">
a.buttonImgPath as buttonImgPath,
a.buttonImgPath,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('imgCommPath') or colPickMode == 1 and data.containsKey('imgCommPath')))">
a.imgCommPath as imgCommPath,
a.imgCommPath,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('commMenu') or colPickMode == 1 and data.containsKey('commMenu')))">
a.commMenu as commMenu,
a.commMenu,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('menuType') or colPickMode == 1 and data.containsKey('menuType')))">
a.menuType as menuType,
a.menuType,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('authType') or colPickMode == 1 and data.containsKey('authType')))">
a.authType as authType,
a.authType,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('createTime') or colPickMode == 1 and data.containsKey('createTime')))">
a.createTime as createTime,
a.createTime,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('createUserId') or colPickMode == 1 and data.containsKey('createUserId')))">
a.createUserId as createUserId,
a.createUserId,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('createUserName') or colPickMode == 1 and data.containsKey('createUserName')))">
a.createUserName as createUserName,
a.createUserName,
</if>
</trim>
</sql>
<!-- 新增 -->
<!-- 新增 区分主键自增加还是业务插入 -->
<insert id="insert" parameterType="MenuEntity" useGeneratedKeys="true" keyProperty="id">
insert into mortals_xhx_menu
(name,url,parentId,orderId,status,
linkType,groupId,groupName,imgPath,buttonImgPath,
imgCommPath,commMenu,menuType,authType,createTime,
createUserId,createUserName
)VALUES(#{name},#{url},#{parentId},#{orderId},#{status},
#{linkType},#{groupId},#{groupName},#{imgPath},#{buttonImgPath},
#{imgCommPath},#{commMenu},#{menuType},#{authType},#{createTime},
#{createUserId},#{createUserName})
(name,url,ancestors,parentId,orderId,status,linkType,groupId,groupName,imgPath,buttonImgPath,imgCommPath,commMenu,menuType,authType,createTime,createUserId,createUserName)
VALUES
(#{name},#{url},#{ancestors},#{parentId},#{orderId},#{status},#{linkType},#{groupId},#{groupName},#{imgPath},#{buttonImgPath},#{imgCommPath},#{commMenu},#{menuType},#{authType},#{createTime},#{createUserId},#{createUserName})
</insert>
<!-- 批量新增 -->
<insert id="insertBatch" parameterType="paramDto">
insert into mortals_xhx_menu
(name,url,parentId,orderId,status,
linkType,groupId,groupName,imgPath,buttonImgPath,
imgCommPath,commMenu,menuType,authType,createTime,
createUserId,createUserName
)
(name,url,ancestors,parentId,orderId,status,linkType,groupId,groupName,imgPath,buttonImgPath,imgCommPath,commMenu,menuType,authType,createTime,createUserId,createUserName)
VALUES
<foreach collection="data.dataList" item="item" index="index" separator="," >
(#{item.name},#{item.url},#{item.parentId},#{item.orderId},#{item.status},
#{item.linkType},#{item.groupId},#{item.groupName},#{item.imgPath},#{item.buttonImgPath},
#{item.imgCommPath},#{item.commMenu},#{item.menuType},#{item.authType},#{item.createTime},
#{item.createUserId},#{item.createUserName})
(#{item.name},#{item.url},#{item.ancestors},#{item.parentId},#{item.orderId},#{item.status},#{item.linkType},#{item.groupId},#{item.groupName},#{item.imgPath},#{item.buttonImgPath},#{item.imgCommPath},#{item.commMenu},#{item.menuType},#{item.authType},#{item.createTime},#{item.createUserId},#{item.createUserName})
</foreach>
</insert>
<!-- 根据ParamDto更新 -->
<update id="update" parameterType="paramDto">
update mortals_xhx_menu as a
......@@ -125,6 +120,9 @@
<if test="(colPickMode==0 and data.containsKey('url')) or (colPickMode==1 and !data.containsKey('url'))">
a.url=#{data.url},
</if>
<if test="(colPickMode==0 and data.containsKey('ancestors')) or (colPickMode==1 and !data.containsKey('ancestors'))">
a.ancestors=#{data.ancestors},
</if>
<if test="(colPickMode==0 and data.containsKey('parentId')) or (colPickMode==1 and !data.containsKey('parentId'))">
a.parentId=#{data.parentId},
</if>
......@@ -205,7 +203,187 @@
</trim>
</trim>
</update>
<!-- 批量更新 -->
<update id="updateBatch" parameterType="paramDto">
update mortals_xhx_menu as a
<trim prefix="set" suffixOverrides=",">
<trim prefix="name=(case" suffix="ELSE name end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('name')) or (colPickMode==1 and !item.containsKey('name'))">
when a.id=#{item.id} then #{item.name}
</if>
</foreach>
</trim>
<trim prefix="url=(case" suffix="ELSE url end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('url')) or (colPickMode==1 and !item.containsKey('url'))">
when a.id=#{item.id} then #{item.url}
</if>
</foreach>
</trim>
<trim prefix="ancestors=(case" suffix="ELSE ancestors end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('ancestors')) or (colPickMode==1 and !item.containsKey('ancestors'))">
when a.id=#{item.id} then #{item.ancestors}
</if>
</foreach>
</trim>
<trim prefix="parentId=(case" suffix="ELSE parentId end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('parentId')) or (colPickMode==1 and !item.containsKey('parentId'))">
when a.id=#{item.id} then #{item.parentId}
</when>
<when test="(colPickMode==0 and item.containsKey('parentIdIncrement')) or (colPickMode==1 and !item.containsKey('parentIdIncrement'))">
when a.id=#{item.id} then ifnull(a.parentId,0) + #{item.parentIdIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="orderId=(case" suffix="ELSE orderId end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('orderId')) or (colPickMode==1 and !item.containsKey('orderId'))">
when a.id=#{item.id} then #{item.orderId}
</when>
<when test="(colPickMode==0 and item.containsKey('orderIdIncrement')) or (colPickMode==1 and !item.containsKey('orderIdIncrement'))">
when a.id=#{item.id} then ifnull(a.orderId,0) + #{item.orderIdIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="status=(case" suffix="ELSE status end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('status')) or (colPickMode==1 and !item.containsKey('status'))">
when a.id=#{item.id} then #{item.status}
</when>
<when test="(colPickMode==0 and item.containsKey('statusIncrement')) or (colPickMode==1 and !item.containsKey('statusIncrement'))">
when a.id=#{item.id} then ifnull(a.status,0) + #{item.statusIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="linkType=(case" suffix="ELSE linkType end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('linkType')) or (colPickMode==1 and !item.containsKey('linkType'))">
when a.id=#{item.id} then #{item.linkType}
</when>
<when test="(colPickMode==0 and item.containsKey('linkTypeIncrement')) or (colPickMode==1 and !item.containsKey('linkTypeIncrement'))">
when a.id=#{item.id} then ifnull(a.linkType,0) + #{item.linkTypeIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="groupId=(case" suffix="ELSE groupId end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('groupId')) or (colPickMode==1 and !item.containsKey('groupId'))">
when a.id=#{item.id} then #{item.groupId}
</when>
<when test="(colPickMode==0 and item.containsKey('groupIdIncrement')) or (colPickMode==1 and !item.containsKey('groupIdIncrement'))">
when a.id=#{item.id} then ifnull(a.groupId,0) + #{item.groupIdIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="groupName=(case" suffix="ELSE groupName end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('groupName')) or (colPickMode==1 and !item.containsKey('groupName'))">
when a.id=#{item.id} then #{item.groupName}
</if>
</foreach>
</trim>
<trim prefix="imgPath=(case" suffix="ELSE imgPath end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('imgPath')) or (colPickMode==1 and !item.containsKey('imgPath'))">
when a.id=#{item.id} then #{item.imgPath}
</if>
</foreach>
</trim>
<trim prefix="buttonImgPath=(case" suffix="ELSE buttonImgPath end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('buttonImgPath')) or (colPickMode==1 and !item.containsKey('buttonImgPath'))">
when a.id=#{item.id} then #{item.buttonImgPath}
</if>
</foreach>
</trim>
<trim prefix="imgCommPath=(case" suffix="ELSE imgCommPath end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('imgCommPath')) or (colPickMode==1 and !item.containsKey('imgCommPath'))">
when a.id=#{item.id} then #{item.imgCommPath}
</if>
</foreach>
</trim>
<trim prefix="commMenu=(case" suffix="ELSE commMenu end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('commMenu')) or (colPickMode==1 and !item.containsKey('commMenu'))">
when a.id=#{item.id} then #{item.commMenu}
</when>
<when test="(colPickMode==0 and item.containsKey('commMenuIncrement')) or (colPickMode==1 and !item.containsKey('commMenuIncrement'))">
when a.id=#{item.id} then ifnull(a.commMenu,0) + #{item.commMenuIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="menuType=(case" suffix="ELSE menuType end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('menuType')) or (colPickMode==1 and !item.containsKey('menuType'))">
when a.id=#{item.id} then #{item.menuType}
</when>
<when test="(colPickMode==0 and item.containsKey('menuTypeIncrement')) or (colPickMode==1 and !item.containsKey('menuTypeIncrement'))">
when a.id=#{item.id} then ifnull(a.menuType,0) + #{item.menuTypeIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="authType=(case" suffix="ELSE authType end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('authType')) or (colPickMode==1 and !item.containsKey('authType'))">
when a.id=#{item.id} then #{item.authType}
</when>
<when test="(colPickMode==0 and item.containsKey('authTypeIncrement')) or (colPickMode==1 and !item.containsKey('authTypeIncrement'))">
when a.id=#{item.id} then ifnull(a.authType,0) + #{item.authTypeIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="createTime=(case" suffix="ELSE createTime end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('createTime')) or (colPickMode==1 and !item.containsKey('createTime'))">
when a.id=#{item.id} then #{item.createTime}
</if>
</foreach>
</trim>
<trim prefix="createUserId=(case" suffix="ELSE createUserId end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('createUserId')) or (colPickMode==1 and !item.containsKey('createUserId'))">
when a.id=#{item.id} then #{item.createUserId}
</when>
<when test="(colPickMode==0 and item.containsKey('createUserIdIncrement')) or (colPickMode==1 and !item.containsKey('createUserIdIncrement'))">
when a.id=#{item.id} then ifnull(a.createUserId,0) + #{item.createUserIdIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="createUserName=(case" suffix="ELSE createUserName end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('createUserName')) or (colPickMode==1 and !item.containsKey('createUserName'))">
when a.id=#{item.id} then #{item.createUserName}
</if>
</foreach>
</trim>
</trim>
where id in
<foreach collection="data.dataList" item="item" index="index" open="(" separator="," close=")">
#{item.id}
</foreach>
</update>
<!-- 根据主健查询 -->
<select id="getByKey" parameterType="paramDto" resultMap="MenuEntity-Map">
select <include refid="_columns"/>
......@@ -223,6 +401,21 @@
#{item}
</foreach>
</delete>
<!-- 根据主健列表删除一批,针对单一主健有效 -->
<delete id="deleteByKeyList">
delete from mortals_xhx_menu where id in
<foreach collection="list" item="item" index="index" open="(" separator="," close=")">
#{item}
</foreach>
</delete>
<!-- 根据对象列表删除一批,针对单一主健有效 -->
<delete id="deleteByEntityList">
delete from mortals_xhx_menu where id in
<foreach collection="list" item="item" index="index" open="(" separator="," close=")">
#{item.id}
</foreach>
</delete>
<!-- 根据paramDto删除一批 -->
<delete id="deleteByMap" parameterType="paramDto">
delete a.* from mortals_xhx_menu as a
......@@ -245,6 +438,13 @@
</trim>
<include refid="_orderCols_"/>
</select>
<!-- 获取子节点 -->
<select id="selectChildrenMenuById" parameterType="String" resultMap="MenuEntity-Map">
select * from mortals_xhx_menu as a where find_in_set(#{menuId}, ancestors)
</select>
<!-- 获取 -->
<select id="getListCount" parameterType="paramDto" resultType="int">
select count(1)
......@@ -256,327 +456,500 @@
</trim>
</trim>
</select>
<!-- 条件映射 -->
<sql id="_condition_">
<if test="condition != null and !condition.isEmpty()">
<if test="condition.containsKey('id')">
<if test="condition.id != null">
and a.id=#{condition.id}
<!-- 条件映射-普通条件 -->
<include refid="_condition_param_">
<property name="_conditionParam_" value="condition"/>
<property name="_conditionType_" value="and"/>
</include>
<!-- 条件映射-集合之间使用AND,集合中元素使用OR-(list[0].1 or list[0].2) and (list[1].3 or list[1].4) -->
<if test="condition.containsKey('andConditionList') and !condition.andConditionList.isEmpty()">
and
<foreach collection="condition.andConditionList" open="(" close=")" index="index" item="andCondition" separator=" and ">
<trim prefixOverrides="or" prefix="(" suffix=")">
<include refid="_condition_param_">
<property name="_conditionParam_" value="andCondition"/>
<property name="_conditionType_" value="or"/>
</include>
</trim>
</foreach>
</if>
<!-- 条件映射-集合之间使用OR,集合中元素使用AND-(list[0].1 and list[0].2) or (list[1].3 and list[1].4) -->
<if test="condition.containsKey('orConditionList') and !condition.orConditionList.isEmpty()">
and
<foreach collection="condition.orConditionList" open="(" close=")" index="index" item="orCondition" separator=" or ">
<trim prefixOverrides="and" prefix="(" suffix=")">
<include refid="_condition_param_">
<property name="_conditionParam_" value="orCondition"/>
<property name="_conditionType_" value="and"/>
</include>
</trim>
</foreach>
</if>
</if>
</sql>
<!-- 条件映射-代参数 -->
<sql id="_condition_param_">
<bind name="conditionParamRef" value="${_conditionParam_}"/>
<if test="conditionParamRef.containsKey('id')">
<if test="conditionParamRef.id != null">
${_conditionType_} a.id=#{${_conditionParam_}.id}
</if>
</if>
<if test="condition.containsKey('id')">
<if test="condition.id != null ">
and a.id = #{condition.id}
<if test="conditionParamRef.containsKey('id')">
<if test="conditionParamRef.id != null ">
${_conditionType_} a.id = #{${_conditionParam_}.id}
</if>
<if test="condition.id == null">
and a.id is null
<if test="conditionParamRef.id == null">
${_conditionType_} a.id is null
</if>
</if>
<if test="condition.containsKey('idList')">
and a.id in
<foreach collection="condition.idList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('idList') and conditionParamRef.idList.size() > 0">
${_conditionType_} a.id in
<foreach collection="conditionParamRef.idList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('idStart') and condition.idStart != null">
<![CDATA[ and a.id >= #{condition.idStart} ]]>
<if test="conditionParamRef.containsKey('idNotList') and conditionParamRef.idNotList.size() > 0">
${_conditionType_} a.id not in
<foreach collection="conditionParamRef.idNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('idEnd') and condition.idEnd != null">
<![CDATA[ and a.id <= #{condition.idEnd} ]]>
<if test="conditionParamRef.containsKey('idStart') and conditionParamRef.idStart != null">
${_conditionType_} a.id <![CDATA[ >= ]]> #{${_conditionParam_}.idStart}
</if>
<if test="condition.containsKey('name')">
<if test="condition.name != null and condition.name != ''">
and a.name like #{condition.name}
<if test="conditionParamRef.containsKey('idEnd') and conditionParamRef.idEnd != null">
${_conditionType_} a.id <![CDATA[ <= ]]> #{${_conditionParam_}.idEnd}
</if>
<if test="condition.name == null">
and a.name is null
<if test="conditionParamRef.containsKey('name')">
<if test="conditionParamRef.name != null and conditionParamRef.name != ''">
${_conditionType_} a.name like #{${_conditionParam_}.name}
</if>
<if test="conditionParamRef.name == null">
${_conditionType_} a.name is null
</if>
<if test="condition.containsKey('nameList')">
and a.name in
<foreach collection="condition.nameList" open="(" close=")" index="index" item="item" separator=",">
</if>
<if test="conditionParamRef.containsKey('nameList') and conditionParamRef.nameList.size() > 0">
${_conditionType_} a.name in
<foreach collection="conditionParamRef.nameList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('url')">
<if test="condition.url != null and condition.url != ''">
and a.url like #{condition.url}
<if test="conditionParamRef.containsKey('nameNotList') and conditionParamRef.nameNotList.size() > 0">
${_conditionType_} a.name not in
<foreach collection="conditionParamRef.nameNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('url')">
<if test="conditionParamRef.url != null and conditionParamRef.url != ''">
${_conditionType_} a.url like #{${_conditionParam_}.url}
</if>
<if test="condition.url == null">
and a.url is null
<if test="conditionParamRef.url == null">
${_conditionType_} a.url is null
</if>
</if>
<if test="condition.containsKey('urlList')">
and a.url in
<foreach collection="condition.urlList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('urlList') and conditionParamRef.urlList.size() > 0">
${_conditionType_} a.url in
<foreach collection="conditionParamRef.urlList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('parentId')">
<if test="condition.parentId != null ">
and a.parentId = #{condition.parentId}
<if test="conditionParamRef.containsKey('urlNotList') and conditionParamRef.urlNotList.size() > 0">
${_conditionType_} a.url not in
<foreach collection="conditionParamRef.urlNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('ancestors')">
<if test="conditionParamRef.ancestors != null and conditionParamRef.ancestors != ''">
${_conditionType_} a.ancestors like #{${_conditionParam_}.ancestors}
</if>
<if test="condition.parentId == null">
and a.parentId is null
<if test="conditionParamRef.ancestors == null">
${_conditionType_} a.ancestors is null
</if>
</if>
<if test="condition.containsKey('parentIdList')">
and a.parentId in
<foreach collection="condition.parentIdList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('ancestorsList') and conditionParamRef.ancestorsList.size() > 0">
${_conditionType_} a.ancestors in
<foreach collection="conditionParamRef.ancestorsList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('parentIdStart') and condition.parentIdStart != null">
<![CDATA[ and a.parentId >= #{condition.parentIdStart} ]]>
<if test="conditionParamRef.containsKey('ancestorsNotList') and conditionParamRef.ancestorsNotList.size() > 0">
${_conditionType_} a.ancestors not in
<foreach collection="conditionParamRef.ancestorsNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('parentIdEnd') and condition.parentIdEnd != null">
<![CDATA[ and a.parentId <= #{condition.parentIdEnd} ]]>
<if test="conditionParamRef.containsKey('parentId')">
<if test="conditionParamRef.parentId != null ">
${_conditionType_} a.parentId = #{${_conditionParam_}.parentId}
</if>
<if test="condition.containsKey('orderId')">
<if test="condition.orderId != null ">
and a.orderId = #{condition.orderId}
<if test="conditionParamRef.parentId == null">
${_conditionType_} a.parentId is null
</if>
<if test="condition.orderId == null">
and a.orderId is null
</if>
<if test="conditionParamRef.containsKey('parentIdList') and conditionParamRef.parentIdList.size() > 0">
${_conditionType_} a.parentId in
<foreach collection="conditionParamRef.parentIdList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('orderIdList')">
and a.orderId in
<foreach collection="condition.orderIdList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('parentIdNotList') and conditionParamRef.parentIdNotList.size() > 0">
${_conditionType_} a.parentId not in
<foreach collection="conditionParamRef.parentIdNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('orderIdStart') and condition.orderIdStart != null">
<![CDATA[ and a.orderId >= #{condition.orderIdStart} ]]>
<if test="conditionParamRef.containsKey('parentIdStart') and conditionParamRef.parentIdStart != null">
${_conditionType_} a.parentId <![CDATA[ >= ]]> #{${_conditionParam_}.parentIdStart}
</if>
<if test="condition.containsKey('orderIdEnd') and condition.orderIdEnd != null">
<![CDATA[ and a.orderId <= #{condition.orderIdEnd} ]]>
<if test="conditionParamRef.containsKey('parentIdEnd') and conditionParamRef.parentIdEnd != null">
${_conditionType_} a.parentId <![CDATA[ <= ]]> #{${_conditionParam_}.parentIdEnd}
</if>
<if test="condition.containsKey('status')">
<if test="condition.status != null ">
and a.status = #{condition.status}
<if test="conditionParamRef.containsKey('orderId')">
<if test="conditionParamRef.orderId != null ">
${_conditionType_} a.orderId = #{${_conditionParam_}.orderId}
</if>
<if test="condition.status == null">
and a.status is null
<if test="conditionParamRef.orderId == null">
${_conditionType_} a.orderId is null
</if>
</if>
<if test="condition.containsKey('statusList')">
and a.status in
<foreach collection="condition.statusList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('orderIdList') and conditionParamRef.orderIdList.size() > 0">
${_conditionType_} a.orderId in
<foreach collection="conditionParamRef.orderIdList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('orderIdNotList') and conditionParamRef.orderIdNotList.size() > 0">
${_conditionType_} a.orderId not in
<foreach collection="conditionParamRef.orderIdNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('statusStart') and condition.statusStart != null">
<![CDATA[ and a.status >= #{condition.statusStart} ]]>
<if test="conditionParamRef.containsKey('orderIdStart') and conditionParamRef.orderIdStart != null">
${_conditionType_} a.orderId <![CDATA[ >= ]]> #{${_conditionParam_}.orderIdStart}
</if>
<if test="conditionParamRef.containsKey('orderIdEnd') and conditionParamRef.orderIdEnd != null">
${_conditionType_} a.orderId <![CDATA[ <= ]]> #{${_conditionParam_}.orderIdEnd}
</if>
<if test="condition.containsKey('statusEnd') and condition.statusEnd != null">
<![CDATA[ and a.status <= #{condition.statusEnd} ]]>
<if test="conditionParamRef.containsKey('status')">
<if test="conditionParamRef.status != null ">
${_conditionType_} a.status = #{${_conditionParam_}.status}
</if>
<if test="condition.containsKey('linkType')">
<if test="condition.linkType != null ">
and a.linkType = #{condition.linkType}
<if test="conditionParamRef.status == null">
${_conditionType_} a.status is null
</if>
<if test="condition.linkType == null">
and a.linkType is null
</if>
<if test="conditionParamRef.containsKey('statusList') and conditionParamRef.statusList.size() > 0">
${_conditionType_} a.status in
<foreach collection="conditionParamRef.statusList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('linkTypeList')">
and a.linkType in
<foreach collection="condition.linkTypeList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('statusNotList') and conditionParamRef.statusNotList.size() > 0">
${_conditionType_} a.status not in
<foreach collection="conditionParamRef.statusNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('linkTypeStart') and condition.linkTypeStart != null">
<![CDATA[ and a.linkType >= #{condition.linkTypeStart} ]]>
<if test="conditionParamRef.containsKey('statusStart') and conditionParamRef.statusStart != null">
${_conditionType_} a.status <![CDATA[ >= ]]> #{${_conditionParam_}.statusStart}
</if>
<if test="condition.containsKey('linkTypeEnd') and condition.linkTypeEnd != null">
<![CDATA[ and a.linkType <= #{condition.linkTypeEnd} ]]>
<if test="conditionParamRef.containsKey('statusEnd') and conditionParamRef.statusEnd != null">
${_conditionType_} a.status <![CDATA[ <= ]]> #{${_conditionParam_}.statusEnd}
</if>
<if test="condition.containsKey('groupId')">
<if test="condition.groupId != null ">
and a.groupId = #{condition.groupId}
<if test="conditionParamRef.containsKey('linkType')">
<if test="conditionParamRef.linkType != null ">
${_conditionType_} a.linkType = #{${_conditionParam_}.linkType}
</if>
<if test="condition.groupId == null">
and a.groupId is null
<if test="conditionParamRef.linkType == null">
${_conditionType_} a.linkType is null
</if>
</if>
<if test="condition.containsKey('groupIdList')">
and a.groupId in
<foreach collection="condition.groupIdList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('linkTypeList') and conditionParamRef.linkTypeList.size() > 0">
${_conditionType_} a.linkType in
<foreach collection="conditionParamRef.linkTypeList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('groupIdStart') and condition.groupIdStart != null">
<![CDATA[ and a.groupId >= #{condition.groupIdStart} ]]>
<if test="conditionParamRef.containsKey('linkTypeNotList') and conditionParamRef.linkTypeNotList.size() > 0">
${_conditionType_} a.linkType not in
<foreach collection="conditionParamRef.linkTypeNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('linkTypeStart') and conditionParamRef.linkTypeStart != null">
${_conditionType_} a.linkType <![CDATA[ >= ]]> #{${_conditionParam_}.linkTypeStart}
</if>
<if test="condition.containsKey('groupIdEnd') and condition.groupIdEnd != null">
<![CDATA[ and a.groupId <= #{condition.groupIdEnd} ]]>
<if test="conditionParamRef.containsKey('linkTypeEnd') and conditionParamRef.linkTypeEnd != null">
${_conditionType_} a.linkType <![CDATA[ <= ]]> #{${_conditionParam_}.linkTypeEnd}
</if>
<if test="conditionParamRef.containsKey('groupId')">
<if test="conditionParamRef.groupId != null ">
${_conditionType_} a.groupId = #{${_conditionParam_}.groupId}
</if>
<if test="condition.containsKey('groupName')">
<if test="condition.groupName != null and condition.groupName != ''">
and a.groupName like #{condition.groupName}
<if test="conditionParamRef.groupId == null">
${_conditionType_} a.groupId is null
</if>
<if test="condition.groupName == null">
and a.groupName is null
</if>
<if test="conditionParamRef.containsKey('groupIdList') and conditionParamRef.groupIdList.size() > 0">
${_conditionType_} a.groupId in
<foreach collection="conditionParamRef.groupIdList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('groupNameList')">
and a.groupName in
<foreach collection="condition.groupNameList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('groupIdNotList') and conditionParamRef.groupIdNotList.size() > 0">
${_conditionType_} a.groupId not in
<foreach collection="conditionParamRef.groupIdNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('imgPath')">
<if test="condition.imgPath != null and condition.imgPath != ''">
and a.imgPath like #{condition.imgPath}
<if test="conditionParamRef.containsKey('groupIdStart') and conditionParamRef.groupIdStart != null">
${_conditionType_} a.groupId <![CDATA[ >= ]]> #{${_conditionParam_}.groupIdStart}
</if>
<if test="conditionParamRef.containsKey('groupIdEnd') and conditionParamRef.groupIdEnd != null">
${_conditionType_} a.groupId <![CDATA[ <= ]]> #{${_conditionParam_}.groupIdEnd}
</if>
<if test="conditionParamRef.containsKey('groupName')">
<if test="conditionParamRef.groupName != null and conditionParamRef.groupName != ''">
${_conditionType_} a.groupName like #{${_conditionParam_}.groupName}
</if>
<if test="condition.imgPath == null">
and a.imgPath is null
<if test="conditionParamRef.groupName == null">
${_conditionType_} a.groupName is null
</if>
</if>
<if test="condition.containsKey('imgPathList')">
and a.imgPath in
<foreach collection="condition.imgPathList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('groupNameList') and conditionParamRef.groupNameList.size() > 0">
${_conditionType_} a.groupName in
<foreach collection="conditionParamRef.groupNameList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('buttonImgPath')">
<if test="condition.buttonImgPath != null and condition.buttonImgPath != ''">
and a.buttonImgPath like #{condition.buttonImgPath}
<if test="conditionParamRef.containsKey('groupNameNotList') and conditionParamRef.groupNameNotList.size() > 0">
${_conditionType_} a.groupName not in
<foreach collection="conditionParamRef.groupNameNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('imgPath')">
<if test="conditionParamRef.imgPath != null and conditionParamRef.imgPath != ''">
${_conditionType_} a.imgPath like #{${_conditionParam_}.imgPath}
</if>
<if test="conditionParamRef.imgPath == null">
${_conditionType_} a.imgPath is null
</if>
<if test="condition.buttonImgPath == null">
and a.buttonImgPath is null
</if>
<if test="conditionParamRef.containsKey('imgPathList') and conditionParamRef.imgPathList.size() > 0">
${_conditionType_} a.imgPath in
<foreach collection="conditionParamRef.imgPathList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('buttonImgPathList')">
and a.buttonImgPath in
<foreach collection="condition.buttonImgPathList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('imgPathNotList') and conditionParamRef.imgPathNotList.size() > 0">
${_conditionType_} a.imgPath not in
<foreach collection="conditionParamRef.imgPathNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('imgCommPath')">
<if test="condition.imgCommPath != null and condition.imgCommPath != ''">
and a.imgCommPath like #{condition.imgCommPath}
<if test="conditionParamRef.containsKey('buttonImgPath')">
<if test="conditionParamRef.buttonImgPath != null and conditionParamRef.buttonImgPath != ''">
${_conditionType_} a.buttonImgPath like #{${_conditionParam_}.buttonImgPath}
</if>
<if test="condition.imgCommPath == null">
and a.imgCommPath is null
<if test="conditionParamRef.buttonImgPath == null">
${_conditionType_} a.buttonImgPath is null
</if>
</if>
<if test="condition.containsKey('imgCommPathList')">
and a.imgCommPath in
<foreach collection="condition.imgCommPathList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('buttonImgPathList') and conditionParamRef.buttonImgPathList.size() > 0">
${_conditionType_} a.buttonImgPath in
<foreach collection="conditionParamRef.buttonImgPathList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('commMenu')">
<if test="condition.commMenu != null ">
and a.commMenu = #{condition.commMenu}
<if test="conditionParamRef.containsKey('buttonImgPathNotList') and conditionParamRef.buttonImgPathNotList.size() > 0">
${_conditionType_} a.buttonImgPath not in
<foreach collection="conditionParamRef.buttonImgPathNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.commMenu == null">
and a.commMenu is null
<if test="conditionParamRef.containsKey('imgCommPath')">
<if test="conditionParamRef.imgCommPath != null and conditionParamRef.imgCommPath != ''">
${_conditionType_} a.imgCommPath like #{${_conditionParam_}.imgCommPath}
</if>
<if test="conditionParamRef.imgCommPath == null">
${_conditionType_} a.imgCommPath is null
</if>
<if test="condition.containsKey('commMenuList')">
and a.commMenu in
<foreach collection="condition.commMenuList" open="(" close=")" index="index" item="item" separator=",">
</if>
<if test="conditionParamRef.containsKey('imgCommPathList') and conditionParamRef.imgCommPathList.size() > 0">
${_conditionType_} a.imgCommPath in
<foreach collection="conditionParamRef.imgCommPathList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('commMenuStart') and condition.commMenuStart != null">
<![CDATA[ and a.commMenu >= #{condition.commMenuStart} ]]>
<if test="conditionParamRef.containsKey('imgCommPathNotList') and conditionParamRef.imgCommPathNotList.size() > 0">
${_conditionType_} a.imgCommPath not in
<foreach collection="conditionParamRef.imgCommPathNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('commMenuEnd') and condition.commMenuEnd != null">
<![CDATA[ and a.commMenu <= #{condition.commMenuEnd} ]]>
<if test="conditionParamRef.containsKey('commMenu')">
<if test="conditionParamRef.commMenu != null ">
${_conditionType_} a.commMenu = #{${_conditionParam_}.commMenu}
</if>
<if test="condition.containsKey('menuType')">
<if test="condition.menuType != null ">
and a.menuType = #{condition.menuType}
<if test="conditionParamRef.commMenu == null">
${_conditionType_} a.commMenu is null
</if>
<if test="condition.menuType == null">
and a.menuType is null
</if>
<if test="conditionParamRef.containsKey('commMenuList') and conditionParamRef.commMenuList.size() > 0">
${_conditionType_} a.commMenu in
<foreach collection="conditionParamRef.commMenuList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('menuTypeList')">
and a.menuType in
<foreach collection="condition.menuTypeList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('commMenuNotList') and conditionParamRef.commMenuNotList.size() > 0">
${_conditionType_} a.commMenu not in
<foreach collection="conditionParamRef.commMenuNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('menuTypeStart') and condition.menuTypeStart != null">
<![CDATA[ and a.menuType >= #{condition.menuTypeStart} ]]>
<if test="conditionParamRef.containsKey('commMenuStart') and conditionParamRef.commMenuStart != null">
${_conditionType_} a.commMenu <![CDATA[ >= ]]> #{${_conditionParam_}.commMenuStart}
</if>
<if test="condition.containsKey('menuTypeEnd') and condition.menuTypeEnd != null">
<![CDATA[ and a.menuType <= #{condition.menuTypeEnd} ]]>
<if test="conditionParamRef.containsKey('commMenuEnd') and conditionParamRef.commMenuEnd != null">
${_conditionType_} a.commMenu <![CDATA[ <= ]]> #{${_conditionParam_}.commMenuEnd}
</if>
<if test="condition.containsKey('authType')">
<if test="condition.authType != null ">
and a.authType = #{condition.authType}
<if test="conditionParamRef.containsKey('menuType')">
<if test="conditionParamRef.menuType != null ">
${_conditionType_} a.menuType = #{${_conditionParam_}.menuType}
</if>
<if test="conditionParamRef.menuType == null">
${_conditionType_} a.menuType is null
</if>
</if>
<if test="conditionParamRef.containsKey('menuTypeList') and conditionParamRef.menuTypeList.size() > 0">
${_conditionType_} a.menuType in
<foreach collection="conditionParamRef.menuTypeList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('menuTypeNotList') and conditionParamRef.menuTypeNotList.size() > 0">
${_conditionType_} a.menuType not in
<foreach collection="conditionParamRef.menuTypeNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('menuTypeStart') and conditionParamRef.menuTypeStart != null">
${_conditionType_} a.menuType <![CDATA[ >= ]]> #{${_conditionParam_}.menuTypeStart}
</if>
<if test="conditionParamRef.containsKey('menuTypeEnd') and conditionParamRef.menuTypeEnd != null">
${_conditionType_} a.menuType <![CDATA[ <= ]]> #{${_conditionParam_}.menuTypeEnd}
</if>
<if test="condition.authType == null">
and a.authType is null
<if test="conditionParamRef.containsKey('authType')">
<if test="conditionParamRef.authType != null ">
${_conditionType_} a.authType = #{${_conditionParam_}.authType}
</if>
<if test="conditionParamRef.authType == null">
${_conditionType_} a.authType is null
</if>
</if>
<if test="condition.containsKey('authTypeList')">
and a.authType in
<foreach collection="condition.authTypeList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('authTypeList') and conditionParamRef.authTypeList.size() > 0">
${_conditionType_} a.authType in
<foreach collection="conditionParamRef.authTypeList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('authTypeStart') and condition.authTypeStart != null">
<![CDATA[ and a.authType >= #{condition.authTypeStart} ]]>
<if test="conditionParamRef.containsKey('authTypeNotList') and conditionParamRef.authTypeNotList.size() > 0">
${_conditionType_} a.authType not in
<foreach collection="conditionParamRef.authTypeNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('authTypeEnd') and condition.authTypeEnd != null">
<![CDATA[ and a.authType <= #{condition.authTypeEnd} ]]>
<if test="conditionParamRef.containsKey('authTypeStart') and conditionParamRef.authTypeStart != null">
${_conditionType_} a.authType <![CDATA[ >= ]]> #{${_conditionParam_}.authTypeStart}
</if>
<if test="condition.containsKey('createTime')">
<if test="condition.createTime != null ">
and a.createTime = #{condition.createTime}
<if test="conditionParamRef.containsKey('authTypeEnd') and conditionParamRef.authTypeEnd != null">
${_conditionType_} a.authType <![CDATA[ <= ]]> #{${_conditionParam_}.authTypeEnd}
</if>
<if test="condition.createTime == null">
and a.createTime is null
<if test="conditionParamRef.containsKey('createTime')">
<if test="conditionParamRef.createTime != null ">
${_conditionType_} a.createTime = #{${_conditionParam_}.createTime}
</if>
<if test="conditionParamRef.createTime == null">
${_conditionType_} a.createTime is null
</if>
<if test="condition.containsKey('createTimeStart') and condition.createTimeStart != null and condition.createTimeStart!=''">
<![CDATA[ and a.createTime >= STR_TO_DATE(left(concat(#{condition.createTimeStart},' 00:00:00'),19),'%Y-%m-%d %k:%i:%s') ]]>
</if>
<if test="condition.containsKey('createTimeEnd') and condition.createTimeEnd != null and condition.createTimeEnd!=''">
<![CDATA[ and a.createTime <= STR_TO_DATE(left(concat(#{condition.createTimeEnd},' 23:59:59'),19),'%Y-%m-%d %k:%i:%s') ]]>
<if test="conditionParamRef.containsKey('createTimeStart') and conditionParamRef.createTimeStart != null and conditionParamRef.createTimeStart!=''">
${_conditionType_} a.createTime <![CDATA[ >= ]]> STR_TO_DATE(left(concat(#{${_conditionParam_}.createTimeStart},' 00:00:00'),19),'%Y-%m-%d %k:%i:%s')
</if>
<if test="condition.containsKey('createUserId')">
<if test="condition.createUserId != null ">
and a.createUserId = #{condition.createUserId}
<if test="conditionParamRef.containsKey('createTimeEnd') and conditionParamRef.createTimeEnd != null and conditionParamRef.createTimeEnd!=''">
${_conditionType_} a.createTime <![CDATA[ <= ]]> STR_TO_DATE(left(concat(#{${_conditionParam_}.createTimeEnd},' 23:59:59'),19),'%Y-%m-%d %k:%i:%s')
</if>
<if test="condition.createUserId == null">
and a.createUserId is null
<if test="conditionParamRef.containsKey('createUserId')">
<if test="conditionParamRef.createUserId != null ">
${_conditionType_} a.createUserId = #{${_conditionParam_}.createUserId}
</if>
<if test="conditionParamRef.createUserId == null">
${_conditionType_} a.createUserId is null
</if>
<if test="condition.containsKey('createUserIdList')">
and a.createUserId in
<foreach collection="condition.createUserIdList" open="(" close=")" index="index" item="item" separator=",">
</if>
<if test="conditionParamRef.containsKey('createUserIdList') and conditionParamRef.createUserIdList.size() > 0">
${_conditionType_} a.createUserId in
<foreach collection="conditionParamRef.createUserIdList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('createUserIdStart') and condition.createUserIdStart != null">
<![CDATA[ and a.createUserId >= #{condition.createUserIdStart} ]]>
<if test="conditionParamRef.containsKey('createUserIdNotList') and conditionParamRef.createUserIdNotList.size() > 0">
${_conditionType_} a.createUserId not in
<foreach collection="conditionParamRef.createUserIdNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="condition.containsKey('createUserIdEnd') and condition.createUserIdEnd != null">
<![CDATA[ and a.createUserId <= #{condition.createUserIdEnd} ]]>
<if test="conditionParamRef.containsKey('createUserIdStart') and conditionParamRef.createUserIdStart != null">
${_conditionType_} a.createUserId <![CDATA[ >= ]]> #{${_conditionParam_}.createUserIdStart}
</if>
<if test="condition.containsKey('createUserName')">
<if test="condition.createUserName != null and condition.createUserName != ''">
and a.createUserName like #{condition.createUserName}
<if test="conditionParamRef.containsKey('createUserIdEnd') and conditionParamRef.createUserIdEnd != null">
${_conditionType_} a.createUserId <![CDATA[ <= ]]> #{${_conditionParam_}.createUserIdEnd}
</if>
<if test="condition.createUserName == null">
and a.createUserName is null
<if test="conditionParamRef.containsKey('createUserName')">
<if test="conditionParamRef.createUserName != null and conditionParamRef.createUserName != ''">
${_conditionType_} a.createUserName like #{${_conditionParam_}.createUserName}
</if>
<if test="conditionParamRef.createUserName == null">
${_conditionType_} a.createUserName is null
</if>
<if test="condition.containsKey('createUserNameList')">
and a.createUserName in
<foreach collection="condition.createUserNameList" open="(" close=")" index="index" item="item" separator=",">
</if>
<if test="conditionParamRef.containsKey('createUserNameList') and conditionParamRef.createUserNameList.size() > 0">
${_conditionType_} a.createUserName in
<foreach collection="conditionParamRef.createUserNameList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('createUserNameNotList') and conditionParamRef.createUserNameNotList.size() > 0">
${_conditionType_} a.createUserName not in
<foreach collection="conditionParamRef.createUserNameNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
</sql>
<sql id="_orderCols_">
......@@ -593,128 +966,97 @@
<trim suffixOverrides="," suffix="">
<if test="orderCol.containsKey('id')">
a.id
<if test="orderCol.id!= null">
${orderCol.id}
</if>
<if test='orderCol.id != null and "DESC".equalsIgnoreCase(orderCol.id)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('name')">
a.name
<if test="orderCol.name!= null">
${orderCol.name}
</if>
<if test='orderCol.name != null and "DESC".equalsIgnoreCase(orderCol.name)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('url')">
a.url
<if test="orderCol.url!= null">
${orderCol.url}
<if test='orderCol.url != null and "DESC".equalsIgnoreCase(orderCol.url)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('ancestors')">
a.ancestors
<if test='orderCol.ancestors != null and "DESC".equalsIgnoreCase(orderCol.ancestors)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('parentId')">
a.parentId
<if test="orderCol.parentId!= null">
${orderCol.parentId}
</if>
<if test='orderCol.parentId != null and "DESC".equalsIgnoreCase(orderCol.parentId)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('orderId')">
a.orderId
<if test="orderCol.orderId!= null">
${orderCol.orderId}
</if>
<if test='orderCol.orderId != null and "DESC".equalsIgnoreCase(orderCol.orderId)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('status')">
a.status
<if test="orderCol.status!= null">
${orderCol.status}
</if>
<if test='orderCol.status != null and "DESC".equalsIgnoreCase(orderCol.status)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('linkType')">
a.linkType
<if test="orderCol.linkType!= null">
${orderCol.linkType}
</if>
<if test='orderCol.linkType != null and "DESC".equalsIgnoreCase(orderCol.linkType)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('groupId')">
a.groupId
<if test="orderCol.groupId!= null">
${orderCol.groupId}
</if>
<if test='orderCol.groupId != null and "DESC".equalsIgnoreCase(orderCol.groupId)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('groupName')">
a.groupName
<if test="orderCol.groupName!= null">
${orderCol.groupName}
</if>
<if test='orderCol.groupName != null and "DESC".equalsIgnoreCase(orderCol.groupName)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('imgPath')">
a.imgPath
<if test="orderCol.imgPath!= null">
${orderCol.imgPath}
</if>
<if test='orderCol.imgPath != null and "DESC".equalsIgnoreCase(orderCol.imgPath)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('buttonImgPath')">
a.buttonImgPath
<if test="orderCol.buttonImgPath!= null">
${orderCol.buttonImgPath}
</if>
<if test='orderCol.buttonImgPath != null and "DESC".equalsIgnoreCase(orderCol.buttonImgPath)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('imgCommPath')">
a.imgCommPath
<if test="orderCol.imgCommPath!= null">
${orderCol.imgCommPath}
</if>
<if test='orderCol.imgCommPath != null and "DESC".equalsIgnoreCase(orderCol.imgCommPath)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('commMenu')">
a.commMenu
<if test="orderCol.commMenu!= null">
${orderCol.commMenu}
</if>
<if test='orderCol.commMenu != null and "DESC".equalsIgnoreCase(orderCol.commMenu)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('menuType')">
a.menuType
<if test="orderCol.menuType!= null">
${orderCol.menuType}
</if>
<if test='orderCol.menuType != null and "DESC".equalsIgnoreCase(orderCol.menuType)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('authType')">
a.authType
<if test="orderCol.authType!= null">
${orderCol.authType}
</if>
<if test='orderCol.authType != null and "DESC".equalsIgnoreCase(orderCol.authType)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('createTime')">
a.createTime
<if test="orderCol.createTime!= null">
${orderCol.createTime}
</if>
<if test='orderCol.createTime != null and "DESC".equalsIgnoreCase(orderCol.createTime)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('createUserId')">
a.createUserId
<if test="orderCol.createUserId!= null">
${orderCol.createUserId}
</if>
<if test='orderCol.createUserId != null and "DESC".equalsIgnoreCase(orderCol.createUserId)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('createUserName')">
a.createUserName
<if test="orderCol.createUserName!= null">
${orderCol.createUserName}
</if>
<if test='orderCol.createUserName != null and "DESC".equalsIgnoreCase(orderCol.createUserName)'>DESC</if>
,
</if>
</trim>
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"mybatis-3-mapper.dtd">
"mybatis-3-mapper.dtd">
<mapper namespace="com.mortals.xhx.module.appointment.dao.ibatis.AppointmentConfigDaoImpl">
<!-- 字段和属性映射 -->
......@@ -26,7 +26,7 @@
<collection property="appointmentConfigTimesList" column="id" ofType="AppointmentConfigTimesEntity" javaType="ArrayList" select="getAppointmentConfigTimesByAotoCheckCfgId"></collection>
</resultMap>
<resultMap type="AppointmentConfigTimesEntity" id="AppointmentConfigTimesEntity-Map">
<result property="Id" column="Id" />
<result property="id" column="id" />
<result property="aotoCheckCfgId" column="aotoCheckCfgId" />
<result property="serviceTimeStart" column="serviceTimeStart" />
<result property="serviceTimeEnd" column="serviceTimeEnd" />
......@@ -100,7 +100,7 @@
<!-- 子表所有列 -->
<sql id="_columns_sub">
<trim suffixOverrides="," suffix="">
b.Id,b.aotoCheckCfgId,b.serviceTimeStart,b.serviceTimeEnd,b.remark,b.createUserId,b.createTime,b.updateUserId,b.updateTime,
b.id,b.aotoCheckCfgId,b.serviceTimeStart,b.serviceTimeEnd,b.remark,b.createUserId,b.createTime,b.updateUserId,b.updateTime,
</trim>
</sql>
<!-- 新增 区分主键自增加还是业务插入 -->
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"mybatis-3-mapper.dtd">
"mybatis-3-mapper.dtd">
<mapper namespace="com.mortals.xhx.module.appointment.dao.ibatis.AppointmentConfigTimesDaoImpl">
<!-- 字段和属性映射 -->
<resultMap type="AppointmentConfigTimesEntity" id="AppointmentConfigTimesEntity-Map">
<id property="Id" column="Id" />
<id property="id" column="id" />
<result property="aotoCheckCfgId" column="aotoCheckCfgId" />
<result property="serviceTimeStart" column="serviceTimeStart" />
<result property="serviceTimeEnd" column="serviceTimeEnd" />
......@@ -21,8 +21,8 @@
<!-- 表所有列 -->
<sql id="_columns">
<trim suffixOverrides="," suffix="">
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('Id') or colPickMode == 1 and data.containsKey('Id')))">
a.Id,
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('id') or colPickMode == 1 and data.containsKey('id')))">
a.id,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('aotoCheckCfgId') or colPickMode == 1 and data.containsKey('aotoCheckCfgId')))">
a.aotoCheckCfgId,
......@@ -51,7 +51,7 @@
</trim>
</sql>
<!-- 新增 区分主键自增加还是业务插入 -->
<insert id="insert" parameterType="AppointmentConfigTimesEntity" useGeneratedKeys="true" keyProperty="Id">
<insert id="insert" parameterType="AppointmentConfigTimesEntity" useGeneratedKeys="true" keyProperty="id">
insert into mortals_xhx_appointment_config_times
(aotoCheckCfgId,serviceTimeStart,serviceTimeEnd,remark,createUserId,createTime,updateUserId,updateTime)
VALUES
......@@ -123,10 +123,10 @@
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('aotoCheckCfgId')) or (colPickMode==1 and !item.containsKey('aotoCheckCfgId'))">
when a.Id=#{item.Id} then #{item.aotoCheckCfgId}
when a.id=#{item.id} then #{item.aotoCheckCfgId}
</when>
<when test="(colPickMode==0 and item.containsKey('aotoCheckCfgIdIncrement')) or (colPickMode==1 and !item.containsKey('aotoCheckCfgIdIncrement'))">
when a.Id=#{item.Id} then ifnull(a.aotoCheckCfgId,0) + #{item.aotoCheckCfgIdIncrement}
when a.id=#{item.id} then ifnull(a.aotoCheckCfgId,0) + #{item.aotoCheckCfgIdIncrement}
</when>
</choose>
</foreach>
......@@ -134,21 +134,21 @@
<trim prefix="serviceTimeStart=(case" suffix="ELSE serviceTimeStart end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('serviceTimeStart')) or (colPickMode==1 and !item.containsKey('serviceTimeStart'))">
when a.Id=#{item.Id} then #{item.serviceTimeStart}
when a.id=#{item.id} then #{item.serviceTimeStart}
</if>
</foreach>
</trim>
<trim prefix="serviceTimeEnd=(case" suffix="ELSE serviceTimeEnd end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('serviceTimeEnd')) or (colPickMode==1 and !item.containsKey('serviceTimeEnd'))">
when a.Id=#{item.Id} then #{item.serviceTimeEnd}
when a.id=#{item.id} then #{item.serviceTimeEnd}
</if>
</foreach>
</trim>
<trim prefix="remark=(case" suffix="ELSE remark end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('remark')) or (colPickMode==1 and !item.containsKey('remark'))">
when a.Id=#{item.Id} then #{item.remark}
when a.id=#{item.id} then #{item.remark}
</if>
</foreach>
</trim>
......@@ -156,10 +156,10 @@
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('createUserId')) or (colPickMode==1 and !item.containsKey('createUserId'))">
when a.Id=#{item.Id} then #{item.createUserId}
when a.id=#{item.id} then #{item.createUserId}
</when>
<when test="(colPickMode==0 and item.containsKey('createUserIdIncrement')) or (colPickMode==1 and !item.containsKey('createUserIdIncrement'))">
when a.Id=#{item.Id} then ifnull(a.createUserId,0) + #{item.createUserIdIncrement}
when a.id=#{item.id} then ifnull(a.createUserId,0) + #{item.createUserIdIncrement}
</when>
</choose>
</foreach>
......@@ -167,7 +167,7 @@
<trim prefix="createTime=(case" suffix="ELSE createTime end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('createTime')) or (colPickMode==1 and !item.containsKey('createTime'))">
when a.Id=#{item.Id} then #{item.createTime}
when a.id=#{item.id} then #{item.createTime}
</if>
</foreach>
</trim>
......@@ -175,10 +175,10 @@
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('updateUserId')) or (colPickMode==1 and !item.containsKey('updateUserId'))">
when a.Id=#{item.Id} then #{item.updateUserId}
when a.id=#{item.id} then #{item.updateUserId}
</when>
<when test="(colPickMode==0 and item.containsKey('updateUserIdIncrement')) or (colPickMode==1 and !item.containsKey('updateUserIdIncrement'))">
when a.Id=#{item.Id} then ifnull(a.updateUserId,0) + #{item.updateUserIdIncrement}
when a.id=#{item.id} then ifnull(a.updateUserId,0) + #{item.updateUserIdIncrement}
</when>
</choose>
</foreach>
......@@ -186,36 +186,36 @@
<trim prefix="updateTime=(case" suffix="ELSE updateTime end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('updateTime')) or (colPickMode==1 and !item.containsKey('updateTime'))">
when a.Id=#{item.Id} then #{item.updateTime}
when a.id=#{item.id} then #{item.updateTime}
</if>
</foreach>
</trim>
</trim>
where Id in
where id in
<foreach collection="data.dataList" item="item" index="index" open="(" separator="," close=")">
#{item.Id}
#{item.id}
</foreach>
</update>
<!-- 根据主健查询 -->
<select id="getByKey" parameterType="paramDto" resultMap="AppointmentConfigTimesEntity-Map">
select <include refid="_columns"/>
from mortals_xhx_appointment_config_times as a
where a.Id=#{condition.Id}
where a.id=#{condition.id}
</select>
<!-- 根据主健删除 -->
<delete id="deleteByKey" parameterType="paramDto">
delete a.* from mortals_xhx_appointment_config_times as a where a.Id=#{condition.Id}
delete a.* from mortals_xhx_appointment_config_times as a where a.id=#{condition.id}
</delete>
<!-- 根据主健删除一批,针对单一主健有效 -->
<delete id="deleteByKeys">
delete from mortals_xhx_appointment_config_times where Id in
delete from mortals_xhx_appointment_config_times where id in
<foreach collection="array" item="item" index="index" open="(" separator="," close=")">
#{item}
</foreach>
</delete>
<!-- 根据主健列表删除一批,针对单一主健有效 -->
<delete id="deleteByKeyList">
delete from mortals_xhx_appointment_config_times where Id in
delete from mortals_xhx_appointment_config_times where id in
<foreach collection="list" item="item" index="index" open="(" separator="," close=")">
#{item}
</foreach>
......@@ -223,9 +223,9 @@
<!-- 根据对象列表删除一批,针对单一主健有效 -->
<delete id="deleteByEntityList">
delete from mortals_xhx_appointment_config_times where Id in
delete from mortals_xhx_appointment_config_times where id in
<foreach collection="list" item="item" index="index" open="(" separator="," close=")">
#{item.Id}
#{item.id}
</foreach>
</delete>
<!-- 根据paramDto删除一批 -->
......@@ -303,34 +303,34 @@
<bind name="conditionParamRef" value="${_conditionParam_}"/>
<if test="conditionParamRef.containsKey('id')">
<if test="conditionParamRef.id != null">
${_conditionType_} a.Id=#{${_conditionParam_}.id}
${_conditionType_} a.id=#{${_conditionParam_}.id}
</if>
</if>
<if test="conditionParamRef.containsKey('Id')">
<if test="conditionParamRef.Id != null ">
${_conditionType_} a.Id = #{${_conditionParam_}.Id}
<if test="conditionParamRef.containsKey('id')">
<if test="conditionParamRef.id != null ">
${_conditionType_} a.id = #{${_conditionParam_}.id}
</if>
<if test="conditionParamRef.Id == null">
${_conditionType_} a.Id is null
<if test="conditionParamRef.id == null">
${_conditionType_} a.id is null
</if>
</if>
<if test="conditionParamRef.containsKey('IdList') and conditionParamRef.IdList.size() > 0">
${_conditionType_} a.Id in
<foreach collection="conditionParamRef.IdList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('idList') and conditionParamRef.idList.size() > 0">
${_conditionType_} a.id in
<foreach collection="conditionParamRef.idList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('IdNotList') and conditionParamRef.IdNotList.size() > 0">
${_conditionType_} a.Id not in
<foreach collection="conditionParamRef.IdNotList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('idNotList') and conditionParamRef.idNotList.size() > 0">
${_conditionType_} a.id not in
<foreach collection="conditionParamRef.idNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('IdStart') and conditionParamRef.IdStart != null">
${_conditionType_} a.Id <![CDATA[ >= ]]> #{${_conditionParam_}.IdStart}
<if test="conditionParamRef.containsKey('idStart') and conditionParamRef.idStart != null">
${_conditionType_} a.id <![CDATA[ >= ]]> #{${_conditionParam_}.idStart}
</if>
<if test="conditionParamRef.containsKey('IdEnd') and conditionParamRef.IdEnd != null">
${_conditionType_} a.Id <![CDATA[ <= ]]> #{${_conditionParam_}.IdEnd}
<if test="conditionParamRef.containsKey('idEnd') and conditionParamRef.idEnd != null">
${_conditionType_} a.id <![CDATA[ <= ]]> #{${_conditionParam_}.idEnd}
</if>
<if test="conditionParamRef.containsKey('aotoCheckCfgId')">
......@@ -508,9 +508,9 @@
<if test="(orderColList == null or orderColList.isEmpty()) and orderCol != null and !orderCol.isEmpty()">
order by
<trim suffixOverrides="," suffix="">
<if test="orderCol.containsKey('Id')">
a.Id
<if test='orderCol.Id != null and "DESC".equalsIgnoreCase(orderCol.Id)'>DESC</if>
<if test="orderCol.containsKey('id')">
a.id
<if test='orderCol.id != null and "DESC".equalsIgnoreCase(orderCol.id)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('aotoCheckCfgId')">
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"mybatis-3-mapper.dtd">
"mybatis-3-mapper.dtd">
<mapper namespace="com.mortals.xhx.module.appointment.dao.ibatis.AppointmentConstraintDaoImpl">
<!-- 字段和属性映射 -->
......@@ -66,7 +66,7 @@
a.operator,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('constraint') or colPickMode == 1 and data.containsKey('constraint')))">
a.constraint,
a.`constraint`,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('createTime') or colPickMode == 1 and data.containsKey('createTime')))">
a.createTime,
......@@ -85,7 +85,7 @@
<!-- 新增 区分主键自增加还是业务插入 -->
<insert id="insert" parameterType="AppointmentConstraintEntity" useGeneratedKeys="true" keyProperty="id">
insert into mortals_xhx_appointment_constraint
(siteId,siteName,personId,name,contact,idCardType,idCardNo,accumulative,constraintTime,createMethod,operator,constraint,createTime,createUserId,updateTime,updateUserId)
(siteId,siteName,personId,name,contact,idCardType,idCardNo,accumulative,constraintTime,createMethod,operator,`constraint`,createTime,createUserId,updateTime,updateUserId)
VALUES
(#{siteId},#{siteName},#{personId},#{name},#{contact},#{idCardType},#{idCardNo},#{accumulative},#{constraintTime},#{createMethod},#{operator},#{constraint},#{createTime},#{createUserId},#{updateTime},#{updateUserId})
</insert>
......@@ -93,7 +93,7 @@
<!-- 批量新增 -->
<insert id="insertBatch" parameterType="paramDto">
insert into mortals_xhx_appointment_constraint
(siteId,siteName,personId,name,contact,idCardType,idCardNo,accumulative,constraintTime,createMethod,operator,constraint,createTime,createUserId,updateTime,updateUserId)
(siteId,siteName,personId,name,contact,idCardType,idCardNo,accumulative,constraintTime,createMethod,operator,`constraint`,createTime,createUserId,updateTime,updateUserId)
VALUES
<foreach collection="data.dataList" item="item" index="index" separator="," >
(#{item.siteId},#{item.siteName},#{item.personId},#{item.name},#{item.contact},#{item.idCardType},#{item.idCardNo},#{item.accumulative},#{item.constraintTime},#{item.createMethod},#{item.operator},#{item.constraint},#{item.createTime},#{item.createUserId},#{item.updateTime},#{item.updateUserId})
......@@ -152,10 +152,10 @@
a.operator=#{data.operator},
</if>
<if test="(colPickMode==0 and data.containsKey('constraint')) or (colPickMode==1 and !data.containsKey('constraint'))">
a.constraint=#{data.constraint},
a.`constraint`=#{data.constraint},
</if>
<if test="(colPickMode==0 and data.containsKey('constraintIncrement')) or (colPickMode==1 and !data.containsKey('constraintIncrement'))">
a.constraint=ifnull(a.constraint,0) + #{data.constraintIncrement},
a.`constraint`=ifnull(a.`constraint`,0) + #{data.constraintIncrement},
</if>
<if test="(colPickMode==0 and data.containsKey('createTime')) or (colPickMode==1 and !data.containsKey('createTime'))">
a.createTime=#{data.createTime},
......@@ -284,14 +284,14 @@
</if>
</foreach>
</trim>
<trim prefix="constraint=(case" suffix="ELSE constraint end),">
<trim prefix="`constraint`=(case" suffix="ELSE `constraint` end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('constraint')) or (colPickMode==1 and !item.containsKey('constraint'))">
when a.id=#{item.id} then #{item.constraint}
</when>
<when test="(colPickMode==0 and item.containsKey('constraintIncrement')) or (colPickMode==1 and !item.containsKey('constraintIncrement'))">
when a.id=#{item.id} then ifnull(a.constraint,0) + #{item.constraintIncrement}
when a.id=#{item.id} then ifnull(a.`constraint`,0) + #{item.constraintIncrement}
</when>
</choose>
</foreach>
......@@ -728,29 +728,29 @@
</if>
<if test="conditionParamRef.containsKey('constraint')">
<if test="conditionParamRef.constraint != null ">
${_conditionType_} a.constraint = #{${_conditionParam_}.constraint}
${_conditionType_} a.`constraint` = #{${_conditionParam_}.constraint}
</if>
<if test="conditionParamRef.constraint == null">
${_conditionType_} a.constraint is null
${_conditionType_} a.`constraint` is null
</if>
</if>
<if test="conditionParamRef.containsKey('constraintList') and conditionParamRef.constraintList.size() > 0">
${_conditionType_} a.constraint in
${_conditionType_} a.`constraint` in
<foreach collection="conditionParamRef.constraintList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('constraintNotList') and conditionParamRef.constraintNotList.size() > 0">
${_conditionType_} a.constraint not in
${_conditionType_} a.`constraint` not in
<foreach collection="conditionParamRef.constraintNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('constraintStart') and conditionParamRef.constraintStart != null">
${_conditionType_} a.constraint <![CDATA[ >= ]]> #{${_conditionParam_}.constraintStart}
${_conditionType_} a.`constraint` <![CDATA[ >= ]]> #{${_conditionParam_}.constraintStart}
</if>
<if test="conditionParamRef.containsKey('constraintEnd') and conditionParamRef.constraintEnd != null">
${_conditionType_} a.constraint <![CDATA[ <= ]]> #{${_conditionParam_}.constraintEnd}
${_conditionType_} a.`constraint` <![CDATA[ <= ]]> #{${_conditionParam_}.constraintEnd}
</if>
......@@ -911,7 +911,7 @@
,
</if>
<if test="orderCol.containsKey('constraint')">
a.constraint
a.`constraint`
<if test='orderCol.constraint != null and "DESC".equalsIgnoreCase(orderCol.constraint)'>DESC</if>
,
</if>
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"mybatis-3-mapper.dtd">
"mybatis-3-mapper.dtd">
<mapper namespace="com.mortals.xhx.module.care.dao.ibatis.CareConfigDaoImpl">
<!-- 字段和属性映射 -->
......@@ -28,7 +28,7 @@
<collection property="careConfigTimesList" column="id" ofType="CareConfigTimesEntity" javaType="ArrayList" select="getCareConfigTimesByCareCfgId"></collection>
</resultMap>
<resultMap type="CareConfigTimesEntity" id="CareConfigTimesEntity-Map">
<result property="Id" column="Id" />
<result property="id" column="id" />
<result property="careCfgId" column="careCfgId" />
<result property="serviceTimeStart" column="serviceTimeStart" />
<result property="serviceTimeEnd" column="serviceTimeEnd" />
......@@ -108,7 +108,7 @@
<!-- 子表所有列 -->
<sql id="_columns_sub">
<trim suffixOverrides="," suffix="">
b.Id,b.careCfgId,b.serviceTimeStart,b.serviceTimeEnd,b.remark,b.createUserId,b.createTime,b.updateUserId,b.updateTime,
b.id,b.careCfgId,b.serviceTimeStart,b.serviceTimeEnd,b.remark,b.createUserId,b.createTime,b.updateUserId,b.updateTime,
</trim>
</sql>
<!-- 新增 区分主键自增加还是业务插入 -->
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"mybatis-3-mapper.dtd">
"mybatis-3-mapper.dtd">
<mapper namespace="com.mortals.xhx.module.care.dao.ibatis.CareConfigTimesDaoImpl">
<!-- 字段和属性映射 -->
<resultMap type="CareConfigTimesEntity" id="CareConfigTimesEntity-Map">
<id property="Id" column="Id" />
<id property="id" column="id" />
<result property="careCfgId" column="careCfgId" />
<result property="serviceTimeStart" column="serviceTimeStart" />
<result property="serviceTimeEnd" column="serviceTimeEnd" />
......@@ -21,8 +21,8 @@
<!-- 表所有列 -->
<sql id="_columns">
<trim suffixOverrides="," suffix="">
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('Id') or colPickMode == 1 and data.containsKey('Id')))">
a.Id,
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('id') or colPickMode == 1 and data.containsKey('id')))">
a.id,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('careCfgId') or colPickMode == 1 and data.containsKey('careCfgId')))">
a.careCfgId,
......@@ -51,7 +51,7 @@
</trim>
</sql>
<!-- 新增 区分主键自增加还是业务插入 -->
<insert id="insert" parameterType="CareConfigTimesEntity" useGeneratedKeys="true" keyProperty="Id">
<insert id="insert" parameterType="CareConfigTimesEntity" useGeneratedKeys="true" keyProperty="id">
insert into mortals_xhx_care_config_times
(careCfgId,serviceTimeStart,serviceTimeEnd,remark,createUserId,createTime,updateUserId,updateTime)
VALUES
......@@ -123,10 +123,10 @@
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('careCfgId')) or (colPickMode==1 and !item.containsKey('careCfgId'))">
when a.Id=#{item.Id} then #{item.careCfgId}
when a.id=#{item.id} then #{item.careCfgId}
</when>
<when test="(colPickMode==0 and item.containsKey('careCfgIdIncrement')) or (colPickMode==1 and !item.containsKey('careCfgIdIncrement'))">
when a.Id=#{item.Id} then ifnull(a.careCfgId,0) + #{item.careCfgIdIncrement}
when a.id=#{item.id} then ifnull(a.careCfgId,0) + #{item.careCfgIdIncrement}
</when>
</choose>
</foreach>
......@@ -134,21 +134,21 @@
<trim prefix="serviceTimeStart=(case" suffix="ELSE serviceTimeStart end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('serviceTimeStart')) or (colPickMode==1 and !item.containsKey('serviceTimeStart'))">
when a.Id=#{item.Id} then #{item.serviceTimeStart}
when a.id=#{item.id} then #{item.serviceTimeStart}
</if>
</foreach>
</trim>
<trim prefix="serviceTimeEnd=(case" suffix="ELSE serviceTimeEnd end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('serviceTimeEnd')) or (colPickMode==1 and !item.containsKey('serviceTimeEnd'))">
when a.Id=#{item.Id} then #{item.serviceTimeEnd}
when a.id=#{item.id} then #{item.serviceTimeEnd}
</if>
</foreach>
</trim>
<trim prefix="remark=(case" suffix="ELSE remark end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('remark')) or (colPickMode==1 and !item.containsKey('remark'))">
when a.Id=#{item.Id} then #{item.remark}
when a.id=#{item.id} then #{item.remark}
</if>
</foreach>
</trim>
......@@ -156,10 +156,10 @@
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('createUserId')) or (colPickMode==1 and !item.containsKey('createUserId'))">
when a.Id=#{item.Id} then #{item.createUserId}
when a.id=#{item.id} then #{item.createUserId}
</when>
<when test="(colPickMode==0 and item.containsKey('createUserIdIncrement')) or (colPickMode==1 and !item.containsKey('createUserIdIncrement'))">
when a.Id=#{item.Id} then ifnull(a.createUserId,0) + #{item.createUserIdIncrement}
when a.id=#{item.id} then ifnull(a.createUserId,0) + #{item.createUserIdIncrement}
</when>
</choose>
</foreach>
......@@ -167,7 +167,7 @@
<trim prefix="createTime=(case" suffix="ELSE createTime end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('createTime')) or (colPickMode==1 and !item.containsKey('createTime'))">
when a.Id=#{item.Id} then #{item.createTime}
when a.id=#{item.id} then #{item.createTime}
</if>
</foreach>
</trim>
......@@ -175,10 +175,10 @@
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('updateUserId')) or (colPickMode==1 and !item.containsKey('updateUserId'))">
when a.Id=#{item.Id} then #{item.updateUserId}
when a.id=#{item.id} then #{item.updateUserId}
</when>
<when test="(colPickMode==0 and item.containsKey('updateUserIdIncrement')) or (colPickMode==1 and !item.containsKey('updateUserIdIncrement'))">
when a.Id=#{item.Id} then ifnull(a.updateUserId,0) + #{item.updateUserIdIncrement}
when a.id=#{item.id} then ifnull(a.updateUserId,0) + #{item.updateUserIdIncrement}
</when>
</choose>
</foreach>
......@@ -186,36 +186,36 @@
<trim prefix="updateTime=(case" suffix="ELSE updateTime end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('updateTime')) or (colPickMode==1 and !item.containsKey('updateTime'))">
when a.Id=#{item.Id} then #{item.updateTime}
when a.id=#{item.id} then #{item.updateTime}
</if>
</foreach>
</trim>
</trim>
where Id in
where id in
<foreach collection="data.dataList" item="item" index="index" open="(" separator="," close=")">
#{item.Id}
#{item.id}
</foreach>
</update>
<!-- 根据主健查询 -->
<select id="getByKey" parameterType="paramDto" resultMap="CareConfigTimesEntity-Map">
select <include refid="_columns"/>
from mortals_xhx_care_config_times as a
where a.Id=#{condition.Id}
where a.id=#{condition.id}
</select>
<!-- 根据主健删除 -->
<delete id="deleteByKey" parameterType="paramDto">
delete a.* from mortals_xhx_care_config_times as a where a.Id=#{condition.Id}
delete a.* from mortals_xhx_care_config_times as a where a.id=#{condition.id}
</delete>
<!-- 根据主健删除一批,针对单一主健有效 -->
<delete id="deleteByKeys">
delete from mortals_xhx_care_config_times where Id in
delete from mortals_xhx_care_config_times where id in
<foreach collection="array" item="item" index="index" open="(" separator="," close=")">
#{item}
</foreach>
</delete>
<!-- 根据主健列表删除一批,针对单一主健有效 -->
<delete id="deleteByKeyList">
delete from mortals_xhx_care_config_times where Id in
delete from mortals_xhx_care_config_times where id in
<foreach collection="list" item="item" index="index" open="(" separator="," close=")">
#{item}
</foreach>
......@@ -223,9 +223,9 @@
<!-- 根据对象列表删除一批,针对单一主健有效 -->
<delete id="deleteByEntityList">
delete from mortals_xhx_care_config_times where Id in
delete from mortals_xhx_care_config_times where id in
<foreach collection="list" item="item" index="index" open="(" separator="," close=")">
#{item.Id}
#{item.id}
</foreach>
</delete>
<!-- 根据paramDto删除一批 -->
......@@ -303,34 +303,34 @@
<bind name="conditionParamRef" value="${_conditionParam_}"/>
<if test="conditionParamRef.containsKey('id')">
<if test="conditionParamRef.id != null">
${_conditionType_} a.Id=#{${_conditionParam_}.id}
${_conditionType_} a.id=#{${_conditionParam_}.id}
</if>
</if>
<if test="conditionParamRef.containsKey('Id')">
<if test="conditionParamRef.Id != null ">
${_conditionType_} a.Id = #{${_conditionParam_}.Id}
<if test="conditionParamRef.containsKey('id')">
<if test="conditionParamRef.id != null ">
${_conditionType_} a.id = #{${_conditionParam_}.id}
</if>
<if test="conditionParamRef.Id == null">
${_conditionType_} a.Id is null
<if test="conditionParamRef.id == null">
${_conditionType_} a.id is null
</if>
</if>
<if test="conditionParamRef.containsKey('IdList') and conditionParamRef.IdList.size() > 0">
${_conditionType_} a.Id in
<foreach collection="conditionParamRef.IdList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('idList') and conditionParamRef.idList.size() > 0">
${_conditionType_} a.id in
<foreach collection="conditionParamRef.idList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('IdNotList') and conditionParamRef.IdNotList.size() > 0">
${_conditionType_} a.Id not in
<foreach collection="conditionParamRef.IdNotList" open="(" close=")" index="index" item="item" separator=",">
<if test="conditionParamRef.containsKey('idNotList') and conditionParamRef.idNotList.size() > 0">
${_conditionType_} a.id not in
<foreach collection="conditionParamRef.idNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('IdStart') and conditionParamRef.IdStart != null">
${_conditionType_} a.Id <![CDATA[ >= ]]> #{${_conditionParam_}.IdStart}
<if test="conditionParamRef.containsKey('idStart') and conditionParamRef.idStart != null">
${_conditionType_} a.id <![CDATA[ >= ]]> #{${_conditionParam_}.idStart}
</if>
<if test="conditionParamRef.containsKey('IdEnd') and conditionParamRef.IdEnd != null">
${_conditionType_} a.Id <![CDATA[ <= ]]> #{${_conditionParam_}.IdEnd}
<if test="conditionParamRef.containsKey('idEnd') and conditionParamRef.idEnd != null">
${_conditionType_} a.id <![CDATA[ <= ]]> #{${_conditionParam_}.idEnd}
</if>
<if test="conditionParamRef.containsKey('careCfgId')">
......@@ -508,9 +508,9 @@
<if test="(orderColList == null or orderColList.isEmpty()) and orderCol != null and !orderCol.isEmpty()">
order by
<trim suffixOverrides="," suffix="">
<if test="orderCol.containsKey('Id')">
a.Id
<if test='orderCol.Id != null and "DESC".equalsIgnoreCase(orderCol.Id)'>DESC</if>
<if test="orderCol.containsKey('id')">
a.id
<if test='orderCol.id != null and "DESC".equalsIgnoreCase(orderCol.id)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('careCfgId')">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment