Skip to content
Snippets Groups Projects
Verified Commit 3116b670 authored by Martin Weise's avatar Martin Weise
Browse files
parent 41d8d46b
No related branches found
No related tags found
1 merge request!411WIP
......@@ -4,6 +4,10 @@ author: Martin Weise
## v1.8.2 (2025-04-23)
#### Fixes
* Fixed a bug in the UI where the resource status was displayed as identifier when a draft identifier has been created.
#### Features
* Added structured logging through the `fluentd` protocol via the lightweight fluentbit in a
......
......@@ -11,6 +11,9 @@ import java.util.UUID;
@Repository
public interface IdentifierRepository extends JpaRepository<Identifier, UUID> {
@NotNull
List<Identifier> findAll();
/**
* Finds identifiers by given database id.
*
......
......@@ -13,6 +13,7 @@ import org.apache.commons.codec.digest.DigestUtils;
import org.apache.commons.lang3.RandomStringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.nio.charset.StandardCharsets;
import java.util.List;
......@@ -33,11 +34,13 @@ public class UserServiceImpl implements UserService {
}
@Override
@Transactional(readOnly = true)
public List<User> findAll() {
return userRepository.findAll();
}
@Override
@Transactional(readOnly = true)
public User findByUsername(String username) throws UserNotFoundException {
final Optional<User> optional = userRepository.findByUsername(username);
if (optional.isEmpty()) {
......@@ -48,11 +51,13 @@ public class UserServiceImpl implements UserService {
}
@Override
@Transactional(readOnly = true)
public List<User> findAllInternalUsers() {
return userRepository.findAllInternal();
}
@Override
@Transactional(readOnly = true)
public User findById(UUID id) throws UserNotFoundException {
final Optional<User> optional = userRepository.findById(id);
if (optional.isEmpty()) {
......@@ -63,6 +68,7 @@ public class UserServiceImpl implements UserService {
}
@Override
@Transactional
public User create(CreateUserDto data) {
/* create at authentication service */
final String passwordHash = "*" + DigestUtils.sha1Hex(DigestUtils.sha1(RandomStringUtils.randomAlphabetic(40)
......@@ -86,6 +92,7 @@ public class UserServiceImpl implements UserService {
}
@Override
@Transactional
public User modify(User user, UserUpdateDto data) throws UserNotFoundException, AuthServiceException {
user.setFirstname(data.getFirstname());
user.setLastname(data.getLastname());
......
......@@ -16,7 +16,11 @@
</template>
<script>
<<<<<<< Updated upstream
import { useCacheStore } from '~/stores/cache.js';
=======
import { useCacheStore } from '@/stores/cache.js'
>>>>>>> Stashed changes
export default {
props: {
......@@ -65,7 +69,11 @@ export default {
return this.cacheStore.getUser
},
hasIdentifier () {
<<<<<<< Updated upstream
if (!this.resource.identifiers) {
=======
if (!this.resource.identifiers || this.resource.identifiers.length === 0) {
>>>>>>> Stashed changes
return false
}
if (!this.cacheUser) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment