OpenPerpetuum / PerpetuumServer

The Open Perpetuum Project's fork of the Perpetuum Standalone Server
https://openperpetuum.com
Other
44 stars 21 forks source link

PBS Market items fail to show on remote markets #332

Closed MikeJeffers closed 3 years ago

MikeJeffers commented 3 years ago

Command MarketItemsInRange ends up calling IMarketOrderRepository.GetAllByDefinition which produces the following query.

SELECT marketitems.marketitemid, marketitems.marketeid, marketitems.itemeid, marketitems.itemdefinition, marketitems.submittereid, 
marketitems.submitted, marketitems.duration, marketitems.isSell, marketitems.price, marketitems.quantity, 
marketitems.usecorporationwallet, marketitems.isvendoritem, marketitems.formembersof FROM marketitems 
INNER JOIN entities as childentity on (marketitems.marketeid=childentity.eid) 
INNER JOIN entities parent on (childentity.eid=parent.eid) 
INNER JOIN zoneentities on (parent.parent=zoneentities.eid) 
INNER JOIN zones on (zoneentities.zoneid=zones.id) where itemdefinition = @definition and zones.enabled=1

A key problem for PBS is that the terminals are not appearing as ZoneEntities in the zoneentities table. Thus no orders.

impl hint: PBS are zoneuserentities, not zoneentities