Skip to content
Snippets Groups Projects
Commit 457cebf7 authored by Petr.Kalashnikov's avatar Petr.Kalashnikov
Browse files

Merge branch 'pte18' into 'master'

Move client module from PTE service

See merge request !41
parents 5ce4a161 09ddee30
No related branches found
No related tags found
1 merge request!41Move client module from PTE service
Pipeline #235153 passed with stages
in 3 minutes
......@@ -871,6 +871,19 @@ class EphClient:
return None
return EphAdministrativEnhet.from_orm(orm_obj)
def update_list_of_fields(
self, journalpost_id: int, fields_to_update: Dict[str, Any]
) -> Optional[Any]:
jp = self.fetch_by_id("Journalpost", journalpost_id)
jp.Hjemmel = fields_to_update["hjemmel"]
jp.TilgangskodeId = fields_to_update["tilgangskode_id"]
jp.TilgangsgruppeId = fields_to_update["tilgangsgruppe_id"]
jp.AvsenderMottakerUntattOffentlighet = fields_to_update[
"avsender_mottaker_untatt_offentlighet"
]
resp = self.insert_or_update(ins_obj=[jp], update=True)
return resp
def get_ord_verdi_id(self, prefix: str, prinsipp: str, req: CreateSakReq) -> str:
if prinsipp == PrinsippType.ansatt_nr.value or prinsipp == PrinsippType.anr:
return req.person.emp_nr
......
......@@ -209,7 +209,6 @@ def test_fetch_sak(client, service_config):
@pytest.mark.integration
def test_search_jp_by_field(client, service_config):
jp_list = client.search_jp_by_field(
"tilleggsattributt1", "1"
) # data["sekvensnr_" + service_config.interface]
......@@ -1001,7 +1000,6 @@ def assert_klassering(
beskrivelse: str,
untatt_off: bool,
):
assert klassering is not None
assert klassering.OrdningsprinsippId == ordningsprinsipp_id
assert klassering.OrdningsverdiId == ordningsprinsipp_verdi_id
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment