Post

Replies

Boosts

Views

Activity

Reply to The current model reference and the next model reference cannot be equal.
Thanks Guys. The type alias stuff was getting me. I manually put the static declaration with the class in front to avoid my confusion. Here's my latest VersionedSchema for clarity. enum ModelSchemaV5: VersionedSchema { static var versionIdentifier = Schema.Version(5, 0, 0) static var models: [any PersistentModel.Type] { [ // V1 ModelSchemaV1.SDAccountingClass.self, ModelSchemaV1.SDCacheRecord.self, ModelSchemaV1.SDCustomer.self, ModelSchemaV1.SDItem.self, ModelSchemaV1.SDLocation.self, ModelSchemaV1.SDTag.self, ModelSchemaV1.SDUOM.self, // V2 ModelSchemaV2.SDPurchaseOrder.self, ModelSchemaV2.SDPurchaseOrderItem.self, ModelSchemaV2.SDVendor.self, ModelSchemaV2.SDCarrier.self, ModelSchemaV2.SDInventoryLocationSummary.self, ModelSchemaV2.SDPurchaseOrderSettings.self, // V3 ModelSchemaV3.SDShip.self, ModelSchemaV3.SDSalesOrder.self, // V4 ModelSchemaV4.SDReceipt.self, ModelSchemaV4.SDDocument.self, // V5 ModelSchemaV5.SDReceiptItem.self ] } }
Oct ’24
Reply to Hot to merge Predicate in SwiftData
@Indubitably Thank you for your answer. I followed your instructions and it's working great - however - mine is acting like an AND predicate and not an OR. If anyone is looking for OR: Replace PredicateExpressions.Conjunction with PredicateExpressions.Disjunction in the function buildConjunction (and preferably rename it) to combine the predicates using logical OR instead.
Apr ’24
Reply to The current model reference and the next model reference cannot be equal.
Thanks Guys. The type alias stuff was getting me. I manually put the static declaration with the class in front to avoid my confusion. Here's my latest VersionedSchema for clarity. enum ModelSchemaV5: VersionedSchema { static var versionIdentifier = Schema.Version(5, 0, 0) static var models: [any PersistentModel.Type] { [ // V1 ModelSchemaV1.SDAccountingClass.self, ModelSchemaV1.SDCacheRecord.self, ModelSchemaV1.SDCustomer.self, ModelSchemaV1.SDItem.self, ModelSchemaV1.SDLocation.self, ModelSchemaV1.SDTag.self, ModelSchemaV1.SDUOM.self, // V2 ModelSchemaV2.SDPurchaseOrder.self, ModelSchemaV2.SDPurchaseOrderItem.self, ModelSchemaV2.SDVendor.self, ModelSchemaV2.SDCarrier.self, ModelSchemaV2.SDInventoryLocationSummary.self, ModelSchemaV2.SDPurchaseOrderSettings.self, // V3 ModelSchemaV3.SDShip.self, ModelSchemaV3.SDSalesOrder.self, // V4 ModelSchemaV4.SDReceipt.self, ModelSchemaV4.SDDocument.self, // V5 ModelSchemaV5.SDReceiptItem.self ] } }
Replies
Boosts
Views
Activity
Oct ’24
Reply to Hot to merge Predicate in SwiftData
@Indubitably Thank you for your answer. I followed your instructions and it's working great - however - mine is acting like an AND predicate and not an OR. If anyone is looking for OR: Replace PredicateExpressions.Conjunction with PredicateExpressions.Disjunction in the function buildConjunction (and preferably rename it) to combine the predicates using logical OR instead.
Replies
Boosts
Views
Activity
Apr ’24
Reply to Unable to Add for Review - Xcode 15.0.1 - New apps and app updates must be built with the public (GM) versions of Xcode 11 or later
same here.
Replies
Boosts
Views
Activity
Nov ’23
Reply to EKEventEditViewController Add and Cancel buttons not responding
for me: vc.eventStore = viewModel.eventStore I was forgetting to set the eventStore on the EKEventEditViewController
Topic: App & System Services SubTopic: General Tags:
Replies
Boosts
Views
Activity
May ’22