Frappe ui - Vue Js

Hi @buildwithhussain @netchampfaris
I tried bench add-frapp-ui. it’s installed and its working. I replaced my site name with localhost. My site name is practice.com.
I tried with http://practice.com:8080
this url is not working? But localhost:8080 is working in that i go this error how to solve?

in console:
caught (in promise) TypeError: Cannot read properties of undefined (reading ‘exc_type’)
at frappeRequest.js:59:31
at Generator.next ()
at fulfilled (chunk-C5ROOZUP.js?v=62fbdc61:45:24)

while clicking that frappeRequest.js

 try {
      error = JSON.parse(errorResponse)
      // eslint-disable-next-line no-empty
    } catch (e) {}
    let errorParts = [
      [options.url, error.exc_type, error._error_message]
        .filter(Boolean)
        .join(' '),
    ]

How to solve and run with our site name. Thankyou

I tried this code

For this i got these errors

i am following your last live session code. i am trying on that. Help to solve these. Thankyou bro

first i installed this bench get-app GitHub - NagariaHussain/doppio: A Frappe app (CLI) to magically setup single page applications on your custom Frappe apps.
and this bench add-frappe-ui

first i tried installing bench add-frappe ui directly it tells command not found then i followed this

  1. bench get-app GitHub - NagariaHussain/doppio: A Frappe app (CLI) to magically setup single page applications on your custom Frappe apps.
  2. bench add-frappe-ui

In vscode

Is there any error message?

Do you use bench use to set a current site? You can check if your sites folder has a file named current_site.txt.

Hi,
my currentsite.txt is set to practice.com
while installing bench add-frappe-ui no error, only warn’s are there

I am using aws server for frappe-instance my domain name is turiya.in for this scenario
can i use domain name or i should replace with my site name ?

I removed front end folder and tried again the first ping request is working. I tried with my doctype

This error came
Traceback (most recent call last):
File “apps/frappe/frappe/app.py”, line 53, in application
response = frappe.api.handle()
File “apps/frappe/frappe/api.py”, line 53, in handle
return _RESTAPIHandler(call, doctype, name).get_response()
File “apps/frappe/frappe/api.py”, line 69, in get_response
return self.handle_method()
File “apps/frappe/frappe/api.py”, line 79, in handle_method
return frappe.handler.handle()
File “apps/frappe/frappe/handler.py”, line 48, in handle
data = execute_cmd(cmd)
File “apps/frappe/frappe/handler.py”, line 83, in execute_cmd
is_whitelisted(method)
File “apps/frappe/frappe/init.py”, line 779, in is_whitelisted
throw(msg, PermissionError, title=“Method Not Allowed”)
File “apps/frappe/frappe/init.py”, line 523, in throw
msgprint(
File “apps/frappe/frappe/init.py”, line 491, in msgprint
_raise_exception()
File “apps/frappe/frappe/init.py”, line 440, in _raise_exception
raise raise_exception(msg)
frappe.exceptions.PermissionError:

You are not permitted to access this resource.Function frappe.client.get_list is not whitelisted.

In vscode,
ahead of ‘frappe-ui’ three dots are there while i move the cursor to that point i got these whether it’s an error?

Could not find a declaration file for module ‘frappe-ui’. ‘/home/ubuntu/frappe-practice/apps/practice_app/frontend/node_modules/frappe-ui/src/index.js’ implicitly has an ‘any’ type.
Try npm i --save-dev @types/frappe-ui if it exists or add a new declaration (.d.ts) file containing declare module 'frappe-ui';Vetur(7016)
Could not find a declaration file for module ‘frappe-ui’. ‘/home/ubuntu/frappe-practice/apps/practice_app/frontend/node_modules/frappe-ui/src/index.js’ implicitly has an ‘any’ type.
If the ‘frappe-ui’ package actually exposes this module, try adding a new declaration (.d.ts) file containing declare module 'frappe-ui';ts(7016)
module “/home/ubuntu/frappe-practice/apps/practice_app/frontend/node_modules/frappe-ui/src/index”
No quick fixes available

This causes problems a lot of times. Delete the current_site.txt (keep the bench in multi-tenant mode).

For getting it working on a production, you will need to do some extra steps, let me add them to README.

You can ignore the VSCode warning.

Hi sir,
Thankyou for your response. I will wait for the update.

how to solve this permission error sir. It should be work in 8080 port right? If i do any action means my frappe desk pop up with the message you are not permitted it again ask me to login.

Uncaught (in promise) Error: /api/method/frappe.client.insert PermissionError
at frappeRequest.js:71:17
at Generator.next ()
at fulfilled (chunk-C5ROOZUP.js?v=6c831050:45:24)

After clicking add action

I got this pop up and again i need to login to access my site

Please help sir thankyou

This is not related to frappe-ui. Might be coming from customisations or custom app.

Permission error sir?

I have released a new version of Doppio that will automatically configure the prod setup. You can either re-setup or check the change log for what it really adds:

  1. build command in spa/package.json
  2. routing rule in hooks.py

You can also check apps like Gameplan or Press to see how they are configured.

2 Likes