in a perpetual inventory system, cost of goods sold is recorded