Subversion Repositories SmartDukaan

Rev

Rev 8626 | Rev 9433 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 8626 Rev 8630
Line 127... Line 127...
127
           FROM inventoryItem ii 
127
           FROM inventoryItem ii 
128
           JOIN scanNew s 
128
           JOIN scanNew s 
129
                ON (s.inventoryItemId = ii.id) 
129
                ON (s.inventoryItemId = ii.id) 
130
           WHERE (ii.lastScanType IN ('PURCHASE', 'SALE_RET', 'MARKED_GOOD') 
130
           WHERE (ii.lastScanType IN ('PURCHASE', 'SALE_RET', 'MARKED_GOOD') 
131
           OR ii.currentQuantity>1)
131
           OR ii.currentQuantity>1)
132
           AND ii.transferStatus!='IN_TRANSIT' 
132
           AND (transferStatus is NULL or transferStatus != 'IN_TRANSIT')
133
           AND ii.physicalWarehouseId !=16
133
           AND ii.physicalWarehouseId !=16
134
           GROUP BY ii.id, ii.itemId, ii.currentQuantity) t 
134
           GROUP BY ii.id, ii.itemId, ii.currentQuantity) t 
135
    JOIN purchase p 
135
    JOIN purchase p 
136
        ON (p.id = t.purchaseId) 
136
        ON (p.id = t.purchaseId) 
137
    JOIN lineitem l 
137
    JOIN lineitem l