File tree Expand file tree Collapse file tree 1 file changed +11
-6
lines changed
WooCommerce/Classes/ViewModels/Order Details Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Original file line number Diff line number Diff line change @@ -1241,13 +1241,18 @@ extension OrderDetailsDataSource {
12411241 siteID: order. siteID,
12421242 orderID: order. orderID,
12431243 index: " 0 " ,
1244- items: order. items. map { item in
1245- var subItems : [ String ] = [ ]
1246- for index in 0 ..< item. quantity . intValue {
1247- subItems . append ( " \( item . itemID ) -sub- \( index ) " )
1244+ items: order. items
1245+ . filter { item in
1246+ let matchingProduct = products . first ( where : { $0 . productID == item. productOrVariationID } )
1247+ return matchingProduct ? . virtual == false
12481248 }
1249- return WooShippingShipmentItem ( id: item. itemID, subItems: subItems)
1250- } ,
1249+ . map { item in
1250+ var subItems : [ String ] = [ ]
1251+ for index in 0 ..< item. quantity. intValue {
1252+ subItems. append ( " \( item. itemID) -sub- \( index) " )
1253+ }
1254+ return WooShippingShipmentItem ( id: item. itemID, subItems: subItems)
1255+ } ,
12511256 shippingLabel: nil
12521257 ) ]
12531258 } ( )
You can’t perform that action at this time.
0 commit comments