Factorizer/Cluster ERP WikiCluster ERP English
Ana sayfa / İş modülleri

Modül

Purchasing quotations modülü (purchasing_quotations)

Kalemleri, fiyat koşulları, kademeleri, sürümleri, ihale, karşılaştırma ve izleyen belgeleriyle tedarikçi teklif defteri olan purchasing_quotations modülü sayfası.

src/cluster_erp/modules/purchasing_quotations/ içindeki purchasing_quotations modülü tedarikçi tekliflerinin defteridir. Bir tedarikçi teklifi (PurchasingQuotation), bir satın alma teklif talebiyle veya talepsiz olarak bir tedarikçinin teklifini kaydeder; kalem başına indirim, ek ücret ve navlun koşullarıyla fiyatlanır. Bir teklifin ihalesi procurement modülünde bir satın alma siparişi veya satın alma sözleşmesi oluşturabilir ve satın alma info kayıtlarını günceller. Defter, satın alma teklif talebi alt modülünde tutulan tedarikçi tekliflerini de listeler.

Bir bakışta

Öğe Değer Kaynak
Paket src/cluster_erp/modules/purchasing_quotations/ klasör
Modül sınıfı Module src/cluster_erp/modules/purchasing_quotations/module.py:15
name / version purchasing_quotations / 0.1.0 src/cluster_erp/modules/purchasing_quotations/module.py:20-26
API öneki /api/v1/purchasing_quotations (ModuleBase.api_prefix) src/cluster_erp/core/module_base.py:37-38
Alt modüller 1: quotations klasör listesi
Tablolar 4: purq_quotations, purq_quotation_lines, purq_quotation_conditions, purq_quotation_scales quotations/models.py içindeki __tablename__
Metadata'daki varlıklar entities içinde 6 anahtar src/cluster_erp/modules/purchasing_quotations/module.py:173-184
Uçlar Pakette 27 uç dekoratörü @...router.get/post/put/patch/delete için grep
Aksiyonlar 7 ActionMeta girdisi pakette grep "ActionMeta("
Göçler 8 dosya metni dört tablo adından birini içeren migrations/versions/ dosyaları
Web uygulamasında yeri Katalog uygulaması purchasing-quotations src/cluster_erp/modules/app_store/catalog.json (purchasing-quotations girdisi)
Masaüstünde yeri src/cluster_erp/desktop/modules/purchasing_quotations/ yalnızca __init__.py içerir; ekranlar genel bileşenleri kullanır klasör

Modül ne yapar

  • Tedarikçi tekliflerini dört source değeriyle kaydeder: rfq, unsolicited (varsayılan), spot ve price_list (src/cluster_erp/modules/purchasing_quotations/quotations/models.py:40-46, src/cluster_erp/modules/purchasing_quotations/quotations/schemas.py:16).
  • Her kalemi bir koşul dizisinden geçirerek etkin birim fiyata ulaştırır (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:797-831).
  • Revizyonları tutar: revise bir teklifi yeni bir sürüme kopyalar ve eskisini yerini almış olarak işaretler (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:509-594).
  • Kalemleri ihale eder ve istenirse EventBus üzerinden bir satın alma siparişi veya sözleşmesi oluşturur (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:285-346).
  • Bir ürün için tüm canlı teklif kalemlerini etkin fiyata göre karşılaştırır ve yerel ve teklif talebi tekliflerinden oluşan bir defter listeler (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:990-1116).

Alt modüller

Alt modül Amaç Ana varlıklar Yönlendirici Kaynak
quotations Teklifler, kalemler, koşullar, kademeler, karşılaştırma, defter PurchasingQuotation, PurchasingQuotationLine, PurchasingQuotationCondition, PurchasingQuotationScale /purchasing-quotations ve kalem, koşul ve kademe yolları src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:39-61

Yönlendirici modül önekinin altına require_app("purchasing_quotations") ile bağlanır (src/cluster_erp/modules/purchasing_quotations/module.py:39-49).

Veri modeli

Varlık Tablo Anahtar alanlar Notlar Kaynak
PurchasingQuotation purq_quotations code, source, purchase_rfq_id, vendor_party_id, status, version_no, superseded_by_id, vendor_quotation_no, currency, valid_from, valid_until, binding_until, total_amount, project_id, follow_on_type, follow_on_id, follow_on_code gönderme, ihale, ret, tamamlama ve iptal zaman damgaları src/cluster_erp/modules/purchasing_quotations/quotations/models.py:24-104
PurchasingQuotationLine purq_quotation_lines line_no, ürün kırılımı, description, qty, net_unit_price, effective_unit_price, line_total, lead_time_days, moq, rejection_indicator, is_awarded serbest metin kalemlerinin ürünü yoktur src/cluster_erp/modules/purchasing_quotations/quotations/models.py:107-151
PurchasingQuotationCondition purq_quotation_conditions condition_type, calc_type, value, base, sequence, label src/cluster_erp/modules/purchasing_quotations/quotations/models.py:154-186
PurchasingQuotationScale purq_quotation_scales from_qty, unit_price src/cluster_erp/modules/purchasing_quotations/quotations/models.py:189-205

Para Numeric türündedir: toplam ve kalem toplamı Numeric(19, 4), fiyatlar ve koşul değerleri Numeric(18, 4) (src/cluster_erp/modules/purchasing_quotations/quotations/models.py:81, src/cluster_erp/modules/purchasing_quotations/quotations/models.py:127-131, src/cluster_erp/modules/purchasing_quotations/quotations/models.py:172). Kalem kırılımları ensure_product_breakdown ile denetlenir (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:713, src/cluster_erp/modules/purchasing_quotations/quotations/services.py:745).

Ekranlar ve metadata

get_metadata üç liste bölümlü bir Tedarikçi Teklifleri (İngilizce Supplier Quotations) kenar çubuğu grubu bildirir: Tedarikçi Teklifleri, Tüm Teklifler (Defter) ve Tedarikçi Teklifi Karşılaştır (src/cluster_erp/modules/purchasing_quotations/module.py:130-170). Defter ve karşılaştırma görünümleri kendi varlıklarıdır: purchasing_quotation_register ve purchasing_quotation_compare (src/cluster_erp/modules/purchasing_quotations/module.py:173-184). Bkz. genel liste.

Durumlar ve aksiyonlar

Durumlar in_preparation (varsayılan), submitted, awarded, completed, rejected ve cancelled'dır (src/cluster_erp/modules/purchasing_quotations/quotations/models.py:54-62). Servis her aksiyonu bir hedef duruma ve izin verilen kaynak durumlara eşler (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:57-64).

stateDiagram-v2
 [*] --> in_preparation
 in_preparation --> submitted: submit
 submitted --> awarded: award
 in_preparation --> rejected: reject
 submitted --> rejected: reject
 awarded --> completed: complete
 in_preparation --> cancelled: cancel
 submitted --> cancelled: cancel
 awarded --> cancelled: cancel
 rejected --> in_preparation: reopen
 cancelled --> in_preparation: reopen

Düz anlatımla: bir teklif hazırlanır ve gönderilir, sonra ihale edilir veya reddedilir. İhale edilmiş bir teklif tamamlanır veya iptal edilir. Reddedilmiş veya iptal edilmiş bir teklif yeniden açılabilir. revise, submitted, rejected veya cancelled durumundan çalışır ve yeni bir in_preparation sürümü başlatır (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:509-525).

Aksiyon Etiket Koşul Uç İzin Kaynak
submit Sun status değeri in_preparation POST /purchasing-quotations/{id}/submit purchasing_quotation.submit src/cluster_erp/modules/purchasing_quotations/quotations/metadata.py:636-643, src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:178
award Ödüllendir status değeri submitted POST /purchasing-quotations/{id}/award purchasing_quotation.award src/cluster_erp/modules/purchasing_quotations/quotations/metadata.py:644-695, src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:192
reject Reddet status değeri in_preparation veya submitted POST /purchasing-quotations/{id}/reject purchasing_quotation.reject src/cluster_erp/modules/purchasing_quotations/quotations/metadata.py:696-712, src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:214
complete Tamamla status değeri awarded POST /purchasing-quotations/{id}/complete purchasing_quotation.complete src/cluster_erp/modules/purchasing_quotations/quotations/metadata.py:713-720, src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:231
cancel İptal Et status değeri in_preparation, submitted veya awarded POST /purchasing-quotations/{id}/cancel purchasing_quotation.update src/cluster_erp/modules/purchasing_quotations/quotations/metadata.py:721-737, src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:245
reopen Yeniden Aç status değeri rejected veya cancelled POST /purchasing-quotations/{id}/reopen purchasing_quotation.update src/cluster_erp/modules/purchasing_quotations/quotations/metadata.py:738-745, src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:262
revise Revize Et (yeni sürüm) status değeri submitted, rejected veya cancelled POST /purchasing-quotations/{id}/revise purchasing_quotation.revise src/cluster_erp/modules/purchasing_quotations/quotations/metadata.py:746-753, src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:276

İş kuralları

  • Bir teklif yalnızca in_preparation veya submitted durumunda düzenlenebilir (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:54, src/cluster_erp/modules/purchasing_quotations/quotations/services.py:634-640).
  • Yalnızca in_preparation, cancelled veya rejected teklifler silinebilir; silme deleted_at alanını doldurur (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:224-238).
  • Gönderim için en az bir kalem, reddedilmemiş en az bir kalem, bir para birimi ve bir geçerlilik tarihi gerekir (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:599-633).
  • Etkin birim fiyat koşulları sequence sırasıyla dolaşır. Yüzde, yürüyen ara toplama veya net fiyata uygulanır; per_unit birim başına sabit tutar ekler; absolute sabit bir tutarı miktara yayar. İndirimler düşer, ek ücret ve navlun ekler; sonuç sıfırın altına inmez (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:797-831).
  • Kalem toplamı miktar çarpı etkin fiyattır ve dört basamağa yuvarlanır; başlık toplamı her kalem veya koşul değişikliğinde yeniden hesaplanır (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:848-874).
  • İhale önce kararı saklar, istenirse ardından bir izleyen satın alma siparişi veya sözleşmesi oluşturur; izleyen belge zaten varsa bu adımı atlar (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:321-339, src/cluster_erp/modules/purchasing_quotations/quotations/services.py:389-449).
  • code, purchasing_quotation yıllık dizisinden gelir; bir revizyon yeni bir kod ve bir fazla version_no alır (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:168, src/cluster_erp/modules/purchasing_quotations/quotations/services.py:522).
  • Kademeler kalem başına saklanır ve revizyonda kopyalanır; etkin fiyat hesabı bunları okumaz (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:580-582, src/cluster_erp/modules/purchasing_quotations/quotations/services.py:848-851).

Olaylar ve sorgular

Modül 2 sözleşme tüketir ve 7 sözleşme üretir; sayım parties modülü sayfasındaki gibi yapıldı. Tam liste sözleşmeler başvurusu sayfasındadır.

Yön Sözleşme sınıfı İşleyici veya yayan Kaynak
yayar SupplierQuotationAwarded ürünü olan ihale edilmiş kalemler için _emit_awarded_event src/cluster_erp/modules/purchasing_quotations/quotations/services.py:347-388
sorgular CreateFollowOnFromSupplierQuotation _create_follow_on src/cluster_erp/modules/purchasing_quotations/quotations/services.py:389-449
sorgular GetPurchaseRfqQuotations teklif talebi teklifleri için register src/cluster_erp/modules/purchasing_quotations/quotations/services.py:1048-1116
sorguyu yanıtlar GetPurchasingQuotationById _handle_get_quotation src/cluster_erp/modules/purchasing_quotations/module.py:51-102
abone olur DescribeAnalyticsFacts describe_analytics_facts src/cluster_erp/modules/purchasing_quotations/module.py:60-66

SupplierQuotationAwarded ve CreateFollowOnFromSupplierQuotation sözleşmelerini procurement modülü işler; bkz. satın alma sözleşmeleri ve info kayıtları.

Yetkiler

İzin anahtarı Kullanan Kaynak
purchasing_quotation.read listeler, ayrıntı, eksiksizlik, kalemler, koşullar, kademeler, karşılaştırma, defter src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:61-473
purchasing_quotation.create, .update, .delete, .bulk_delete kayıt ve alt kayıt değişiklikleri, iptal, yeniden açma src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:99-436
purchasing_quotation.submit, .award, .reject, .complete, .revise yaşam döngüsü uçları src/cluster_erp/modules/purchasing_quotations/quotations/routes.py:178-276

Gizlilik, saklama ve geçmiş

Modülün privacy_handlers.py dosyası yoktur. Teklifler yumuşak silinir (src/cluster_erp/modules/purchasing_quotations/quotations/services.py:236). Fiyat koşulları ve kademeler, satırlarıyla birlikte yenilenen alt satırlardır; her kaldırma kayda geçsin diye ORM üzerinden kaldırılır (aşağıdaki nota bakın). Değişiklikler değişiklik geçmişi tarafından kaydedilir.

Analitik olguları

analytics_facts.py, purchasing_quotation.read ile okunan quotation_count, total_amount, median_amount ve average_lead_time_days ölçülü purchasing_quotation olgu kümesini katar (src/cluster_erp/modules/purchasing_quotations/analytics_facts.py:17-117). Bkz. analitik olguları.

Ayarlar ve başvuru verileri

Modülün ayarlar bölümü yoktur. Koddan belirlenemedi: koşul tiplerinin başvuru verisinden gelip gelmemesi gerektiği; bunlar şemada sabit bir Literal olarak tanımlıdır (src/cluster_erp/modules/purchasing_quotations/quotations/schemas.py:16-19).

Testler

tests/ içinde modules.purchasing_quotations için (sonuç yok) ve web-client/ içinde dosya adına ve /purchasing_quotations/ yoluna göre grep ile bulundu.

Tür Dosya Kapsam
e2e web-client/_e2e_purchasing_quotations_app.mjs tedarikçi teklifleri uygulaması
e2e web-client/_e2e_tenant_fields_phase4b.mjs teklifteki kiracı alanları

Tutarsızlıklar

Tanıtılan terimler

Terim Kod tanımlayıcısı Tanım Türkçe terim Kaynak
supplier quotation PurchasingQuotation Teklif talebiyle veya talepsiz deftere kaydedilen tedarikçi teklifi. Tedarikçi teklifi src/cluster_erp/modules/purchasing_quotations/quotations/models.py:24
pricing condition PurchasingQuotationCondition Kalem fiyatına uygulanan indirim, ek ücret, navlun veya nakit indirimi. Fiyat koşulu src/cluster_erp/modules/purchasing_quotations/quotations/models.py:154
effective unit price effective_unit_price Tüm koşullar sırayla uygulandıktan sonraki kalem fiyatı. Etkin birim fiyat src/cluster_erp/modules/purchasing_quotations/quotations/models.py:130
follow-on document follow_on_type, follow_on_id İhale edilmiş bir tekliften oluşturulan satın alma siparişi veya sözleşmesi. İzleyen belge src/cluster_erp/modules/purchasing_quotations/quotations/models.py:91-93

İlgili sayfalar


92f8051 numaralı commit ile 2026-11-13 tarihinde doğrulandı.

Doğrulanan commit 92f8051 · 2026-11-13