| | |
| | | import com.ruoyi.system.mapper.*; |
| | | import com.ruoyi.system.service.ISysConfigService; |
| | | import com.ruoyi.system.service.ISysUserService; |
| | | import com.smartor.domain.IvrLibaScriptAssort; |
| | | import com.smartor.domain.SvyLibScriptCategory; |
| | | import com.smartor.domain.SvyTaskVO; |
| | | import com.smartor.domain.SysUserOrg; |
| | | import com.smartor.mapper.IvrLibaScriptAssortMapper; |
| | | import com.smartor.mapper.SvyLibScriptCategoryMapper; |
| | | import com.smartor.mapper.SysUserDeptMapper; |
| | | import com.smartor.mapper.SysUserOrgMapper; |
| | | import org.slf4j.Logger; |
| | |
| | | |
| | | @Autowired |
| | | private SysUserDeptMapper sysUserDeptMapper; |
| | | |
| | | @Autowired |
| | | private IvrLibaScriptAssortMapper ivrLibaScriptAssortMapper; |
| | | |
| | | @Autowired |
| | | private SvyLibScriptCategoryMapper svyLibScriptCategoryMapper; |
| | | |
| | | @Autowired |
| | | private SysRoleMapper roleMapper; |
| | |
| | | if (StringUtils.isNotEmpty(sud.getDeptName())) map.put("deptName", sud.getDeptName()); |
| | | list.add(map); |
| | | } |
| | | //获取当前机构的满意度问题分类 |
| | | sysUser.setBelongDepts(list); |
| | | Map<String, Object> satisfactionCategories = new HashMap<>(); |
| | | //获取语音问题分类 |
| | | IvrLibaScriptAssort ivrLibaScriptAssort = new IvrLibaScriptAssort(); |
| | | ivrLibaScriptAssort.setOrgid(sysUser.getOrgid()); |
| | | ivrLibaScriptAssort.setType("myd"); |
| | | List<IvrLibaScriptAssort> ivrLibaScriptAssorts = ivrLibaScriptAssortMapper.selectIvrLibaScriptAssortList(ivrLibaScriptAssort); |
| | | List<Map<String, Object>> categoryList = new ArrayList<>(); |
| | | if (!CollectionUtils.isEmpty(ivrLibaScriptAssorts)) { |
| | | for (IvrLibaScriptAssort assort : ivrLibaScriptAssorts) { |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("categoryid", assort.getId()); |
| | | map.put("categoryName", assort.getIndexAssortName()); |
| | | categoryList.add(map); |
| | | } |
| | | } |
| | | satisfactionCategories.put("voiceCategories", categoryList); |
| | | |
| | | //获取问卷问题分类 |
| | | SvyLibScriptCategory svyLibScriptCategory = new SvyLibScriptCategory(); |
| | | svyLibScriptCategory.setOrgid(sysUser.getOrgid()); |
| | | svyLibScriptCategory.setType("myd"); |
| | | List<SvyLibScriptCategory> svyLibScriptCategories = svyLibScriptCategoryMapper.selectSvyLibScriptCategoryList(svyLibScriptCategory); |
| | | List<Map<String, Object>> questionnaireCategorys = new ArrayList<>(); |
| | | if (!CollectionUtils.isEmpty(svyLibScriptCategories)) { |
| | | for (SvyLibScriptCategory scriptCategory : svyLibScriptCategories) { |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("categoryid", scriptCategory.getId()); |
| | | map.put("categoryName", scriptCategory.getName()); |
| | | questionnaireCategorys.add(map); |
| | | } |
| | | } |
| | | satisfactionCategories.put("questionnaireCategorys", CollectionUtils.isEmpty(questionnaireCategorys) ? null : questionnaireCategorys); |
| | | |
| | | //设置当前用户的声音问题分类和问卷问题分类 |
| | | sysUser.setSatisfactionCategories(satisfactionCategories); |
| | | } |
| | | return sysUser; |
| | | } |