There's a lookup on the Opportunity to pricebook called Pricbook2ID. Just query and check to see if it null.
From: https://developer.salesforce.com/docs/atlas.en-us.api.meta/api/sforce_api_objects_opportunity.htm
Pricebook2Id
Type:
reference
Properties:
Create, Defaulted on create, Filter, Group, Nillable, Sort, Update
Description
ID of a related Pricebook2 object. The Pricebook2Id field indicates which Pricebook2 applies to this opportunity. The Pricebook2Id field is defined only for those organizations that have products enabled as a feature. You can specify values for only one field (Pricebook2Id or PricebookId)—not both fields. For this reason, both fields are declared nillable.