fix decrypt password
This commit is contained in:
@@ -5,6 +5,7 @@ import com.iconplus.smartproc.helper.model.EmptyResponse;
|
||||
import com.iconplus.smartproc.helper.service.BaseService;
|
||||
import com.iconplus.smartproc.model.request.JabatanRequest;
|
||||
import com.iconplus.smartproc.repository.JabatanRepository;
|
||||
import com.iconplus.smartproc.util.Constants;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@Service
|
||||
@@ -17,7 +18,10 @@ public class DeleteJabatanService implements BaseService<JabatanRequest, EmptyRe
|
||||
@Override
|
||||
public EmptyResponse execute(JabatanRequest input) {
|
||||
var jabatan = jabatanRepository.findByIdAndIsDeleteFalse(input.getId())
|
||||
.orElseThrow(() -> new BusinessException("err", "err", "err"));
|
||||
.orElseThrow(() -> new BusinessException(Constants.ERR_CODE_10001,
|
||||
Constants.ERR_TTL_10001,
|
||||
String.format(Constants.ERR_MSG_10001, "Jabatan", input.getId())));
|
||||
|
||||
jabatan.setIsDelete(true);
|
||||
jabatanRepository.save(jabatan);
|
||||
return new EmptyResponse();
|
||||
|
Reference in New Issue
Block a user