Skip to main content
Question

Contract Statuses - how do they work?

  • August 6, 2025
  • 6 replies
  • 53 views

Forum|alt.badge.img+5

How do the contract statuses work?

We are running version 

15.4.11.2


If I look in the cconth DB table, the cconth_stat_id doesn't seem to align with the codes I see in the 'Contract Statuses' module.

For example, in the 'Contract Statuses' module, it says that 700 is Expired.
If I look in the database table for all records with cconth_stat_id = '700' it comes back with no rows, yet we have a ton of expired contracts.

The module also says 200 = approved and 300 = active.
Yet a DB query seems to return expired contracts if the cconth_stat_id = 200 & is_active = n.
And if cconth_stat_id = 200 & is_active = y, then the status appears to be active.

Just want to understand how what's in the database relates to the status I see in the contract in the web gui.

 

6 replies

Forum|alt.badge.img+12
  • Superhero (Employee)
  • August 6, 2025

Hi Mark,

In general, when you activate contract the status is 200.

It remains 200 until you actively change it (Actions, Change Status).

When the contract expiry date has been passed, you will see the status as expired. It is a calculated value, but in the database remains 200.

 

Regards,

Joshua


Forum|alt.badge.img+5
  • Author
  • Sidekick
  • August 6, 2025

Thanks ​@Joshua Liem 

So are the status and their numbers that are in the ‘Contract Statuses’ module, not really used?


Forum|alt.badge.img+10

Expanding on Joshua’s answer, if the status is Approved and the From Date is equal or greater than the current date, then the status will be displayed as Active.

If the contract status is Approved or Active and the to date is greater than the current date, the status will be displayed as Expired.

Otherwise, the status will display as it is in the database.

The reason for this dynamic calculation is because there is no background service that looks to see if contracts are expired or active and update the status accordingly. This would put too much unnecessary load on the database - instead, it's all done dynamically by the system.  If you are running any kind of reporting based on status, you should include this logic in your reports as well.


Forum|alt.badge.img+12
  • Superhero (Employee)
  • August 6, 2025

Hi Mark,

 

The Contract Status can be used for different purpose, i.e: for suspending or holding contract from billing


Forum|alt.badge.img+5
  • Author
  • Sidekick
  • August 6, 2025

If the contract status is Approved or Active and the to date is greater than the current date, the status will be displayed as Expired.

Otherwise, the status will display as it is in the database.

 

Thanks for your response Andrew.
Just to make sense of it . . . in the piece quoted above, have you got it the wrong way around in regard to expired being displayed?? That would be if the to date is LESS than the current date right? Not GREATER than the current date?

 

cheers

mark.


Forum|alt.badge.img+12
  • Superhero (Employee)
  • August 6, 2025

Yes, you are correct Mark. I think it was just typo😀