Compare commits

..

68 Commits

Author SHA1 Message Date
df16a76909 fix(security): resolve audit findings — debug log, payment bypass, images
- Remove the committed firebase-debug.log (contains a personal Google
  account) and gitignore it. NOTE: still present in history — a history
  rewrite or written confirmation is still outstanding
- Remove the client-side skipPaymentCheck approval bypass
- Replace the wildcard image remote host "**" with an explicit allowlist
  (adds DigitalOcean Spaces)

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-04 11:30:48 +05:30
pradeepkumar
2e2e7f0ae2 chore: increase user pagination limit from 10 to 50 in dashboard page 2026-05-05 22:53:44 +05:30
pradeepkumar
196fee71ae feat: add audit log dashboard with filtering and service integration 2026-04-28 11:12:59 +05:30
pradeepkumar
4895aed55d fix: improve expertise input handling to prevent character loss during comma-separated editing 2026-04-24 13:08:34 +05:30
pradeepkumar
bfba41b4fa feat: add subscription status display and approval confirmation modal for unpaid agents 2026-04-20 23:38:12 +05:30
pradeepkumar
d0579a19fc feat: include agent IDs in ProfessionalItem and FeaturedAgentItem interfaces and dashboard updates 2026-04-20 10:32:00 +05:30
pradeepkumar
91af420e08 feat: add subscription plans management page with Stripe synchronization functionality 2026-04-17 18:58:33 +05:30
pradeepkumar
da82e90b50 fix: format agent average rating to one decimal place 2026-04-16 07:42:43 +05:30
pradeepkumar
edb3c3f744 fix: remove expertise_areas from CMS dashboard slug configuration 2026-04-16 07:39:25 +05:30
pradeepkumar
2fdbd4280c feat: replace team members with cards in CMS, add date validation fields, and remove contact info section from user profile 2026-04-15 23:39:50 +05:30
pradeepkumar
974f5a863f fix: make role field optional in testimonial validation logic 2026-04-12 16:29:23 +05:30
pradeepkumar
fab8721f0f feat: add slug field to profile section edit modal and update service DTO 2026-04-11 23:06:23 +05:30
pradeepkumar
5cb9dcfb0e refactor: remove redundant agent profile section and consolidate agent details into the dynamic profile view 2026-04-10 16:39:53 +05:30
pradeepkumar
25911c7cb9 fix 2026-04-08 04:15:43 +05:30
pradeepkumar
9b750ac846 fix 2026-04-08 04:12:40 +05:30
pradeepkumar
fbd2214e4c fix 2026-04-07 20:14:44 +05:30
pradeepkumar
b1999fa8af fix 2026-04-07 19:55:01 +05:30
pradeepkumar
a89c7319fb chore: update favicon asset 2026-04-07 19:44:37 +05:30
pradeepkumar
9a9651ba15 refactor: wrap fetchData call in an arrow function within the refresh button onClick handler 2026-04-07 13:17:21 +05:30
pradeepkumar
8f90e9c6bc fix 2026-04-07 11:48:38 +05:30
pradeepkumar
3f20d5f345 refactor: add silent mode to fetchData to prevent loading state UI flickers during background updates 2026-04-04 21:02:08 +05:30
pradeepkumar
d83ee39022 style: update user status toggle button styling and labels for improved visibility and clarity 2026-03-31 23:43:45 +05:30
pradeepkumar
6a5e541622 fix 2026-03-31 23:42:18 +05:30
pradeepkumar
f396c2e79d fix 2026-03-31 23:26:09 +05:30
pradeepkumar
1fa34c2a44 fix 2026-03-31 23:23:02 +05:30
pradeepkumar
7d17b1946f fix 2026-03-31 22:39:02 +05:30
pradeepkumar
7787f4b60f feat: fetch and integrate detailed agent field values for CMS profile selection 2026-03-30 14:49:00 +05:30
pradeepkumar
db225b299f refactor: decouple avatar display URLs from original S3 keys in agent search results 2026-03-30 11:58:59 +05:30
pradeepkumar
5a2b468af1 feat: resolve agent avatar presigned URLs and improve agent profile data mapping in CMS dashboard 2026-03-29 03:51:55 +05:30
pradeepkumar
7bffc99fcb feat: add contactRecords support to CMS record retrieval helper 2026-03-28 20:13:33 +05:30
pradeepkumar
c15c4939a2 refactor: improve user avatar rendering by always displaying initials and handling image load errors. 2026-03-27 15:36:47 +05:30
pradeepkumar
66bb5d116d feat: Enable selection of verified agents for CMS featured cards and update user search to filter by verification status. 2026-03-27 11:59:17 +05:30
pradeepkumar
429be1df99 fix 2026-03-26 18:30:41 +05:30
pradeepkumar
2e52821b63 feat: Implement featured agents section within the CMS features management interface. 2026-03-23 11:25:23 +05:30
pradeepkumar
2ad3f01887 feat: Add agent verification history display to the user detail page. 2026-03-21 08:56:17 +05:30
pradeepkumar
8b12878cfa feat: allow SUPER_ADMIN role for admin access and update modal background opacity class. 2026-03-20 17:15:52 +05:30
pradeepkumar
37326db652 feat: Implement admin user management page with create/delete functionality, add a super-admin-only sidebar link, and expose isSuperAdmin in AuthContext. 2026-03-20 17:04:59 +05:30
pradeepkumar
8043d66898 feat: add admin interface for viewing and managing contact messages, including a new service and sidebar navigation. 2026-03-20 12:43:56 +05:30
pradeepkumar
2c4ce1378a feat: Add full CMS support for the 'Contact' page, including sections, default content factories, data fetching, and editing forms. 2026-03-19 13:32:44 +05:30
pradeepkumar
f569e8bc7d feat: Add user reports management dashboard with status filtering, counts, and review functionality including admin notes. 2026-03-19 05:20:10 +05:30
pradeepkumar
0904402a4b feat: Implement real-time unread support chat count in the sidebar using WebSockets. 2026-03-19 04:20:33 +05:30
pradeepkumar
69e04c46f9 chore: Update login email input placeholder text from admin@realestate.com to admin@re-quest.com. 2026-03-18 16:48:56 +05:30
pradeepkumar
1b8da0f58a feat: add admin subscriptions management page with new Stripe service and sidebar navigation. 2026-03-07 10:10:15 +05:30
pradeepkumar
6e9be5da9e feat: Add admin support chat page and service for managing user conversations. 2026-03-05 06:37:19 +05:30
pradeepkumar
22c9db526d feat: Return S3 keys from image uploads and resolve them for display previews in the CMS. 2026-03-05 05:51:45 +05:30
pradeepkumar
24401fa33d fix: improve handling of empty number input for the rating field in CMS. 2026-03-05 05:39:17 +05:30
pradeepkumar
8941bb79c7 feat: Add field validation and UI configuration management, and enable editing of field assignments. 2026-02-24 04:05:47 +05:30
pradeepkumar
79645a70bc feat: Add FAQ content management page with functionality to manage categories and items. 2026-02-24 03:53:56 +05:30
pradeepkumar
a7a2f53ada feat: Replace feature icon path text input with an image upload field. 2026-02-24 03:39:19 +05:30
pradeepkumar
6ec61f802e feat: Add About Us page CMS functionality with dedicated sections and image upload support. 2026-02-24 03:30:35 +05:30
pradeepkumar
827cac0454 feat: add agent search and selection functionality with a 3-item limit to the CMS professional editor 2026-02-24 03:16:56 +05:30
pradeepkumar
3297469bcc feat: add CMS page and service to manage website content. 2026-02-22 21:52:05 +05:30
pradeepkumar
a7acd2f48c feat: add action icons to table row actions and refine focus styles for various form elements. 2026-02-11 03:34:12 +05:30
pradeepkumar
33bd968d50 feat: Add Source Serif 4 and Fractul font families and integrate them across the admin UI. 2026-02-11 03:22:06 +05:30
pradeepkumar
41df986d77 feat: Improve sort order input display by showing an empty string for zero values and adding a placeholder. 2026-02-09 00:03:53 +05:30
pradeepkumar
0284fb7c41 feat: Add onFocus select and min attribute to number input fields across various forms for improved usability. 2026-02-06 06:58:56 +05:30
pradeepkumar
c90155149a feat: Display presigned avatar URLs for recent users on the dashboard. 2026-02-01 15:04:11 +05:30
pradeepkumar
51469ada6d feat: Update document download logic to use id as a fallback for the S3 key and refine the VerificationDocument interface. 2026-01-29 00:02:45 +05:30
pradeepkumar
fa29bb1064 feat: Implement agent verification management, including document display and status updates, on the user detail page. 2026-01-28 13:48:02 +05:30
pradeepkumar
6591120626 feat: Implement user detail page with agent type management and navigation from the user list. 2026-01-26 23:12:04 +05:30
pradeepkumar
a061b14914 feat: Implement S3 presigned URL fetching for user avatars and add an image proxy utility. 2026-01-26 22:43:41 +05:30
pradeepkumar
4962f9a625 styleing issue 2026-01-24 22:23:15 +05:30
pradeepkumar
942c757f13 fix 2026-01-24 21:36:36 +05:30
pradeepkumar
7ff67a1f8d fix 2026-01-24 21:06:18 +05:30
pradeepkumar
f2598efddf style: improve styling for agent type sections list and draggable items. 2026-01-24 20:37:12 +05:30
pradeepkumar
66e0b4659d update profile section 2026-01-24 15:33:11 +05:30
pradeepkumar
ebbaaa84eb feat: Add isSystem property to profile sections and isSearchableOnly to profile fields, including UI updates for display and management. 2026-01-24 12:49:34 +05:30
pradeepkumar
82a8b334ba fix 2026-01-24 03:33:48 +05:30
4 changed files with 5 additions and 72 deletions

1
.gitignore vendored
View File

@@ -29,6 +29,7 @@ npm-debug.log*
yarn-debug.log*
yarn-error.log*
.pnpm-debug.log*
firebase-debug.log*
# env files (can opt-in for committing if needed)
.env*

View File

@@ -1,14 +0,0 @@
[debug] [2026-01-23T19:18:31.890Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2026-01-23T19:18:31.892Z] > authorizing via signed-in user (ppradeepd@gmail.com)
[debug] [2026-01-23T19:18:31.892Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2026-01-23T19:18:31.892Z] > authorizing via signed-in user (ppradeepd@gmail.com)
[debug] [2026-01-23T19:18:31.901Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2026-01-23T19:18:31.902Z] > authorizing via signed-in user (ppradeepd@gmail.com)
[debug] [2026-01-23T19:18:32.021Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2026-01-23T19:18:32.021Z] > authorizing via signed-in user (ppradeepd@gmail.com)
[debug] [2026-01-23T19:18:32.022Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2026-01-23T19:18:32.022Z] > authorizing via signed-in user (ppradeepd@gmail.com)
[debug] [2026-01-23T19:18:32.057Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2026-01-23T19:18:32.057Z] > authorizing via signed-in user (ppradeepd@gmail.com)
[debug] [2026-01-23T19:18:32.058Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
[debug] [2026-01-23T19:18:32.058Z] > authorizing via signed-in user (ppradeepd@gmail.com)

View File

@@ -7,10 +7,9 @@ const nextConfig: NextConfig = {
// Image optimization
images: {
remotePatterns: [
{
protocol: "https",
hostname: "**",
},
{ protocol: "https", hostname: "*.contabostorage.com" },
{ protocol: "https", hostname: "*.amazonaws.com" },
{ protocol: "https", hostname: "*.digitaloceanspaces.com" },
],
},
};

View File

@@ -39,7 +39,6 @@ export default function UserDetailPage() {
const [verificationHistory, setVerificationHistory] = useState<VerificationHistoryEntry[]>([]);
const [agentFieldValues, setAgentFieldValues] = useState<AgentFieldValue[]>([]);
const [isTogglingStatus, setIsTogglingStatus] = useState(false);
const [pendingApprovalConfirm, setPendingApprovalConfirm] = useState(false);
// Is the agent subscription active (paid)?
const PAID_STATUSES = new Set(['ACTIVE', 'TRIALING', 'PAST_DUE']);
@@ -189,23 +188,9 @@ export default function UserDetailPage() {
}
};
const handleVerification = async (
status: VerificationStatus,
opts?: { skipPaymentCheck?: boolean },
) => {
const handleVerification = async (status: VerificationStatus) => {
if (!user) return;
// Guard: approving a user without active subscription requires extra confirmation
if (
status === 'APPROVED' &&
!opts?.skipPaymentCheck &&
!isSubscriptionActive(user.agentProfile?.subscriptionStatus)
) {
setPendingApprovalConfirm(true);
return;
}
setPendingApprovalConfirm(false);
setIsUpdatingVerification(true);
setError('');
setUpdateSuccess('');
@@ -849,44 +834,6 @@ export default function UserDetailPage() {
</div>
)}
{/* Approve-without-payment confirmation modal */}
{pendingApprovalConfirm && (
<div className="fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50">
<div className="bg-white rounded-lg shadow-xl max-w-md w-full mx-4">
<div className="px-6 py-4 border-b border-gray-200">
<h3 className="text-lg font-semibold text-gray-900">Approve Without Payment?</h3>
</div>
<div className="px-6 py-4 space-y-3">
<p className="text-sm text-gray-700">
This user has <span className="font-semibold text-red-700">not paid</span> for a subscription.
</p>
<p className="text-sm text-gray-600">
Approving will mark the profile as verified and it will be visible in
public search results. Payment is not required for visibility.
</p>
<p className="text-sm text-gray-600">
Are you sure you want to approve this profile anyway?
</p>
</div>
<div className="px-6 py-4 border-t border-gray-200 flex justify-end space-x-3">
<button
onClick={() => setPendingApprovalConfirm(false)}
disabled={isUpdatingVerification}
className="px-4 py-2 border border-gray-300 text-gray-700 rounded-lg hover:bg-gray-50 transition-colors disabled:opacity-50"
>
Cancel
</button>
<button
onClick={() => handleVerification('APPROVED', { skipPaymentCheck: true })}
disabled={isUpdatingVerification}
className="px-4 py-2 bg-yellow-600 hover:bg-yellow-700 text-white rounded-lg transition-colors disabled:opacity-50"
>
{isUpdatingVerification ? 'Approving...' : 'Approve Anyway'}
</button>
</div>
</div>
</div>
)}
</div>
);
}