Skip to content

Conversation

@Purplewells
Copy link
Owner

@Purplewells Purplewells commented Nov 6, 2025

Capture amended and enhanced accounting


Note

Adds a background queue worker, enhances fee refund processing and permissions, introduces a full assessment targets framework with pages/reports, and updates accounting/cashflow views and reports.

  • Infrastructure:
    • Add background QueueWorker (runs usp_ProcessSyncQueue) and SyncQueueHelper; initialize in Global.asax.
    • Bump framework version to 8.9.23.517.
  • Finance/Accounting:
    • Extend fee_collection_transaction_extra (new DueDate), refine UI, and restrict Delete to Administrators.
    • Expand refund processing (new params RefundReason, NameOfRecepient, ActionedBy) and add ProcessMultiFeeRefund action.
    • Use TransactionTypeRefund (exclude REFUND) in fee_collection_transaction.
    • Add PaymentRecords bank_manifest view and "Print To Current Bank" action.
    • Add get_cashflow_inflow_outflow controller/page; update cashflow statements/reports.
  • Targets Framework:
    • New controllers/models/pages: AssessmentTarget, TargetLevel, MeasurementType, MeasurementUnit, MeasurementTypeUnitMapping, TargetTemplate, TargetTemplateScope (+Detail), TargetEntity, TargetAssignment, TargetAdjustment, and WorkBenchAssessmentTargets.
    • Add navigation entries (Targets, Hub-Targets).
  • Staff/Contact:
    • Add PersonOwner, IdentificationCode (Staff Number), AccountNo; relabel to "Qualified Teacher Status"; minor label/lookup/tag tweaks.
  • Reports/UI:
    • Update multiple RDLCs (fee receipts, mini fee reminder, cashflow, payment records) and sitemap/pages.
    • Minor pivots/field order text tweaks across views.

Written by Cursor Bugbot for commit 1027673. This will update automatically on new commits. Configure here.

Capture amended and enhanced accounting
Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @Purplewells, your pull request is larger than the review limit of 150000 diff characters

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is being reviewed by Cursor Bugbot

Details

You are on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle.

To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.

}
}

base.BeforeSqlAction(args, result);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Base BeforeSqlAction Called Twice, Validation Order Incorrect

The BeforeSqlAction method calls base.BeforeSqlAction twice (lines 151 and 178). The first call at line 151 happens before any validation logic, and the second call at line 178 happens after the validation logic for fee_collection_transaction_extra. This is incorrect because base.BeforeSqlAction should only be called once, and it should be called AFTER all custom validation logic has been executed. The comment at line 164 even states "Always call base AFTER your logic" but then the code violates this principle by calling base first at line 151. This could cause validation logic to be bypassed or executed in the wrong order.

Fix in Cursor Fix in Web

// Show a clear message to the user
result.ShowAlert("You do not have permission to delete payment records. Escalate to a higher authority.");
}
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Redundant Delete Validation Blocks Cause Confusion

The delete validation for fee_collection_transaction_extra is duplicated with identical logic in two consecutive if blocks (lines 153-161 and lines 165-176). Both check the same condition (controller == "fee_collection_transaction_extra" && commandName == "Delete") and both check user roles. The first block only shows an alert without canceling the action, while the second block properly cancels the action with result.Canceled = true. This means the first block is redundant and could cause confusion. Only one of these blocks should exist, and it should properly cancel the action.

Fix in Cursor Fix in Web

@Purplewells
Copy link
Owner Author

Capture amended and enhanced accounting

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants