- Implemented test scripts for vTiger account retrieval, contact data, and modules. - Created a detailed test suite for the ticket module, covering database schema validation, ticket number generation, prepaid card constraints, and service logic. - Added tests for vTiger field inspection and various queries related to accounts and sales orders. - Introduced SQL migration scripts for the ALSO Cloud Billing foundation, including import jobs, lines, and mapping tables with necessary constraints and indices. - Enhanced workflow columns in the import lines table to support matching and validation timestamps.
26 lines
683 B
Python
26 lines
683 B
Python
"""
|
|
Quick test of bulk customer hourly rate update endpoint
|
|
"""
|
|
import json
|
|
|
|
# Test payload structure
|
|
test_payload = {
|
|
"customer_ids": [1, 2, 3],
|
|
"hourly_rate": 1200.00
|
|
}
|
|
|
|
print("Test payload for POST /api/v1/timetracking/customers/bulk-update-rate:")
|
|
print(json.dumps(test_payload, indent=2))
|
|
|
|
print("\nExpected response:")
|
|
expected_response = {
|
|
"updated": 3,
|
|
"hourly_rate": 1200.00
|
|
}
|
|
print(json.dumps(expected_response, indent=2))
|
|
|
|
print("\nEndpoint ready for testing!")
|
|
print("curl -X POST http://172.16.31.183:8000/api/v1/timetracking/customers/bulk-update-rate \\")
|
|
print(' -H "Content-Type: application/json" \\')
|
|
print(f' -d \'{json.dumps(test_payload)}\'')
|