| Rev |
Age |
Author |
Path |
Log message |
Diff |
| 37845 |
1 d 1 h |
amit |
/trunk/profitmandi-dao/src/ |
feat(warehouse): ACTIVE/SUSPENDED/INACTIVE status + label on sellerwarehouse replace WAREHOUSE_MAP - BillingWarehouseService (active for dashboards, active+suspended for warehouse screens, names in every state, 5 min cache); setup service: guarded status change (no suspend while franchise stores or brand mapping route there, no close while stock/unshipped orders), rename, all-warehouse overview with usage; partner store assignable only to an active warehouse; daily stock alert for suspended/inactive warehouses to logistics/accounts top 2 staffed levels + leadership; dashboard warehouse list = active (replaces r37834 stock-holding loop); migration sellerwarehouse_status_display_name_20261005.sql (applied on hadb1) |
|
| 37830 |
4 d 18 h |
amit |
/trunk/profitmandi-dao/src/ |
feat(movement): one PO per source vendor warehouse and cost - layers carry their GOOD/OURS vendor warehouse, orders are raised pinned to it, holds of pinned orders come off their own warehouse, billing takes units at the order's price first |
|
| 37822 |
4 d 23 h |
amit |
/trunk/profitmandi-dao/src/ |
feat(warehouse): physical warehouse setup service, supplier mapping PO guard, address active flag
- WarehouseSetupService + WarehouseSetupValidator: create seller (state from GSTIN,
unique label/GSTIN), address master (city stored last, 6-digit pin, contact),
physical warehouse (OURS/BAD vendor 40 + Dummy/G + sellerwarehouse + mapping in
one transaction), activate/deactivate (sellerwarehouse.is_active), remap address
with internal store sync. Limits follow column sizes (sql_mode is empty).
- WarehouseAddressMaster.active: only active addresses are offered for assignment.
Migration sql/20261001_warehouseaddressmaster_active.sql (applied on hadb1).
- PO guard: createPurchaseOrder refuses a supplier with no OURS/GOOD vendor
warehouse at the destination (GRN could never receive it).
InventoryWarehouseRepository.hasGoodSupplierWarehouse / selectSupplierIdsWithGoodWarehouse
use existence checks; 67 pairs carry duplicate OURS/GOOD rows.
- SellerService.syncInternalStoreAddress(store); RetailerServiceImpl syncs an
INTERNAL store's address when it moves warehouse or becomes internal.
- Record of 2026-10-01 HR Gurugram setup SQL (seller 21, warehouses 13368/13370/13372).
- Tests: WarehouseSetupValidatorTest (10), WarehouseSetupServiceImplTest (7). |
|
| 37806 |
7 d 6 h |
amit |
/trunk/profitmandi-dao/src/test/java/com/spice/profitmandi/service/integrations/gstpro/ |
test(gstpro): classify NIC refusals - buyer GSTIN vs own seller vs state code
IrnRefusalClassificationTest covers GstProService.isInvalidBuyerGstin, which
decides whether a NIC refusal opens the Finance B2C settlement: a cancelled or
invalid BUYER GSTIN qualifies; a state-code mismatch or a message naming our
own seller GSTIN does not. 9/9 pass. |
|
| 37792 |
8 d 4 h |
amit |
/trunk/profitmandi-dao/src/ |
feat(cart): carry bag at Rs 1 per smartphone over Rs 12,000, extras at listing price
One carry bag (item 32046) is priced at Rs 1 for each smartphone (category
10006) in the cart selling above Rs 12,000; bags beyond that count are priced
at the carry bag's listing price, and Bronze partners pay listing for all.
Closes the leak where bag-only carts of hundreds of bags at Rs 1 were placed
from the old app. CarryBagQuote (via CartService.getCarryBagQuote) is the
single rule; the cart carries it as one line at a blended price.
- CartService/CartServiceImpl, CartResponse, OpenCartValidationResult: expose
the quote on the cart.
- OrderLineAllocator: an item may now have more than one cart line (the flat
and listing-priced parts); its units fill the lines in order.
- TransactionServiceImpl: item quantities merge instead of failing on a
duplicate item id.
- PurchaseServiceImpl: partner GRN creates one stock record per billed price;
the GRN screen shows the blended unit price; dead
createScannedNonSerializedItem removed.
- PurchaseReturnServiceImpl: debit-note PDF picks the order billed at the
returned stock's price; refundOrder spreads a non-serialized return over the
item's orders with room left (same price first) instead of loading it all
on the first order.
Tests: CarryBagQuoteTest 6/6, OrderLineAllocatorTest 13/13.
Deploy with profitmandi-web (same change) and the partner apps. |
|
| 37769 |
12 d 1 h |
amit |
/trunk/profitmandi-dao/src/ |
fix(movement): receive a movement invoice only against its own PO, stop auto-closing movements, cancel reduces the PO line
- GRN: movement invoice resolves invoice -> orders -> transaction -> its own movement PO (or a receive-only PO
from the billing warehouse); supplier/warehouse keyed at entry must match; scanned IMEIs must be the billed ones
- Cancelling an unbilled movement order takes its qty off the PO line; PO CLOSED/PRECLOSED once nothing is open
- reopenedAt removed (movements no longer auto-close); PO records createdBy
- SupplierStateResolver: a supplier's state is derived from its GSTIN on save
- sql: add_po_created_by (applied), drop_po_reopened_at (run AFTER fofo/cron/web deploy) |
|
| 37767 |
12 d 1 h |
amit |
/trunk/profitmandi-dao/src/ |
fix(orders): movements ship from their source only; a row reserved beyond its stock gives nothing
Internal movement orders were allocated by the partner allocator, which spills a source
shortfall to every warehouse the brand mapping links to the destination - stock billed
there has no PO to be received against (PO 54279: 3 units put on Jaipur for a UP->Delhi
movement). createTransactionInternally now keeps the source's own rows only; a shortfall
still parks on the source's Dummy.
getItemQty took min(qty, netAvailability) on a row reserved beyond its stock - always the
case on a Dummy holding an open order - so a -1 row added a unit to the shortfall, which
then parked on the Dummy as an extra order (24 Sep: 9 units raised for a movement of 8,
refused by the cart-value guard). Rows with nothing free are now skipped and no longer
offset another row's free stock in the warehouse total.
Removes the empty, uncalled markOrdersAsGrnCompleted. |
|
| 37721 |
18 d 3 h |
amit |
/trunk/profitmandi-dao/src/ |
fix(orders): price each order by the cart line that asked for it, not the first line of its model
Orders were priced from one cart line per catalog, so colours of one model at different
prices all took an arbitrary one. Internal movements (cost layers) failed with WLT_1000
when the dearer line won and were silently under-billed when the cheaper one did.
fulfillQty now prices from the item's own line, newColorQty from the model's any-colour
line; same-price output is unchanged. Refuse the transaction if orders do not total the cart. |
|
| 37640 |
21 d 2 h |
amit |
/trunk/profitmandi-dao/src/ |
Hot Deal brand: brand-driven membership, model_hot_deal reduced to attributes + oem_brand + oem_catalog_id, migration SQL |
|
| 37628 |
21 d 7 h |
amit |
/trunk/profitmandi-dao/src/ |
feat(mail): filter inactive auth users from outgoing mail
InactiveAuthUserRecipientFilter drops @smartdukaan.com recipients whose auth.auth_user is inactive (cached, 5 min refresh, fail-open). Remove inactive hardcoded recipients (sm@, praveen.sharma, tejus.lohani). |
|
| 37525 |
33 d 2 h |
amit |
/trunk/profitmandi-dao/src/ |
offer circular: division aliases, portal-editable scope, web offer sync (dao)
- division_alias support: CircularIngestRepository.selectDivisionAliases so an
alternate OEM label resolves onto an existing division instead of dropping the
rows as UNKNOWN. Both pdf_label columns are ALIASED - Hibernate discovers
native-query results by name and throws NonUniqueDiscoveredSqlAlias on a dup.
- OfferScopeRepository{,Impl}: write side for scope config (add/edit a division,
in_scope toggle, label aliases). Kept apart from OfferCurationRepository, whose
contract is limited to product_alias - a bad alias mismaps one product, a bad
scope change silently drops a whole brand.
- OfferCircularRepositoryImpl: label-side division join now resolves through
division_alias (dva), otherwise an UNPARSED row under an aliased label is hidden
by the inScopeOnly filter - exactly the rows the review screen exists to show.
Also isoDate(): period_month left as java.sql.Date serialised to epoch millis,
which an <input type=date> silently rejects, so the circular filter cleared
itself and every circular showed every row.
- WebOfferSyncRepository{,Impl} + migration: publish a parsed circular into
dtr.web_offer / web_offer_product. Anchored on (document, page, row) stored as
VALUES, never offers.offer.id, which is recreated on every re-ingest. source
defaults to MANUAL so the 3850 hand-typed rows are untouched; web_offer_sync_shadow
is what lets a human edit win over a later sync. |
|
| 37456 |
38 d 12 h |
amit |
/trunk/ |
Block billing when NIC rejects the transporter GSTIN for e-way bills
NIC files the e-way bill alongside the IRN, so a deregistered transporter
GSTIN returns Status=1 with InfoDtls[InfCd=EWBERR] (3029 "GSTIN - ... is
not active"): the IRN is valid while ewb_no stays null. Nothing downstream
reads that as a failure, so invoices kept being issued for goods that
could not legally move.
Cache the rejected transporter GSTIN in Redis and refuse to bill through
it. The block is keyed on the GSTIN, since one GSTIN is shared by several
warehouse_provider rows, and it carries the day it was raised so it lapses
at midnight and each new day re-tests NIC once. Correcting the GSTIN in
the provider panel lifts it immediately.
Only errors that are the transporter's fault block billing - NIC's 3029,
or any message naming the GSTIN we sent as TransId. Every other EWBERR
behaves as before: the IRN is filed and the e-way bill is retried later.
Guard sits in addBillingDetailsForGrouppedOrders before the pessimistic
lock and before any mutation, mirroring LogisticsServiceImpl#getEwbDetails
(order's own warehouse; self-pickup and runner skipped, as they travel on
a vehicle number rather than a transporter id). |
|
| 37415 |
41 d 6 h |
vikas |
/trunk/ |
Whatsapp Apis |
|
| 37409 |
41 d 7 h |
vikas |
/trunk/ |
Changed WhatsApp service to botpenguin (DigiWaha) |
|
| 37388 |
43 d 3 h |
vikas |
/trunk/ |
Whatsapp Apis |
|
| 37289 |
57 d 0 h |
amit |
/trunk/profitmandi-dao/src/ |
external api v2: space-separated ram/storage pair in catalog titles (refurb naming) |
|
| 37284 |
57 d 3 h |
amit |
/trunk/profitmandi-dao/src/ |
external api v2: derive specs from catalog brand/model title (pair + lone-storage forms) as last resort; migration file marks applied state, legacy update() note |
|
| 37281 |
57 d 3 h |
amit |
/trunk/profitmandi-dao/src/ |
external api v2: storeMaster visibility by fofo_type=FRANCHISE (drop internal flag check); spec derivation supports MB sizes (feature phones) |
|
| 37268 |
57 d 10 h |
amit |
/trunk/profitmandi-dao/src/ |
Hot deals: rename attribute activated -> fresh with polarity inversion (fresh = device unused/sealed). Entity/attributes/service/tests migrated; prod DDL (unapplied) now creates fresh directly; model_hot_deal_activated_to_fresh.sql migrates envs that had the old column (applied on local + saholic-test) |
|
| 37244 |
61 d 9 h |
amit |
/trunk/profitmandi-dao/src/ |
Hot deal attributes: five mandatory fields (warranty_months 0-12, item_condition NEW/OPEN_BOX/REFURBISHED, activated, finance_mapping, affordability) on model_hot_deal - entity+enum+attributes holder, service validation (no defaults), addDeal/updateDeal signatures, selectActiveByCatalogItemIds/selectAllActive repo queries, hotDealTags on FofoCatalogResponse, DDL script, tests (14 green) |
|