YKPN#88810 Uitschakelen van het kunnen boeken van facturen op een contract

svn path=/Website/trunk/; revision=71123
This commit is contained in:
Erik Groener
2025-12-03 09:05:58 +00:00
parent 6ffd381e67
commit 9517935e17
3 changed files with 11 additions and 2 deletions

View File

@@ -72,6 +72,11 @@ model_cnt_disc_params =
"label": L("cnt_discipline_factuurappr"),
"typ": "check0"
},
"bookinvoice": {
"dbs": "cnt_disc_params_factuurboeken",
"label": L("cnt_discipline_factuurboeken"),
"typ": "check0"
},
"invoicelimit": { // "limit" is een reserved naam in API2
"dbs": "cnt_disc_params_factuurgrens",
"label": L("cnt_discipline_factuurgrens"),

View File

@@ -305,7 +305,10 @@ fin = { trackfactuurupdate:
result.cnt_versie = cnt_versie;
sql = "SELECT MAX(cnt_contract_key) cnt_contract_key"
+ " FROM cnt_v_aanwezigcontract c"
+ " WHERE c.cnt_contract_nummer_intern = " + safe.quoted_sql(cnt_nr)
+ " , cnt_disc_params p"
+ " WHERE c.ins_discipline_key = p.cnt_ins_discipline_key"
+ " AND p.cnt_disc_params_factuurboeken = 1"
+ " AND c.cnt_contract_nummer_intern = " + safe.quoted_sql(cnt_nr)
+ " AND c.cnt_contract_status = 0"
+ (cnt_versie? " AND c.cnt_contract_versie = " + safe.quoted_sql(cnt_versie) : "")
+ (ascontactpers

View File

@@ -80,7 +80,8 @@ scaffolding(this_model,
"margin",
"approve",
"invoicelimit",
"schedule"
"schedule",
"bookinvoice"
]
}
]