refactored create pq view and implemented cbv