Guest User

Untitled

a guest
Jan 12th, 2022
10
3 days
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ### App Versions
  2. ```
  3. {
  4. "erpnext": "13.17.0",
  5. "frappe": "13.17.1",
  6. }
  7. ```
  8. ### Route
  9. ```
  10. List/prod_6/List
  11. ```
  12. ### Trackeback
  13. ```
  14. data:::[[{'id': '123', 'da': 'snhg', 'price': '111', 'control': '1223'}, {'id': '456', 'da': 'asdasd', 'price': '222', 'control': '1223'}]]
  15. keys:::[{'id': '123', 'da': 'snhg', 'price': '111', 'control': '1223'}, {'id': '456', 'da': 'asdasd', 'price': '222', 'control': '1223'}]
  16. row:::[{'id': '123', 'da': 'snhg', 'price': '111', 'control': '1223'}, {'id': '456', 'da': 'asdasd', 'price': '222', 'control': '1223'}]
  17. key:::{'id': '123', 'da': 'snhg', 'price': '111', 'control': '1223'}
  18. Traceback (most recent call last):
  19. File "apps/frappe/frappe/app.py", line 68, in application
  20. response = frappe.api.handle()
  21. File "apps/frappe/frappe/api.py", line 55, in handle
  22. return frappe.handler.handle()
  23. File "apps/frappe/frappe/handler.py", line 31, in handle
  24. data = execute_cmd(cmd)
  25. File "apps/frappe/frappe/handler.py", line 67, in execute_cmd
  26. return frappe.call(method, **frappe.form_dict)
  27. File "apps/frappe/frappe/__init__.py", line 1208, in call
  28. return fn(*args, **newargs)
  29. File "apps/frappe/frappe/__init__.py", line 624, in wrapper_fn
  30. retval = fn(*args, **get_newargs(fn, kwargs))
  31. File "apps/frappe/frappe/desk/reportview.py", line 26, in get
  32. data = compress(controller(args.doctype).get_list(args))
  33. File "apps/frappe/frappe/desk/reportview.py", line 238, in compress
  34. new_row.append(row.get(key))
  35. AttributeError: 'list' object has no attribute 'get'
  36.  
  37. ```
  38. ### Request Data
  39. ```
  40. {
  41. "type": "POST",
  42. "args": {
  43. "doctype": "prod_6",
  44. "fields": "[\"`tabprod_6`.`name`\",\"`tabprod_6`.`owner`\",\"`tabprod_6`.`creation`\",\"`tabprod_6`.`modified`\",\"`tabprod_6`.`modified_by`\",\"`tabprod_6`.`_user_tags`\",\"`tabprod_6`.`_comments`\",\"`tabprod_6`.`_assign`\",\"`tabprod_6`.`_liked_by`\",\"`tabprod_6`.`docstatus`\",\"`tabprod_6`.`parent`\",\"`tabprod_6`.`parenttype`\",\"`tabprod_6`.`parentfield`\",\"`tabprod_6`.`idx`\"]",
  45. "filters": "[]",
  46. "order_by": "`tabprod_6`.`modified` desc",
  47. "start": 0,
  48. "page_length": 20,
  49. "view": "List",
  50. "group_by": "`tabprod_6`.`name`",
  51. "with_comment_count": true
  52. },
  53. "freeze": false,
  54. "freeze_message": "Loading...",
  55. "headers": {},
  56. "error_handlers": {},
  57. "url": "/api/method/frappe.desk.reportview.get"
  58. }
  59. ```
  60. ### Response Data
  61. ```
  62. {
  63. "exception": "AttributeError: 'list' object has no attribute 'get'"
  64. }
  65. ```
RAW Paste Data