| | |
| | | import com.moral.common.util.Crypto;
|
| | | import com.moral.common.util.ResourceUtil;
|
| | | import com.moral.entity.Account;
|
| | | import com.moral.entity.Organization;
|
| | | import com.moral.mapper.AccountMapper;
|
| | | import com.moral.mapper.OrganizationMapper;
|
| | | import com.moral.service.AccountService;
|
| | | import com.moral.service.OrganizationService;
|
| | |
|
| | |
| | | @Resource
|
| | | private OrganizationService organizationService;
|
| | |
|
| | | @Resource
|
| | | private OrganizationMapper organizationMapper;
|
| | | |
| | | @Override
|
| | | public Map<String, Object> screenLogin(Map<String, Object> parameters) {
|
| | | Map<String, Object> result = new HashMap<String, Object>();
|
| | |
| | | }
|
| | | PageHelper.startPage(Integer.valueOf((String) parameters.get("pageIndex")), Integer.valueOf((String) parameters.get("pageSize")));
|
| | | List<Account> accounts = accountMapper.selectByExample(example);
|
| | | for (Account account : accounts) {
|
| | | if (!ObjectUtils.isEmpty(account.getOrganizationId())) {
|
| | | Organization organization = organizationMapper.selectByPrimaryKey(account.getOrganizationId());
|
| | | account.setOrganization(organization);
|
| | | }
|
| | | }
|
| | | return new PageBean<Account>(accounts);
|
| | | }
|
| | |
|
| | |
| | | return accountMapper.updateByExampleSelective(account, example);
|
| | | }
|
| | |
|
| | | @Override
|
| | | public Integer getAccountCountByAccountName(String accountName) {
|
| | | Account account = new Account();
|
| | | account.setAccountName(accountName);
|
| | | return accountMapper.selectCount(account);
|
| | | }
|
| | |
|
| | | }
|