-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathProductReviewHelper.php
More file actions
177 lines (173 loc) · 7.35 KB
/
ProductReviewHelper.php
File metadata and controls
177 lines (173 loc) · 7.35 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
<?php
declare(strict_types=1);
/*
* (c) shopware AG <info@shopware.com>
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Swag\PlatformDemoData\helper;
use Shopware\Core\Framework\Log\Package;
use Shopware\Core\Framework\Uuid\Uuid;
use Swag\PlatformDemoData\DataProvider\CustomerProvider;
#[Package('fundamentals@after-sales')]
class ProductReviewHelper
{
/**
* @return array<int, array<string, mixed>>
*/
public function createReviews(string $salesChannelId, string $languageId): array
{
return [
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Very good',
'content' => 'Excellent product! The quality is top notch, everything works perfectly and exceeds my expectations. I definitely recommend buying it.',
'points' => 5.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Outstanding Quality',
'content' => 'Top product! High-quality build, easy to use, and fast delivery. I would buy it again anytime',
'points' => 5.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Exceeded Expectations',
'content' => 'Absolutely delighted. Exactly as described, even better than expected.',
'points' => 5.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Perfect Choice',
'content' => 'Perfect! Exactly what I was looking for. Works flawlessly.',
'points' => 5.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Good',
'content' => 'Very good product with minor flaws. Overall, I am satisfied; it offers good value for money.',
'points' => 4.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Very Solid Product',
'content' => 'Overall a very good product. Minor flaws, but nothing serious.',
'points' => 4.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Great Value for Money',
'content' => 'Solid product with good value for money. I would recommend it.',
'points' => 4.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Satisfactory',
'content' => 'The product is fine, serves its purpose, but there is nothing special about it. Acceptable for the price.',
'points' => 3.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Does the Job',
'content' => 'Okay for everyday use. Does its job, but there are definitely better alternatives.',
'points' => 3.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Average Experience',
'content' => 'Average. Neither particularly good nor particularly bad.',
'points' => 3.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Poor',
'content' => 'Unfortunately disappointing. The quality is mediocre and there were several problems during use.',
'points' => 2.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Disappointing Durability',
'content' => 'Unfortunately not very durable. Problems appeared after a short time.',
'points' => 2.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Good Idea, Weak Execution',
'content' => 'The idea is good, but the execution is lacking.',
'points' => 2.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Very poor',
'content' => 'Absolutely not recommended. The product is defective, does not work as described and appears to be cheaply made.',
'points' => 1.0,
'status' => true,
],
[
'id' => Uuid::randomHex(),
'salesChannelId' => $salesChannelId,
'customerId' => CustomerProvider::CUSTOMER_ID,
'languageId' => $languageId,
'title' => 'Not Worth It',
'content' => 'Very disappointing. Poor quality and not functional upon delivery.',
'points' => 1.0,
'status' => true,
],
];
}
}