File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed
app/code/Magento/Reports/Model/ResourceModel/Quote Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change 5
5
*/
6
6
namespace Magento \Reports \Model \ResourceModel \Quote ;
7
7
8
+ use Magento \Store \Model \Store ;
9
+
8
10
/**
11
+ * Collection of abandoned quotes with reports join.
12
+ *
9
13
* @api
10
14
* @since 100.0.2
11
15
*/
@@ -48,6 +52,24 @@ public function __construct(
48
52
$ this ->customerResource = $ customerResource ;
49
53
}
50
54
55
+ /**
56
+ * Filter collections by stores.
57
+ *
58
+ * @param array $storeIds
59
+ * @param bool $withAdmin
60
+ * @return $this
61
+ */
62
+ public function addStoreFilter (array $ storeIds , bool $ withAdmin = true )
63
+ {
64
+ if ($ withAdmin ) {
65
+ $ storeIds [] = Store::DEFAULT_STORE_ID ;
66
+ }
67
+
68
+ $ this ->addFieldToFilter ('store_id ' , ['in ' => $ storeIds ]);
69
+
70
+ return $ this ;
71
+ }
72
+
51
73
/**
52
74
* Prepare for abandoned report
53
75
*
You can’t perform that action at this time.
0 commit comments