I'm facing a challenge in updating the URL path using the $location.url service, as it's not reflecting the changes correctly.
For instance, my current URL path is
http://localhost:64621/module/commercial/#/company/98163780-4fa6-426f-8753-e05a67d48e54
and I want to modify it to
http://localhost:64621/module/sales/#/sales-company/98163780-4fa6-426f-8753-e05a67d48e54
The code snippet I am using with $location.url is
$location.url('/module/sales/#/sales-company/98163780-4fa6-426f-8753-e05a67d48e54')
Unfortunately, the redirection isn't functioning as intended. Can you advise me on how I can achieve the desired functionality using the $location service?