fix: block ready bid exports once a winner is published
This commit is contained in:
@@ -33,6 +33,7 @@ export function bidSourceSnapshot(tender, results, rows = sourceRows(tender, res
|
||||
announcement: tender?.aciklama || '',
|
||||
deadline: [tender?.tarih || '', tender?.saat || ''],
|
||||
status: tender?.durum || '',
|
||||
...(tender?.kazananFirma ? {winner:tender.kazananFirma} : {}),
|
||||
documentVersion: results?.documentVersion ?? tender?.documentVersion ?? null,
|
||||
procurementTerms: results?.procurementTerms || null,
|
||||
analysis: preparationAnalysisSource(results),
|
||||
|
||||
@@ -2,6 +2,7 @@ import {deadlineInfo} from './tenderCalendar.js';
|
||||
|
||||
/** Preparation may be saved, but a current bid needs a verified future deadline. */
|
||||
export function preparationDeadlineProblem(tender, now = new Date()) {
|
||||
if(tender?.kazananFirma)return 'İhalenin kazananı açıklanmış. Hazır teklif çıktısı oluşturulamaz; taslağınızı kaydedebilirsiniz.';
|
||||
const status=String(tender?.durum || '').toLocaleLowerCase('tr-TR');
|
||||
if (/iptal|sonuçlandı|sözleşme imzalandı/.test(status))
|
||||
return 'İhale iptal edilmiş veya sonuçlanmış. Hazır teklif çıktısı oluşturulamaz; taslağınızı kaydedebilirsiniz.';
|
||||
|
||||
Reference in New Issue
Block a user