mbu-dev-shared-components 0.3.0__tar.gz → 0.3.2__tar.gz

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.
Files changed (42) hide show
  1. mbu_dev_shared_components-0.3.2/PKG-INFO +79 -0
  2. mbu_dev_shared_components-0.3.2/README.md +60 -0
  3. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/solteqtand/db_handler.py +15 -10
  4. mbu_dev_shared_components-0.3.2/mbu_dev_shared_components.egg-info/PKG-INFO +79 -0
  5. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/pyproject.toml +1 -1
  6. mbu_dev_shared_components-0.3.0/PKG-INFO +0 -45
  7. mbu_dev_shared_components-0.3.0/README.md +0 -26
  8. mbu_dev_shared_components-0.3.0/mbu_dev_shared_components.egg-info/PKG-INFO +0 -45
  9. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/LICENSE +0 -0
  10. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/getorganized/__init__.py +0 -0
  11. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/getorganized/auth.py +0 -0
  12. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/getorganized/cases.py +0 -0
  13. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/getorganized/contacts.py +0 -0
  14. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/getorganized/documents.py +0 -0
  15. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/getorganized/objects.py +0 -0
  16. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/google/__init__.py +0 -0
  17. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/google/api/__init__.py +0 -0
  18. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/google/api/auth.py +0 -0
  19. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/google/workspace/__init__.py +0 -0
  20. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/google/workspace/alerts.py +0 -0
  21. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/msoffice365/__init__.py +0 -0
  22. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/msoffice365/excel/__init__.py +0 -0
  23. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/msoffice365/excel/excel_reader.py +0 -0
  24. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/msoffice365/sharepoint_api/__init__.py +0 -0
  25. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/msoffice365/sharepoint_api/files.py +0 -0
  26. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/os2forms/__init__.py +0 -0
  27. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/os2forms/documents.py +0 -0
  28. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/os2forms/forms.py +0 -0
  29. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/sap/__init__.py +0 -0
  30. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/sap/create_invoice.py +0 -0
  31. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/solteqtand/__init__.py +0 -0
  32. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/solteqtand/app_handler.py +0 -0
  33. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/utils/__init__.py +0 -0
  34. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/utils/db_stored_procedure_executor.py +0 -0
  35. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/utils/fernet_encryptor.py +0 -0
  36. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/utils/file_handler.py +0 -0
  37. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components/utils/json_handler.py +0 -0
  38. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components.egg-info/SOURCES.txt +0 -0
  39. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components.egg-info/dependency_links.txt +0 -0
  40. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components.egg-info/requires.txt +0 -0
  41. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/mbu_dev_shared_components.egg-info/top_level.txt +0 -0
  42. {mbu_dev_shared_components-0.3.0 → mbu_dev_shared_components-0.3.2}/setup.cfg +0 -0
@@ -0,0 +1,79 @@
1
+ Metadata-Version: 2.2
2
+ Name: mbu_dev_shared_components
3
+ Version: 0.3.2
4
+ Summary: Shared components to use in RPA projects
5
+ Author-email: MBU <rpa@mbu.aarhus.dk>
6
+ Classifier: Programming Language :: Python :: 3
7
+ Classifier: License :: OSI Approved :: MIT License
8
+ Classifier: Operating System :: Microsoft :: Windows
9
+ Requires-Python: >=3.7
10
+ Description-Content-Type: text/markdown
11
+ License-File: LICENSE
12
+ Requires-Dist: openpyxl>=3.1.2
13
+ Requires-Dist: pyodbc>=5.1.0
14
+ Requires-Dist: requests_ntlm>=1.2.0
15
+ Requires-Dist: python-dateutil==2.9.*
16
+ Requires-Dist: cryptography>=43.0.0
17
+ Requires-Dist: office365-rest-python-client
18
+ Requires-Dist: uiautomation
19
+
20
+ # MBU Dev Shared Components
21
+
22
+ [![PyPI version](https://badge.fury.io/py/mbu-dev-shared-components.svg)](https://badge.fury.io/py/mbu-dev-shared-components)
23
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
24
+
25
+ ## Overview
26
+
27
+ MBU Dev Shared Components is a Python library that provides helper modules to streamline Robotic Process Automation (RPA) development.
28
+
29
+ ## Features
30
+
31
+ - **Office365 Integration**:
32
+ - SharePoint
33
+ - Excel
34
+ - **SAP Integration**
35
+ - **Solteq Tand Integration**
36
+ - **Utility Modules**:
37
+ - JSON handling
38
+ - Fernet encryption
39
+
40
+ ## Installation
41
+
42
+ Install the package using pip:
43
+
44
+ ```bash
45
+ pip install mbu-dev-shared-components
46
+
47
+
48
+ # Dynamic SQL Query Builder
49
+
50
+ This repository provides a **generic function** to dynamically build SQL `WHERE` clauses using filters. It supports:
51
+
52
+ - **Equality (`=`)**
53
+ - **LIKE (`%search%`)**
54
+ - **IN (`column IN (value1, value2, ...)`)**
55
+ - **BETWEEN (`column BETWEEN value1 AND value2`)**
56
+ - **AND & OR Conditions**
57
+ - **ORDER BY (`ORDER BY column ASC/DESC`)**
58
+
59
+ ---
60
+
61
+ ## 📌 How to Use the `check_if_event_exists` Function
62
+
63
+ | **Usage Type** | **Example Function Call** | **Generated SQL WHERE Clause** |
64
+ |--------------|--------------------------------------|--------------------------------------------|
65
+ | **1. Basic Equality Filtering** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890", "e.event_name": "Some Clinic"}) ``` | `WHERE 1=1 AND p.cpr = ? AND e.event_name = ?` |
66
+ | **2. LIKE Filtering** (Partial Match) | ```python self.check_if_event_exists(filters={"e.event_name": "%Clinic%"}) ``` | `WHERE 1=1 AND e.event_name LIKE ?` |
67
+ | **3. IN Filtering** (Multiple Values) | ```python self.check_if_event_exists(filters={"e.event_message": ["Scheduled", "Pending"]}) ``` | `WHERE 1=1 AND e.event_message IN (?, ?)` |
68
+ | **4. BETWEEN Filtering** (Range) | ```python self.check_if_event_exists(filters={"e.eventTriggerDate": ("2024-01-01", "2024-12-31")}) ``` | `WHERE 1=1 AND e.eventTriggerDate BETWEEN ? AND ?` |
69
+ | **5. Multiple AND Conditions** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890", "e.event_message": "Scheduled", "e.archived": 0}) ``` | `WHERE 1=1 AND p.cpr = ? AND e.event_message = ? AND e.archived = ?` |
70
+ | **6. OR Conditions (Single Group)** | ```python self.check_if_event_exists(or_filters=[{"e.event_name": "Clinic A"}, {"e.event_name": "Clinic B"}]) ``` | `WHERE 1=1 AND (e.event_name = ? OR e.event_name = ?)` |
71
+ | **7. OR with Multiple Conditions** | ```python self.check_if_event_exists(or_filters=[{"e.event_name": "Clinic A", "e.event_message": "Scheduled"}, {"e.event_name": "Clinic B"}]) ``` | `WHERE 1=1 AND ((e.event_name = ? AND e.event_message = ?) OR (e.event_name = ?))` |
72
+ | **8. AND & OR Combined** | ```python self.check_if_event_exists(filters={"e.archived": 0}, or_filters=[{"e.event_name": "Clinic A"}, {"e.event_name": "Clinic B"}]) ``` | `WHERE 1=1 AND e.archived = ? AND (e.event_name = ? OR e.event_name = ?)` |
73
+ | **9. LIKE with OR** | ```python self.check_if_event_exists(or_filters=[{"e.event_message": "%Scheduled%"}, {"e.event_message": "%Pending%"}]) ``` | `WHERE 1=1 AND (e.event_message LIKE ? OR e.event_message LIKE ?)` |
74
+ | **10. Complex AND, OR, LIKE, IN Combined** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890", "e.event_message": ["Scheduled", "Pending"]}, or_filters=[{"e.event_name": "%Hospital%"}, {"e.event_name": "%Clinic%"}]) ``` | `WHERE 1=1 AND p.cpr = ? AND e.event_message IN (?, ?) AND (e.event_name LIKE ? OR e.event_name LIKE ?)` |
75
+ | **11. ORDER BY (Ascending)** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890"}, order_by="e.timestamp", order_direction="ASC") ``` | `WHERE 1=1 AND p.cpr = ? ORDER BY e.timestamp ASC` |
76
+ | **12. ORDER BY (Descending)** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890"}, order_by="e.timestamp", order_direction="DESC") ``` | `WHERE 1=1 AND p.cpr = ? ORDER BY e.timestamp DESC` |
77
+ | **13. ORDER BY with Multiple Filters** | ```python self.check_if_event_exists(filters={"e.event_message": "Scheduled"}, order_by="e.eventTriggerDate", order_direction="DESC") ``` | `WHERE 1=1 AND e.event_message = ? ORDER BY e.eventTriggerDate DESC` |
78
+
79
+ ---
@@ -0,0 +1,60 @@
1
+ # MBU Dev Shared Components
2
+
3
+ [![PyPI version](https://badge.fury.io/py/mbu-dev-shared-components.svg)](https://badge.fury.io/py/mbu-dev-shared-components)
4
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
5
+
6
+ ## Overview
7
+
8
+ MBU Dev Shared Components is a Python library that provides helper modules to streamline Robotic Process Automation (RPA) development.
9
+
10
+ ## Features
11
+
12
+ - **Office365 Integration**:
13
+ - SharePoint
14
+ - Excel
15
+ - **SAP Integration**
16
+ - **Solteq Tand Integration**
17
+ - **Utility Modules**:
18
+ - JSON handling
19
+ - Fernet encryption
20
+
21
+ ## Installation
22
+
23
+ Install the package using pip:
24
+
25
+ ```bash
26
+ pip install mbu-dev-shared-components
27
+
28
+
29
+ # Dynamic SQL Query Builder
30
+
31
+ This repository provides a **generic function** to dynamically build SQL `WHERE` clauses using filters. It supports:
32
+
33
+ - **Equality (`=`)**
34
+ - **LIKE (`%search%`)**
35
+ - **IN (`column IN (value1, value2, ...)`)**
36
+ - **BETWEEN (`column BETWEEN value1 AND value2`)**
37
+ - **AND & OR Conditions**
38
+ - **ORDER BY (`ORDER BY column ASC/DESC`)**
39
+
40
+ ---
41
+
42
+ ## 📌 How to Use the `check_if_event_exists` Function
43
+
44
+ | **Usage Type** | **Example Function Call** | **Generated SQL WHERE Clause** |
45
+ |--------------|--------------------------------------|--------------------------------------------|
46
+ | **1. Basic Equality Filtering** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890", "e.event_name": "Some Clinic"}) ``` | `WHERE 1=1 AND p.cpr = ? AND e.event_name = ?` |
47
+ | **2. LIKE Filtering** (Partial Match) | ```python self.check_if_event_exists(filters={"e.event_name": "%Clinic%"}) ``` | `WHERE 1=1 AND e.event_name LIKE ?` |
48
+ | **3. IN Filtering** (Multiple Values) | ```python self.check_if_event_exists(filters={"e.event_message": ["Scheduled", "Pending"]}) ``` | `WHERE 1=1 AND e.event_message IN (?, ?)` |
49
+ | **4. BETWEEN Filtering** (Range) | ```python self.check_if_event_exists(filters={"e.eventTriggerDate": ("2024-01-01", "2024-12-31")}) ``` | `WHERE 1=1 AND e.eventTriggerDate BETWEEN ? AND ?` |
50
+ | **5. Multiple AND Conditions** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890", "e.event_message": "Scheduled", "e.archived": 0}) ``` | `WHERE 1=1 AND p.cpr = ? AND e.event_message = ? AND e.archived = ?` |
51
+ | **6. OR Conditions (Single Group)** | ```python self.check_if_event_exists(or_filters=[{"e.event_name": "Clinic A"}, {"e.event_name": "Clinic B"}]) ``` | `WHERE 1=1 AND (e.event_name = ? OR e.event_name = ?)` |
52
+ | **7. OR with Multiple Conditions** | ```python self.check_if_event_exists(or_filters=[{"e.event_name": "Clinic A", "e.event_message": "Scheduled"}, {"e.event_name": "Clinic B"}]) ``` | `WHERE 1=1 AND ((e.event_name = ? AND e.event_message = ?) OR (e.event_name = ?))` |
53
+ | **8. AND & OR Combined** | ```python self.check_if_event_exists(filters={"e.archived": 0}, or_filters=[{"e.event_name": "Clinic A"}, {"e.event_name": "Clinic B"}]) ``` | `WHERE 1=1 AND e.archived = ? AND (e.event_name = ? OR e.event_name = ?)` |
54
+ | **9. LIKE with OR** | ```python self.check_if_event_exists(or_filters=[{"e.event_message": "%Scheduled%"}, {"e.event_message": "%Pending%"}]) ``` | `WHERE 1=1 AND (e.event_message LIKE ? OR e.event_message LIKE ?)` |
55
+ | **10. Complex AND, OR, LIKE, IN Combined** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890", "e.event_message": ["Scheduled", "Pending"]}, or_filters=[{"e.event_name": "%Hospital%"}, {"e.event_name": "%Clinic%"}]) ``` | `WHERE 1=1 AND p.cpr = ? AND e.event_message IN (?, ?) AND (e.event_name LIKE ? OR e.event_name LIKE ?)` |
56
+ | **11. ORDER BY (Ascending)** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890"}, order_by="e.timestamp", order_direction="ASC") ``` | `WHERE 1=1 AND p.cpr = ? ORDER BY e.timestamp ASC` |
57
+ | **12. ORDER BY (Descending)** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890"}, order_by="e.timestamp", order_direction="DESC") ``` | `WHERE 1=1 AND p.cpr = ? ORDER BY e.timestamp DESC` |
58
+ | **13. ORDER BY with Multiple Filters** | ```python self.check_if_event_exists(filters={"e.event_message": "Scheduled"}, order_by="e.eventTriggerDate", order_direction="DESC") ``` | `WHERE 1=1 AND e.event_message = ? ORDER BY e.eventTriggerDate DESC` |
59
+
60
+ ---
@@ -38,7 +38,7 @@ class SolteqTandDatabase:
38
38
 
39
39
  return result
40
40
 
41
- def _construct_sql_statement(self, base_query, filters=None, or_filters=None): # noqa
41
+ def _construct_sql_statement(self, base_query, filters=None, or_filters=None, order_by=None, order_direction="ASC"): # noqa
42
42
  """
43
43
  Dynamically constructs a SQL query by applying filters.
44
44
 
@@ -100,6 +100,11 @@ class SolteqTandDatabase:
100
100
  if or_clauses:
101
101
  base_query += " AND (" + " OR ".join(or_clauses) + ")"
102
102
 
103
+ # Adding ORDER BY clause
104
+ if order_by:
105
+ order_direction = "ASC" if order_direction.upper() not in ["ASC", "DESC"] else order_direction.upper()
106
+ base_query += f" ORDER BY {order_by} {order_direction}"
107
+
103
108
  return base_query, params
104
109
 
105
110
  def get_list_of_documents(self, filters=None, or_filters=None):
@@ -166,15 +171,15 @@ class SolteqTandDatabase:
166
171
  list: A list of external dentist records.
167
172
  """
168
173
  base_query = """
169
- SELECT [patientId]
170
- ,[cpr]
171
- ,[privateClinicId]
172
- ,[c.contractorId]
173
- ,[c.isPrimary]
174
- ,[c.name]
175
- ,[c.streetAddress]
176
- ,[c.zip]
177
- ,[c.phoneNumber]
174
+ SELECT p.[patientId]
175
+ ,p.[cpr]
176
+ ,p.[privateClinicId]
177
+ ,c.[contractorId]
178
+ ,c.[isPrimary]
179
+ ,c.[name]
180
+ ,c.[streetAddress]
181
+ ,c.[zip]
182
+ ,c.[phoneNumber]
178
183
  FROM [tmtdata_prod].[dbo].[PATIENT] p
179
184
  JOIN [CLINIC] c on c.clinicId = p.privateClinicId
180
185
  WHERE 1=1
@@ -0,0 +1,79 @@
1
+ Metadata-Version: 2.2
2
+ Name: mbu_dev_shared_components
3
+ Version: 0.3.2
4
+ Summary: Shared components to use in RPA projects
5
+ Author-email: MBU <rpa@mbu.aarhus.dk>
6
+ Classifier: Programming Language :: Python :: 3
7
+ Classifier: License :: OSI Approved :: MIT License
8
+ Classifier: Operating System :: Microsoft :: Windows
9
+ Requires-Python: >=3.7
10
+ Description-Content-Type: text/markdown
11
+ License-File: LICENSE
12
+ Requires-Dist: openpyxl>=3.1.2
13
+ Requires-Dist: pyodbc>=5.1.0
14
+ Requires-Dist: requests_ntlm>=1.2.0
15
+ Requires-Dist: python-dateutil==2.9.*
16
+ Requires-Dist: cryptography>=43.0.0
17
+ Requires-Dist: office365-rest-python-client
18
+ Requires-Dist: uiautomation
19
+
20
+ # MBU Dev Shared Components
21
+
22
+ [![PyPI version](https://badge.fury.io/py/mbu-dev-shared-components.svg)](https://badge.fury.io/py/mbu-dev-shared-components)
23
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
24
+
25
+ ## Overview
26
+
27
+ MBU Dev Shared Components is a Python library that provides helper modules to streamline Robotic Process Automation (RPA) development.
28
+
29
+ ## Features
30
+
31
+ - **Office365 Integration**:
32
+ - SharePoint
33
+ - Excel
34
+ - **SAP Integration**
35
+ - **Solteq Tand Integration**
36
+ - **Utility Modules**:
37
+ - JSON handling
38
+ - Fernet encryption
39
+
40
+ ## Installation
41
+
42
+ Install the package using pip:
43
+
44
+ ```bash
45
+ pip install mbu-dev-shared-components
46
+
47
+
48
+ # Dynamic SQL Query Builder
49
+
50
+ This repository provides a **generic function** to dynamically build SQL `WHERE` clauses using filters. It supports:
51
+
52
+ - **Equality (`=`)**
53
+ - **LIKE (`%search%`)**
54
+ - **IN (`column IN (value1, value2, ...)`)**
55
+ - **BETWEEN (`column BETWEEN value1 AND value2`)**
56
+ - **AND & OR Conditions**
57
+ - **ORDER BY (`ORDER BY column ASC/DESC`)**
58
+
59
+ ---
60
+
61
+ ## 📌 How to Use the `check_if_event_exists` Function
62
+
63
+ | **Usage Type** | **Example Function Call** | **Generated SQL WHERE Clause** |
64
+ |--------------|--------------------------------------|--------------------------------------------|
65
+ | **1. Basic Equality Filtering** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890", "e.event_name": "Some Clinic"}) ``` | `WHERE 1=1 AND p.cpr = ? AND e.event_name = ?` |
66
+ | **2. LIKE Filtering** (Partial Match) | ```python self.check_if_event_exists(filters={"e.event_name": "%Clinic%"}) ``` | `WHERE 1=1 AND e.event_name LIKE ?` |
67
+ | **3. IN Filtering** (Multiple Values) | ```python self.check_if_event_exists(filters={"e.event_message": ["Scheduled", "Pending"]}) ``` | `WHERE 1=1 AND e.event_message IN (?, ?)` |
68
+ | **4. BETWEEN Filtering** (Range) | ```python self.check_if_event_exists(filters={"e.eventTriggerDate": ("2024-01-01", "2024-12-31")}) ``` | `WHERE 1=1 AND e.eventTriggerDate BETWEEN ? AND ?` |
69
+ | **5. Multiple AND Conditions** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890", "e.event_message": "Scheduled", "e.archived": 0}) ``` | `WHERE 1=1 AND p.cpr = ? AND e.event_message = ? AND e.archived = ?` |
70
+ | **6. OR Conditions (Single Group)** | ```python self.check_if_event_exists(or_filters=[{"e.event_name": "Clinic A"}, {"e.event_name": "Clinic B"}]) ``` | `WHERE 1=1 AND (e.event_name = ? OR e.event_name = ?)` |
71
+ | **7. OR with Multiple Conditions** | ```python self.check_if_event_exists(or_filters=[{"e.event_name": "Clinic A", "e.event_message": "Scheduled"}, {"e.event_name": "Clinic B"}]) ``` | `WHERE 1=1 AND ((e.event_name = ? AND e.event_message = ?) OR (e.event_name = ?))` |
72
+ | **8. AND & OR Combined** | ```python self.check_if_event_exists(filters={"e.archived": 0}, or_filters=[{"e.event_name": "Clinic A"}, {"e.event_name": "Clinic B"}]) ``` | `WHERE 1=1 AND e.archived = ? AND (e.event_name = ? OR e.event_name = ?)` |
73
+ | **9. LIKE with OR** | ```python self.check_if_event_exists(or_filters=[{"e.event_message": "%Scheduled%"}, {"e.event_message": "%Pending%"}]) ``` | `WHERE 1=1 AND (e.event_message LIKE ? OR e.event_message LIKE ?)` |
74
+ | **10. Complex AND, OR, LIKE, IN Combined** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890", "e.event_message": ["Scheduled", "Pending"]}, or_filters=[{"e.event_name": "%Hospital%"}, {"e.event_name": "%Clinic%"}]) ``` | `WHERE 1=1 AND p.cpr = ? AND e.event_message IN (?, ?) AND (e.event_name LIKE ? OR e.event_name LIKE ?)` |
75
+ | **11. ORDER BY (Ascending)** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890"}, order_by="e.timestamp", order_direction="ASC") ``` | `WHERE 1=1 AND p.cpr = ? ORDER BY e.timestamp ASC` |
76
+ | **12. ORDER BY (Descending)** | ```python self.check_if_event_exists(filters={"p.cpr": "123456-7890"}, order_by="e.timestamp", order_direction="DESC") ``` | `WHERE 1=1 AND p.cpr = ? ORDER BY e.timestamp DESC` |
77
+ | **13. ORDER BY with Multiple Filters** | ```python self.check_if_event_exists(filters={"e.event_message": "Scheduled"}, order_by="e.eventTriggerDate", order_direction="DESC") ``` | `WHERE 1=1 AND e.event_message = ? ORDER BY e.eventTriggerDate DESC` |
78
+
79
+ ---
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "mbu_dev_shared_components"
7
- version = "0.3.0" # Specify the version manually here
7
+ version = "0.3.2" # Specify the version manually here
8
8
  authors = [
9
9
  { name="MBU", email="rpa@mbu.aarhus.dk" },
10
10
  ]
@@ -1,45 +0,0 @@
1
- Metadata-Version: 2.2
2
- Name: mbu_dev_shared_components
3
- Version: 0.3.0
4
- Summary: Shared components to use in RPA projects
5
- Author-email: MBU <rpa@mbu.aarhus.dk>
6
- Classifier: Programming Language :: Python :: 3
7
- Classifier: License :: OSI Approved :: MIT License
8
- Classifier: Operating System :: Microsoft :: Windows
9
- Requires-Python: >=3.7
10
- Description-Content-Type: text/markdown
11
- License-File: LICENSE
12
- Requires-Dist: openpyxl>=3.1.2
13
- Requires-Dist: pyodbc>=5.1.0
14
- Requires-Dist: requests_ntlm>=1.2.0
15
- Requires-Dist: python-dateutil==2.9.*
16
- Requires-Dist: cryptography>=43.0.0
17
- Requires-Dist: office365-rest-python-client
18
- Requires-Dist: uiautomation
19
-
20
- # MBU Dev Shared Components
21
-
22
- [![PyPI version](https://badge.fury.io/py/mbu-dev-shared-components.svg)](https://badge.fury.io/py/mbu-dev-shared-components)
23
- [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
24
-
25
- ## Overview
26
-
27
- MBU Dev Shared Components is a Python library that provides helper modules to streamline Robotic Process Automation (RPA) development.
28
-
29
- ## Features
30
-
31
- - **Office365 Integration**:
32
- - SharePoint
33
- - Excel
34
- - **SAP Integration**
35
- - **Solteq Tand Integration**
36
- - **Utility Modules**:
37
- - JSON handling
38
- - Fernet encryption
39
-
40
- ## Installation
41
-
42
- Install the package using pip:
43
-
44
- ```bash
45
- pip install mbu-dev-shared-components
@@ -1,26 +0,0 @@
1
- # MBU Dev Shared Components
2
-
3
- [![PyPI version](https://badge.fury.io/py/mbu-dev-shared-components.svg)](https://badge.fury.io/py/mbu-dev-shared-components)
4
- [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
5
-
6
- ## Overview
7
-
8
- MBU Dev Shared Components is a Python library that provides helper modules to streamline Robotic Process Automation (RPA) development.
9
-
10
- ## Features
11
-
12
- - **Office365 Integration**:
13
- - SharePoint
14
- - Excel
15
- - **SAP Integration**
16
- - **Solteq Tand Integration**
17
- - **Utility Modules**:
18
- - JSON handling
19
- - Fernet encryption
20
-
21
- ## Installation
22
-
23
- Install the package using pip:
24
-
25
- ```bash
26
- pip install mbu-dev-shared-components
@@ -1,45 +0,0 @@
1
- Metadata-Version: 2.2
2
- Name: mbu_dev_shared_components
3
- Version: 0.3.0
4
- Summary: Shared components to use in RPA projects
5
- Author-email: MBU <rpa@mbu.aarhus.dk>
6
- Classifier: Programming Language :: Python :: 3
7
- Classifier: License :: OSI Approved :: MIT License
8
- Classifier: Operating System :: Microsoft :: Windows
9
- Requires-Python: >=3.7
10
- Description-Content-Type: text/markdown
11
- License-File: LICENSE
12
- Requires-Dist: openpyxl>=3.1.2
13
- Requires-Dist: pyodbc>=5.1.0
14
- Requires-Dist: requests_ntlm>=1.2.0
15
- Requires-Dist: python-dateutil==2.9.*
16
- Requires-Dist: cryptography>=43.0.0
17
- Requires-Dist: office365-rest-python-client
18
- Requires-Dist: uiautomation
19
-
20
- # MBU Dev Shared Components
21
-
22
- [![PyPI version](https://badge.fury.io/py/mbu-dev-shared-components.svg)](https://badge.fury.io/py/mbu-dev-shared-components)
23
- [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
24
-
25
- ## Overview
26
-
27
- MBU Dev Shared Components is a Python library that provides helper modules to streamline Robotic Process Automation (RPA) development.
28
-
29
- ## Features
30
-
31
- - **Office365 Integration**:
32
- - SharePoint
33
- - Excel
34
- - **SAP Integration**
35
- - **Solteq Tand Integration**
36
- - **Utility Modules**:
37
- - JSON handling
38
- - Fernet encryption
39
-
40
- ## Installation
41
-
42
- Install the package using pip:
43
-
44
- ```bash
45
- pip install mbu-dev-shared-components