Search in sources :

Example 6 with HsaId

use of se.riv.infrastructure.directory.privatepractitioner.types.v1.HsaId in project webcert by sklintyg.

the class SendMessageToRecipientTypeConverterTest method buildSendMessageToRecipientType.

private SendMessageToRecipientType buildSendMessageToRecipientType() {
    SendMessageToRecipientType res = new SendMessageToRecipientType();
    res.setAmne(new Amneskod());
    res.getAmne().setCode("OVRIGT");
    res.getAmne().setCodeSystem("ffa59d8f-8d7e-46ae-ac9e-31804e8e8499");
    res.getAmne().setDisplayName("Övrigt");
    res.setIntygsId(new IntygId());
    res.getIntygsId().setRoot("TSTNMT2321000156-1039");
    res.getIntygsId().setExtension("79d77cad-0c19-4278-8212-b23c82a7e33c");
    res.setLogiskAdressMottagare("SendMessageStub");
    res.setMeddelande("svarstext meddelande");
    res.setMeddelandeId("b7360a70-80a3-4d24-b10e-621c3c0c826a");
    res.setPatientPersonId(new PersonId());
    res.getPatientPersonId().setRoot("1.2.752.129.2.1.3.1");
    res.getPatientPersonId().setExtension("19121212-1212");
    res.setReferensId("referensId");
    res.setRubrik("en fråga");
    res.setSkickatAv(new HosPersonal());
    res.getSkickatAv().setEnhet(new Enhet());
    res.getSkickatAv().getEnhet().setArbetsplatskod(new ArbetsplatsKod());
    res.getSkickatAv().getEnhet().getArbetsplatskod().setRoot("1.2.752.29.4.71");
    res.getSkickatAv().getEnhet().getArbetsplatskod().setExtension("1234567890");
    res.getSkickatAv().getEnhet().setEnhetsId(new HsaId());
    res.getSkickatAv().getEnhet().getEnhetsId().setRoot("1.2.752.129.2.1.4.1");
    res.getSkickatAv().getEnhet().getEnhetsId().setExtension("TSTNMT2321000156-1039");
    res.getSkickatAv().getEnhet().setEnhetsnamn("NMT vg1 ve2");
    res.getSkickatAv().getEnhet().setVardgivare(new Vardgivare());
    res.getSkickatAv().getEnhet().getVardgivare().setVardgivareId(new HsaId());
    res.getSkickatAv().getEnhet().getVardgivare().getVardgivareId().setRoot("1.2.752.129.2.1.4.1");
    res.getSkickatAv().getEnhet().getVardgivare().getVardgivareId().setExtension("TSTNMT2321000156-1002");
    res.getSkickatAv().getEnhet().getVardgivare().setVardgivarnamn("NMT vg1");
    res.getSkickatAv().setForskrivarkod("0000000");
    res.getSkickatAv().setFullstandigtNamn("Leonie Koehl");
    res.getSkickatAv().setPersonalId(new HsaId());
    res.getSkickatAv().getPersonalId().setRoot("1.2.752.129.2.1.4.1");
    res.getSkickatAv().getPersonalId().setExtension("TSTNMT2321000156-103F");
    res.setSkickatTidpunkt(LocalDateTime.now());
    res.setSvarPa(new MeddelandeReferens());
    res.getSvarPa().setMeddelandeId("5d665d73-7029-4619-9a91-3225a90d81c8");
    res.getSvarPa().setReferensId("referensid2");
    return res;
}
Also used : HosPersonal(se.riv.clinicalprocess.healthcond.certificate.v3.HosPersonal) Enhet(se.riv.clinicalprocess.healthcond.certificate.v3.Enhet) ArbetsplatsKod(se.riv.clinicalprocess.healthcond.certificate.types.v3.ArbetsplatsKod) PersonId(se.riv.clinicalprocess.healthcond.certificate.types.v3.PersonId) SendMessageToRecipientType(se.riv.clinicalprocess.healthcond.certificate.sendMessageToRecipient.v2.SendMessageToRecipientType) Vardgivare(se.riv.clinicalprocess.healthcond.certificate.v3.Vardgivare) Amneskod(se.riv.clinicalprocess.healthcond.certificate.types.v3.Amneskod) HsaId(se.riv.clinicalprocess.healthcond.certificate.types.v3.HsaId) MeddelandeReferens(se.riv.clinicalprocess.healthcond.certificate.v3.MeddelandeReferens) IntygId(se.riv.clinicalprocess.healthcond.certificate.types.v3.IntygId)

Example 7 with HsaId

use of se.riv.infrastructure.directory.privatepractitioner.types.v1.HsaId in project webcert by sklintyg.

the class CreateNewDraftRequestBuilderTest method createUtlatande.

private Utlatande createUtlatande() {
    Utlatande utlatande = new Utlatande();
    // Type
    TypAvUtlatande utlTyp = new TypAvUtlatande();
    utlTyp.setCode(CERT_TYPE);
    utlatande.setTypAvUtlatande(utlTyp);
    // HoSPerson
    HsaId userHsaId = new HsaId();
    userHsaId.setExtension(USER_HSAID);
    userHsaId.setRoot("USERHSAID");
    HosPersonal hosPerson = new HosPersonal();
    hosPerson.setPersonalId(userHsaId);
    hosPerson.setFullstandigtNamn(FULLSTANDIGT_NAMN);
    HsaId unitHsaId = new HsaId();
    unitHsaId.setExtension(UNIT_HSAID);
    unitHsaId.setRoot("UNITHSAID");
    Enhet hosEnhet = new Enhet();
    hosEnhet.setEnhetsId(unitHsaId);
    hosPerson.setEnhet(hosEnhet);
    utlatande.setSkapadAv(hosPerson);
    // Patient
    PersonId personId = new PersonId();
    personId.setRoot("PERSNR");
    personId.setExtension(PERSNR);
    Patient patType = new Patient();
    patType.setPersonId(personId);
    patType.getFornamn().add("Adam");
    patType.getFornamn().add("Bertil");
    patType.getMellannamn().add("Cesarsson");
    patType.getMellannamn().add("Davidsson");
    patType.setEfternamn("Eriksson");
    utlatande.setPatient(patType);
    return utlatande;
}
Also used : HosPersonal(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.HosPersonal) Enhet(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.Enhet) PersonId(se.riv.clinicalprocess.healthcond.certificate.types.v1.PersonId) Utlatande(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.Utlatande) TypAvUtlatande(se.riv.clinicalprocess.healthcond.certificate.types.v1.TypAvUtlatande) Patient(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.Patient) HsaId(se.riv.clinicalprocess.healthcond.certificate.types.v1.HsaId) TypAvUtlatande(se.riv.clinicalprocess.healthcond.certificate.types.v1.TypAvUtlatande)

Example 8 with HsaId

use of se.riv.infrastructure.directory.privatepractitioner.types.v1.HsaId in project webcert by sklintyg.

the class CreateNewDraftRequestBuilderTest method createIntyg.

private Intyg createIntyg() {
    Intyg intyg = new Intyg();
    TypAvIntyg intygTyp = new TypAvIntyg();
    intygTyp.setCode(CERT_TYPE);
    intyg.setTypAvIntyg(intygTyp);
    HosPersonal hosPerson = new HosPersonal();
    HsaId userHsaId = new HsaId();
    userHsaId.setExtension(USER_HSAID);
    userHsaId.setRoot("USERHSAID");
    hosPerson.setPersonalId(userHsaId);
    hosPerson.setFullstandigtNamn(FULLSTANDIGT_NAMN);
    Enhet hosEnhet = new Enhet();
    HsaId unitHsaId = new HsaId();
    unitHsaId.setExtension(UNIT_HSAID);
    unitHsaId.setRoot("UNITHSAID");
    hosEnhet.setEnhetsId(unitHsaId);
    hosPerson.setEnhet(hosEnhet);
    intyg.setSkapadAv(hosPerson);
    Patient patType = new Patient();
    PersonId personId = new PersonId();
    personId.setRoot("PERSNR");
    personId.setExtension(PERSONNUMMER);
    patType.setPersonId(personId);
    patType.setFornamn(FORNAMN);
    patType.setMellannamn(MELLANNAMN);
    patType.setEfternamn(EFTERNAMN);
    patType.setPostadress(PATIENT_POSTADRESS);
    patType.setPostnummer(PATIENT_POSTNUMMER);
    patType.setPostort(PATIENT_POSTORT);
    intyg.setPatient(patType);
    return intyg;
}
Also used : HosPersonal(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v3.HosPersonal) Enhet(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v3.Enhet) TypAvIntyg(se.riv.clinicalprocess.healthcond.certificate.types.v3.TypAvIntyg) PersonId(se.riv.clinicalprocess.healthcond.certificate.types.v3.PersonId) TypAvIntyg(se.riv.clinicalprocess.healthcond.certificate.types.v3.TypAvIntyg) Intyg(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v3.Intyg) Patient(se.riv.clinicalprocess.healthcond.certificate.v3.Patient) HsaId(se.riv.clinicalprocess.healthcond.certificate.types.v3.HsaId)

Example 9 with HsaId

use of se.riv.infrastructure.directory.privatepractitioner.types.v1.HsaId in project webcert by sklintyg.

the class CreateDraftCertificateResponderImplTest method createCertificateType.

private CreateDraftCertificateType createCertificateType() {
    // Type
    TypAvUtlatande utlTyp = new TypAvUtlatande();
    utlTyp.setCode("fk7263");
    // HoSPerson
    HsaId userHsaId = new HsaId();
    userHsaId.setExtension(USER_HSAID);
    userHsaId.setRoot("USERHSAID");
    HsaId unitHsaId = new HsaId();
    unitHsaId.setExtension(UNIT_HSAID);
    unitHsaId.setRoot("UNITHSAID");
    Enhet hosEnhet = new Enhet();
    hosEnhet.setEnhetsId(unitHsaId);
    HosPersonal hosPerson = new HosPersonal();
    hosPerson.setFullstandigtNamn("Abel Baker");
    hosPerson.setPersonalId(userHsaId);
    hosPerson.setEnhet(hosEnhet);
    // Patient
    PersonId personId = new PersonId();
    personId.setRoot("PERSNR");
    personId.setExtension("19121212-1212");
    Patient patType = new Patient();
    patType.setPersonId(personId);
    patType.getFornamn().add("Adam");
    patType.getFornamn().add("Bertil");
    patType.getMellannamn().add("Cesarsson");
    patType.getMellannamn().add("Davidsson");
    patType.setEfternamn("Eriksson");
    Utlatande utlatande = new Utlatande();
    utlatande.setTypAvUtlatande(utlTyp);
    utlatande.setSkapadAv(hosPerson);
    utlatande.setPatient(patType);
    CreateDraftCertificateType certificateType = new CreateDraftCertificateType();
    certificateType.setUtlatande(utlatande);
    return certificateType;
}
Also used : HosPersonal(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.HosPersonal) Enhet(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.Enhet) PersonId(se.riv.clinicalprocess.healthcond.certificate.types.v1.PersonId) CreateDraftCertificateType(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.CreateDraftCertificateType) TypAvUtlatande(se.riv.clinicalprocess.healthcond.certificate.types.v1.TypAvUtlatande) Utlatande(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.Utlatande) Patient(se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.Patient) HsaId(se.riv.clinicalprocess.healthcond.certificate.types.v1.HsaId) TypAvUtlatande(se.riv.clinicalprocess.healthcond.certificate.types.v1.TypAvUtlatande)

Example 10 with HsaId

use of se.riv.infrastructure.directory.privatepractitioner.types.v1.HsaId in project webcert by sklintyg.

the class ElegWebCertUserDetailsServiceTest method buildHosPerson.

private HoSPersonType buildHosPerson() {
    HoSPersonType hoSPersonType = new HoSPersonType();
    HsaId hsaId = new HsaId();
    hsaId.setExtension(HSA_ID);
    hoSPersonType.setHsaId(hsaId);
    PersonId personId = new PersonId();
    personId.setExtension(PERSON_ID);
    hoSPersonType.setPersonId(personId);
    EnhetType vardEnhet = new EnhetType();
    vardEnhet.setEnhetsnamn("enhetsNamn");
    HsaId enhetsId = new HsaId();
    enhetsId.setExtension("enhetsId");
    vardEnhet.setEnhetsId(enhetsId);
    VardgivareType vardgivare = new VardgivareType();
    HsaId vardgivareId = new HsaId();
    enhetsId.setExtension("vardgivareId");
    vardgivare.setVardgivareId(vardgivareId);
    vardgivare.setVardgivarenamn("vardgivareName");
    vardEnhet.setVardgivare(vardgivare);
    hoSPersonType.setEnhet(vardEnhet);
    return hoSPersonType;
}
Also used : PersonId(se.riv.infrastructure.directory.privatepractitioner.types.v1.PersonId) HoSPersonType(se.riv.infrastructure.directory.privatepractitioner.v1.HoSPersonType) EnhetType(se.riv.infrastructure.directory.privatepractitioner.v1.EnhetType) VardgivareType(se.riv.infrastructure.directory.privatepractitioner.v1.VardgivareType) HsaId(se.riv.infrastructure.directory.privatepractitioner.types.v1.HsaId)

Aggregations

HsaId (se.riv.clinicalprocess.healthcond.certificate.types.v3.HsaId)8 PersonId (se.riv.clinicalprocess.healthcond.certificate.types.v3.PersonId)6 Test (org.junit.Test)3 Enhet (se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.Enhet)3 HosPersonal (se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.HosPersonal)3 Patient (se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.Patient)3 Utlatande (se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v1.Utlatande)3 Enhet (se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v3.Enhet)3 HosPersonal (se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v3.HosPersonal)3 Intyg (se.riv.clinicalprocess.healthcond.certificate.createdraftcertificateresponder.v3.Intyg)3 ListCertificatesForCareWithQAType (se.riv.clinicalprocess.healthcond.certificate.listCertificatesForCareWithQA.v3.ListCertificatesForCareWithQAType)3 HsaId (se.riv.clinicalprocess.healthcond.certificate.types.v1.HsaId)3 PersonId (se.riv.clinicalprocess.healthcond.certificate.types.v1.PersonId)3 TypAvUtlatande (se.riv.clinicalprocess.healthcond.certificate.types.v1.TypAvUtlatande)3 TypAvIntyg (se.riv.clinicalprocess.healthcond.certificate.types.v3.TypAvIntyg)3 Patient (se.riv.clinicalprocess.healthcond.certificate.v3.Patient)3 LocalDate (java.time.LocalDate)1 CertificateHolder (se.inera.intyg.common.support.modules.support.api.CertificateHolder)1 ArendeCount (se.inera.intyg.common.support.modules.support.api.notification.ArendeCount)1 Personnummer (se.inera.intyg.schemas.contract.Personnummer)1