update Implement standardized documentation for all database modules, including purpose, rules, and requirements for each CRUD operation; refactor existing comments to follow new documentation standard
```
This commit is contained in:
2025-05-17 10:02:05 +00:00
parent b8309596be
commit 59cdf7257b
135 changed files with 1207 additions and 37 deletions

View File

@@ -1,6 +1,11 @@
// api method for crate customer record
// PURPOSE:
// Create new customer record
// REQ0006
//
// RULES:
// TBA
// error handled by caller
// contain definition to collection only
//
import { pb } from '@/lib/pb';
import { COL_CUSTOMERS } from '@/constants';
import type { CreateFormProps } from '@/components/dashboard/customer/type.d';

View File

@@ -1,3 +1,12 @@
// PURPOSE:
// Delete customer record
// REQ0006
//
// RULES:
// error handled by caller
// contain definition to collection only
//
import { pb } from '@/lib/pb';
import { COL_CUSTOMERS } from '@/constants';

View File

@@ -1,3 +1,12 @@
// PURPOSE:
// Get count of active customers
// REQ0006
//
// RULES:
// error handled by caller
// contain definition to collection only
//
import { COL_USER_METAS } from '@/constants';
import { pb } from '@/lib/pb';

View File

@@ -1,3 +1,12 @@
// PURPOSE:
// Get all customer records
// REQ0006
//
// RULES:
// error handled by caller
// contain definition to collection only
//
import { pb } from '@/lib/pb';
import { COL_CUSTOMERS } from '@/constants';
import type { RecordModel } from 'pocketbase';

View File

@@ -1,3 +1,12 @@
// PURPOSE:
// Get total count of all customers
// REQ0006
//
// RULES:
// error handled by caller
// contain definition to collection only
//
import { pb } from '@/lib/pb';
import { COL_CUSTOMERS } from '@/constants';

View File

@@ -1,3 +1,12 @@
// PURPOSE:
// Get count of blocked customers
// REQ0006
//
// RULES:
// error handled by caller
// contain definition to collection only
//
import { COL_USER_METAS } from '@/constants';
import { pb } from '@/lib/pb';

View File

@@ -1,3 +1,12 @@
// PURPOSE:
// Get customer record by ID
// REQ0006
//
// RULES:
// error handled by caller
// contain definition to collection only
//
import { pb } from '@/lib/pb';
import { COL_CUSTOMERS } from '@/constants';
import type { RecordModel } from 'pocketbase';

View File

@@ -1,3 +1,12 @@
// PURPOSE:
// Get count of pending customers
// REQ0006
//
// RULES:
// error handled by caller
// contain definition to collection only
//
import { COL_USER_METAS } from '@/constants';
import { pb } from '@/lib/pb';

View File

@@ -1,3 +1,12 @@
// PURPOSE:
// Sample hello world function
// REQ0006
//
// RULES:
// error handled by caller
// contain definition to collection only
//
export function helloCustomer(): string {
return 'Hello from Customers module!';
}

View File

@@ -1,3 +1,12 @@
// PURPOSE:
// Update customer information
// REQ0006
//
// RULES:
// error handled by caller
// contain definition to collection only
//
import { pb } from '@/lib/pb';
import { COL_CUSTOMERS } from '@/constants';
import type { RecordModel } from 'pocketbase';