frappe-ui icon indicating copy to clipboard operation
frappe-ui copied to clipboard

Added URL Argument to Call method

Open FeezyHendrix opened this issue 11 months ago • 1 comments

Problem: The current call method is limited to using a fixed base URL. It does not support sending requests to a different hostname or port, which restricts its flexibility in multi-environment or distributed system setups.

Solution: This update introduces the url key as an optional parameter in the call method. When provided, the process constructs the request URL using the specified hostname and port. If the URL key is omitted, the method defaults to the existing base URL.

Usage Example:

call('example.method', {
  url: 'http://localhost:3001'
});

This resolves the request to:

http://localhost:3001/api/method/example.method

FeezyHendrix avatar Dec 13 '24 10:12 FeezyHendrix

Deploy Preview for frappeui ready!

Name Link
Latest commit 00153c337a8c725c3dacc57693d286da3480eec5
Latest deploy log https://app.netlify.com/sites/frappeui/deploys/675c06b53d3ea00008ac44f1
Deploy Preview https://deploy-preview-239--frappeui.netlify.app
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

netlify[bot] avatar Dec 13 '24 10:12 netlify[bot]

Looks like untested PR

surajshetty3416 avatar Nov 10 '25 08:11 surajshetty3416