4f5ed83 fix(webui): create correct PTR record when navigated from host page

3 files Authored by pvoborni 2 years ago, Committed by frenaud 2 years ago,
    fix(webui): create correct PTR record when navigated from host page
    
    In scenario:
    1. make sure that reverse zone doesn't have the desired PTR record
    2. open host page of the host with matchnig the A record, e.g.: https://server.pvoborni.test/ipa/ui/#/e/host/details/test2.pvoborni.test
    3. click on the "Host name" link, it will bring us to it's DNS record page. E.g., https://server.pvoborni.test/ipa/ui/#/e/dnsrecord/details/pvoborni.test&test2
    ! notice the missing '.' in the URL after zone name (pvoborni.test)
    4. click on the A record , dialog will show up, saying "record not found"
    5. click on the "create DNS record"
    
    PTR record created by Web UI doesn't have trailing '.' (is not fully
    qualified record) even if the DNS zone is.
    
    This patch is fixing the link to the DNS Record page so that the
    page then correctly gets the DNS Zone name and thus creates a correct
    fully qualified PTR record.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=2009114
    https://pagure.io/freeipa/issue/9036
    
    Signed-off-by: Petr Vobornik <pvoborni@redhat.com>
    Reviewed-By: Florence Blanc-Renaud <flo@redhat.com>