Subversion Repositories SmartDukaan

Rev

Show changed files | Directory listing | RSS feed

Filtering Options

Rev Age Author Path Log message Diff
36315 1 h 12 m ranu /trunk/ rbm rating dashboard view commited  
36314 3 h 59 m amit /trunk/profitmandi-dao/src/main/ Fix Dummy warehouse creation defaults and backfill invoice receiveDate

- ensureDummyForBillingRegion: set isAvailabilityMonitored=0, transferDelayInHours=0,
source=0 explicitly; copy logisticsLocation and pincode from billing warehouse
(matches createVendorWarehouse pattern)
- Add SQL to backfill warehouse.invoice.receiveDate from warehouse.purchase.receivedOn
for received invoices where receiveDate is NULL
 
36313 7 h 46 m ranu /trunk/profitmandi-fofo/src/main/webapp/WEB-INF/views/ftl/ rbm rating dashboard view commited  
36312 7 h 52 m ranu /trunk/profitmandi-fofo/src/main/java/com/spice/profitmandi/web/controller/monitors/ rbm rating dashboard view commited  
36311 8 h 10 m ranu /trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/model/ rbm rating dashboard view commited  
36310 15 h 52 m amit /trunk/profitmandi-web/src/main/java/com/spice/profitmandi/web/controller/checkout/ Complete applyColorChange rename: caller + handler method

r36305 renamed OrderServiceImpl.notifyColorChange -> applyColorChange but missed the
caller in this controller and the handler method name. Completes the rename so trunk
compiles. REST endpoint URL /order/notify-color-change is preserved as an external
contract.
 
36309 15 h 52 m amit /trunk/profitmandi-dao/src/main/ Route phantom orders to per-region Dummy warehouse; complete applyColorChange rename

- Phantom allocations in getFulfillments route to the Dummy/GOOD/OURS warehouse under
vendor 40 for the partner's billing region. WarehouseServiceImpl.ensureDummyForBillingRegion
returns the existing Dummy or creates one on the fly. createVendorWarehouse hook auto-seeds
a Dummy when a new billing region's first warehouse is created.
- WarehouseRepository.selectByVendorBillingAndType supports the lookup.
- OrderService interface: rename notifyColorChange -> applyColorChange to match r36305's impl
rename (r36305 renamed only the impl, leaving trunk inconsistent).
- PurchaseOrderServiceImpl: remove auto-rebalance on PO receive. Real-wh rebalancing and
phantom-to-real binding are now ops-driven via the order billing UI
(changeFulfillmentWarehouse / applyColorChange / moveOrdersFulfilmentWarehouse).
- migration_dummy_warehouses.sql: idempotent seeding script for 14 Dummy/GOOD/OURS warehouses
under vendor 40, one per WAREHOUSE_MAP billing region that lacked one. Already applied to
hadb1 and local.
 
36308 15 h 53 m amit /trunk/profitmandi-common/src/main/java/com/spice/profitmandi/common/model/ Add DEFAULT_FALLBACK_VENDOR_ID constant

Vendor id 40 ('Dummy') is the fallback routing marker when no real vendor has
pricing for a catalog. Each billing region has a Dummy/GOOD/OURS warehouse under
this vendor; phantom allocations route there.
 
36307 22 h 7 m ranu /trunk/profitmandi-fofo/src/main/ rbm rating dashboard view commited  
36306 1 d 8 h amit /trunk/profitmandi-cron/src/main/java/com/smartdukaan/cron/ Batch processing: BatchScheduledTasks, helpers for offer/sellin/partnerLimit, CronBatchService, OpenCV fix for Apple Silicon, CLI triggers  
36305 1 d 8 h amit /trunk/profitmandi-dao/src/main/ Batch processing infrastructure + per-partner offer processing + partner limit optimization + investment cache eviction on billing/payment/cancellation with 3hr TTL  
36304 2 d 20 h aman /trunk/profitmandi-fofo/src/main/webapp/WEB-INF/views/ftl/ Fix:Show ICICI Bank Ltd in fullstock req pannel  
36303 2 d 21 h aman /trunk/profitmandi-cron/src/main/java/com/smartdukaan/cron/scheduled/ Feat:Separate partner name and code into different columns in Partner Credit Report  
36302 2 d 21 h amit /trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/repository/catalog/ Add 2-min cache on Catalog.selectAllGoodStockBrandWise

Hottest query right now on the DB: 3851 execs x 297ms = ~1143 s over
2.9h uptime. Fired once per target-slab in TodayOfferServiceImpl's
findAllTodayOffer loop whenever the slab has no explicit catalog IDs.

Input is a single String brand (only ~10 brands), output is a list of
Catalog entities with no associations (all primitive/String columns,
no lazy-init risk) and the caller only invokes getBrand/getId on the
results. Safe to cache in the existing in-memory Caffeine
twoMintimeoutCacheManager.

Default Spring key (= brand) is stable; unless skips empty results.
 
36301 2 d 22 h ranu /trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/dao/model/ code optimization of today po rbm page  
36300 2 d 23 h amit /trunk/profitmandi-fofo/src/main/java/com/spice/profitmandi/web/config/ Bump JS version to 331 to bust cache for GRN correction auto-approve UI change  
36299 2 d 23 h amit /trunk/profitmandi-fofo/src/main/ GRN correction: surface autoApproved flag to UI

Controller returns {status, autoApproved} JSON; JS shows an
'auto-approved' message when the request bypasses approval, otherwise
the existing 'raised for approval' message. Pairs with dao r36298.
 
36298 2 d 23 h amit /trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/service/warehouse/ GRN correction: auto-approve IMEI-only and color-only changes

When a correction request contains only IMEI swaps or item swaps where
old and new items share modelName+modelNumber (color-only change), the
request is persisted as APPROVED with requester as approver and applied
immediately. Mixed/model/qty changes continue to go through the existing
PENDING approval flow.
 
36297 3 d 0 h amit /trunk/profitmandi-fofo/src/main/java/com/spice/profitmandi/web/controller/monitors/ Fix MonitorController autowiring after @Cacheable proxy

UserWalletRepositoryImpl now has @Cacheable (r36296), which makes Spring
wrap it in a JDK interface proxy. MonitorController autowired the concrete
class, breaking startup with BeanNotOfRequiredTypeException. Switch to the
interface UserWalletRepository, matching every other repository injection
in the file.
 
36296 3 d 0 h amit /trunk/profitmandi-dao/src/main/java/com/spice/profitmandi/ Add 2-min cache on dashboard-family queries

Three queries dominate dashboard DB time (~830 s / 30 min combined) because
they re-execute on every dashboard refresh with near-identical parameters:

- OrderRepositoryImpl.selectPartnersBilledBetweenDates: dynamic endDate is
LocalDateTime.now(), so cache key bucketed to 2-minute boundaries via SpEL
(endDate.toEpochSecond / 120) so calls in the same bucket share an entry.
- UserWalletRepositoryImpl.getPartnerWiseCollectionAchievement and
RbmTargetServiceImpl.getWeeklyBillingDataForMonth: default Spring key
(fofoIds + startDate) is stable, no bucketing needed.

All three use the existing Caffeine 'twoMintimeoutCacheManager' (in-memory,
per-JVM, expireAfterWrite=2min). unless clause skips caching empty results
so legitimately-empty responses don't pin a bad entry.
 

Show All