| | |
| | | <result property="idCard" column="id_card"/> |
| | | <result property="company" column="company"/> |
| | | <result property="residence" column="residence"/> |
| | | <result property="isPanzhihua" column="is_panzhiHua"/> |
| | | <result property="isPanzhihua" column="is_panzhihua"/> |
| | | <result property="situation" column="situation"/> |
| | | <result property="isContact" column="is_contact"/> |
| | | <result property="major" column="major"/> |
| | | <result property="soldier" column="soldier"/> |
| | | <result property="lowincomeHouseholds" column="lowIncome_households"/> |
| | | <result property="lowincomePeople" column="lowIncome_people"/> |
| | | <result property="lowincomeHouseholds" column="low_income_households"/> |
| | | <result property="lowincomePeople" column="low_income_people"/> |
| | | <result property="oldPeople" column="old_people"/> |
| | | <result property="specialServiceFamily" column="special_service_family"/> |
| | | <result property="keyPersonnel" column="key_personnel"/> |
| | |
| | | |
| | | </resultMap> |
| | | <sql id="columns"> |
| | | `id`,`door_number`,`is_rent`,`name`,`nation`,`political_outlook`,`marital_status`,`phone`,`education`,`id_card`,`company`,`residence`,`is_panzhiHua`,`situation`,`is_contact`,`major`,`soldier`,`lowIncome_households`,`lowIncome_people`,`old_people`,`special_service_family`,`key_personnel`,`community_id`,`area_id`,`create_at`,`update_at`,`house_code`,`disability`,`tags` |
| | | `id`,`door_number`,`is_rent`,`name`,`nation`,`political_outlook`,`marital_status`,`phone`,`education`,`id_card`,`company`,`residence`,`is_panzhihua`,`situation`,`is_contact`,`major`,`soldier`,`low_income_households`,`low_income_people`,`old_people`,`special_service_family`,`key_personnel`,`community_id`,`area_id`,`create_at`,`update_at`,`house_code`,`disability`,`tags` |
| | | </sql> |
| | | |
| | | |
| | |
| | | SELECT u.id 'order', c.`area_name` areaName, u.door_number doorNumber, if(u.is_rent=1,'租住','自主')isRent, u.name, |
| | | u.nation, case u.political_outlook when 1 then '党员' when 2 then '团员' else '群众' end politicalOutlook, |
| | | if(u.marital_status=1,'已婚','未婚')maritalStatus, u.phone, u.education, u.id_card, u.company, u.residence, |
| | | if(u.is_panzhiHua=1,'是','否') isPanZhiHua, u.situation, if(is_contact=1,'是','否') isContact, if(u.major=1,'是','否') |
| | | if(u.is_panzhihua=1,'是','否') isPanZhiHua, u.situation, if(is_contact=1,'是','否') isContact, if(u.major=1,'是','否') |
| | | major, if(u.soldier=1,'是','否') soldier, if(u.disability=1,'是','否') disability, |
| | | if(u.lowIncome_households=1,'是','否') lowIncomeHouseholds, if(u.lowIncome_people=1,'是','否') lowIncomePeople, |
| | | if(u.low_income_households=1,'是','否') lowIncomeHouseholds, if(u.low_income_people=1,'是','否') lowIncomePeople, |
| | | if(u.old_people=1,'是','否') oldPeople, if(u.special_service_family=1,'是','否') specialServiceFamily, |
| | | if(u.key_personnel=1,'是','否') keyPersonnel, u.tags FROM sys_user_input u JOIN com_mng_struct_area c ON u.area_id |
| | | = c.id where u.community_id=#{exportSpecialUserDTO.communityId} |
| | |
| | | like concat(#{exportSpecialUserDTO.name},'%') |
| | | </if> |
| | | <if test='exportSpecialUserDTO.tags != null and exportSpecialUserDTO.tags.trim() != ""'>CONCAT( IF ( |
| | | t.soldier = 1, '军人,', '' ), IF ( t.lowIncome_households = 1, '低保户,', '' ), IF ( t.lowIncome_people = 1, |
| | | t.soldier = 1, '军人,', '' ), IF ( t.low_income_households = 1, '低保户,', '' ), IF ( t.low_income_people = 1, |
| | | '低收入,', '' ), IF ( t.old_people = 1, '特服家庭,', '' ), IF ( t.key_personnel = 1, '重点人员,', '' ), |
| | | IFNULL(t.tags,'') ) like concat(#{exportSpecialUserDTO.tags},'%') |
| | | </if> |
| | |
| | | SELECT u.id 'order', c.`area_name` areaName, u.door_number doorNumber, if(u.is_rent=1,'租住','自主')isRent, u.name, |
| | | u.nation, case u.political_outlook when 1 then '党员' when 2 then '团员' else '群众' end politicalOutlook, |
| | | if(u.marital_status=1,'已婚','未婚')maritalStatus, u.phone, u.education, u.id_card, u.company, u.residence, |
| | | if(u.is_panzhiHua=1,'是','否') isPanZhiHua, u.situation, if(is_contact=1,'是','否') isContact, if(u.major=1,'是','否') |
| | | if(u.is_panzhihua=1,'是','否') isPanZhiHua, u.situation, if(is_contact=1,'是','否') isContact, if(u.major=1,'是','否') |
| | | major, if(u.soldier=1,'是','否') soldier, if(u.disability=1,'是','否') disability, |
| | | if(u.lowIncome_households=1,'是','否') lowIncomeHouseholds, if(u.lowIncome_people=1,'是','否') lowIncomePeople, |
| | | if(u.low_income_households=1,'是','否') lowIncomeHouseholds, if(u.low_income_people=1,'是','否') lowIncomePeople, |
| | | if(u.old_people=1,'是','否') oldPeople, if(u.special_service_family=1,'是','否') specialServiceFamily, |
| | | if(u.key_personnel=1,'是','否') keyPersonnel, u.tags FROM sys_user_input u where |
| | | u.community_id=#{exportUserDTO.communityId} |
| | |
| | | 2, IF ( length( t.id_card ) = 15, cast( substring( t.id_card, 15, 1 ) AS UNSIGNED ) % 2, 3 ) ) WHEN 1 THEN 1 |
| | | WHEN 0 THEN 2 ELSE 0 END AS sex, t.phone, YEAR ( now( ) ) - YEAR ( substring( t.id_card, 7, 8 ) ) age, |
| | | t1.area_name as areaName, t.political_outlook politicalOutlook, CONCAT( IF ( t.soldier = 1, '军人,', '' ), IF ( |
| | | t.lowIncome_households = 1, '低保户,', '' ), IF ( t.lowIncome_people = 1, '低收入,', '' ), IF ( t.old_people = 1, |
| | | t.low_income_households = 1, '低保户,', '' ), IF ( t.low_income_people = 1, '低收入,', '' ), IF ( t.old_people = 1, |
| | | '特服家庭,', '' ), IF ( t.key_personnel = 1, '重点人员,', '' ) ) tags, t.create_at as createAt FROM sys_user_input t |
| | | LEFT JOIN com_mng_struct_area t1 ON t.area_id = t1.id WHERE t.community_id = #{pageInputUserDTO.communityId} |
| | | <if |
| | |
| | | AS UNSIGNED ) % 2, IF ( length( t.id_card ) = 15, cast( substring( t.id_card, 15, 1 ) AS UNSIGNED ) % 2, 3 ) ) |
| | | WHEN 1 THEN 1 WHEN 0 THEN 2 ELSE 0 END AS sex, t.phone, YEAR ( now( ) ) - YEAR ( substring( t.id_card, 7, 8 ) ) |
| | | age, t1.area_name as areaName, t.political_outlook politicalOutlook, CONCAT( IF ( t.soldier = 1, '军人,', '' ), IF |
| | | ( t.lowIncome_households = 1, '低保户,', '' ), IF ( t.lowIncome_people = 1, '低收入,', '' ), IF ( t.old_people = 1, |
| | | ( t.low_income_households = 1, '低保户,', '' ), IF ( t.low_income_people = 1, '低收入,', '' ), IF ( t.old_people = 1, |
| | | '特服家庭,', '' ), IF ( t.key_personnel = 1, '重点人员,', '' ), IFNULL(t.tags,'') ) tags, t2.house_name as address, |
| | | t.create_at as createAt FROM sys_user_input t LEFT JOIN com_mng_struct_area t1 ON t.area_id = t1.id LEFT JOIN |
| | | com_mng_struct_house t2 ON t.house_code = t2.house_code WHERE t.community_id = #{pageInputUserDTO.communityId} |
| | | AND (t.soldier=1 OR t.lowIncome_households=1 OR t.lowIncome_people=1 or t.old_people=1 OR |
| | | AND (t.soldier=1 OR t.low_income_households=1 OR t.low_income_people=1 or t.old_people=1 OR |
| | | t.special_service_family=1 OR t.key_personnel=1 OR |
| | | (t.tags IS NOT NULL AND TRIM(t.tags)!='')) |
| | | <if test='pageInputUserDTO.name != null and pageInputUserDTO.name.trim() != ""'> |