rpa-erpnext 1.0.8__py3-none-any.whl → 1.0.9__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
RPA/ERPNext.py CHANGED
@@ -794,7 +794,12 @@ class ERPNextLibrary:
794
794
  # ===========================================================
795
795
 
796
796
  @keyword("Create Purchase Order From Quotation")
797
- def create_purchase_order_from_quotation(self, quotation_name: str):
797
+
798
+ def create_purchase_order_from_quotation(self, quotation_name):
799
+ # Auto-detect if quotation_name is a dict (from previous keyword return)
800
+ if isinstance(quotation_name, dict):
801
+ quotation_name = quotation_name.get("name")
802
+
798
803
  sq_doc = self.get_doc("Supplier Quotation", quotation_name)
799
804
  supplier = sq_doc["supplier"]
800
805
  company = sq_doc["company"]
@@ -804,13 +809,18 @@ class ERPNextLibrary:
804
809
 
805
810
  items = []
806
811
  for d in sq_doc["items"]:
812
+ # Ensure proper types
813
+ item_code = d["item_code"]
814
+ if isinstance(item_code, list):
815
+ item_code = item_code[0] if item_code else ""
816
+
807
817
  items.append({
808
- "item_code": d["item_code"],
809
- "qty": d["qty"],
810
- "rate": d["rate"],
818
+ "item_code": str(item_code),
819
+ "qty": float(d["qty"]),
820
+ "rate": float(d["rate"]),
811
821
  "schedule_date": "2026-02-28",
812
822
  "warehouse": f"Stores - EDU",
813
- "uom": d.get("uom", "Nos"),
823
+ "uom": str(d.get("uom", "Nos")),
814
824
  "conversion_factor": 1.0
815
825
  })
816
826
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rpa-erpnext
3
- Version: 1.0.8
3
+ Version: 1.0.9
4
4
  Summary: Robot Framework library for automating ERPNext using REST API
5
5
  Author-email: Your Name <youremail@example.com>
6
6
  License: MIT
@@ -0,0 +1,7 @@
1
+ RPA/ERPNext.py,sha256=M_x3eCGqW-ZlRBtZasxqmCaTSVaO3aKaQb9Ybr4NVLA,30262
2
+ RPA/__init__.py,sha256=doHeY54VPWzBDnkSMGvGGSYfkpxt4dFXAV8YOi-Ebig,110
3
+ rpa_erpnext-1.0.9.dist-info/licenses/LICENSE,sha256=sexHbU6pNlqsmC_TQZJLdZ59qC_Bym7mQ0HrNeHHQ3Y,1063
4
+ rpa_erpnext-1.0.9.dist-info/METADATA,sha256=Fb0rCMIgj_LHhmf3XJok93VVbJyRx3evDW9VBUwK5ZQ,800
5
+ rpa_erpnext-1.0.9.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
6
+ rpa_erpnext-1.0.9.dist-info/top_level.txt,sha256=s4yaEXbcdPUcIyAxSvrLKKIMD62cqoNPsOGmdx94U5k,4
7
+ rpa_erpnext-1.0.9.dist-info/RECORD,,
@@ -1,7 +0,0 @@
1
- RPA/ERPNext.py,sha256=0Uxzdl2mh51dZ-WKJfJcYUQsAz9TmzEjAdFJC9RnI4E,29856
2
- RPA/__init__.py,sha256=doHeY54VPWzBDnkSMGvGGSYfkpxt4dFXAV8YOi-Ebig,110
3
- rpa_erpnext-1.0.8.dist-info/licenses/LICENSE,sha256=sexHbU6pNlqsmC_TQZJLdZ59qC_Bym7mQ0HrNeHHQ3Y,1063
4
- rpa_erpnext-1.0.8.dist-info/METADATA,sha256=NQJ8PrfnCegYUHFheDLLwtwtIa8--vAV3KONuoL8VFI,800
5
- rpa_erpnext-1.0.8.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
6
- rpa_erpnext-1.0.8.dist-info/top_level.txt,sha256=s4yaEXbcdPUcIyAxSvrLKKIMD62cqoNPsOGmdx94U5k,4
7
- rpa_erpnext-1.0.8.dist-info/RECORD,,