| 85 |
ashish |
1 |
namespace java in.shop2020.model.v1.catalog
|
| 95 |
ashish |
2 |
namespace py shop2020.thriftpy.model.v1.catalog
|
| 85 |
ashish |
3 |
|
| 3374 |
rajveer |
4 |
include "GenericService.thrift"
|
|
|
5 |
|
| 85 |
ashish |
6 |
/**
|
|
|
7 |
Objects
|
|
|
8 |
*/
|
|
|
9 |
|
| 123 |
ashish |
10 |
/**
|
| 1330 |
chandransh |
11 |
Caution :- Never ever change the numbers in it. Please confirm from @Chandranshu or @Rajveer before any changes in enum and other entries in file.
|
| 123 |
ashish |
12 |
**/
|
| 103 |
ashish |
13 |
enum status{
|
| 123 |
ashish |
14 |
PHASED_OUT = 0, //Item is no longer selling
|
|
|
15 |
DELETED = 1, //Item has been deliberately deleted
|
| 3009 |
chandransh |
16 |
PAUSED = 2, //Item's sale has been paused manually.
|
| 123 |
ashish |
17 |
ACTIVE = 3, //Item is available for sale as of now
|
| 2984 |
rajveer |
18 |
IN_PROCESS = 4, //Item has been added, but content is not available for the same
|
|
|
19 |
CONTENT_COMPLETE = 5, //The content for this item has been completed. We can start selling the item now.
|
| 3009 |
chandransh |
20 |
PAUSED_BY_RISK = 6 //Item's sale has been automatically paused since it was marked as risky
|
| 103 |
ashish |
21 |
}
|
|
|
22 |
|
| 646 |
chandransh |
23 |
enum WarehouseLocation{
|
| 1330 |
chandransh |
24 |
Mumbai = 0,
|
|
|
25 |
Delhi = 1,
|
| 646 |
chandransh |
26 |
Bangalore = 2,
|
|
|
27 |
Kolkata = 3
|
|
|
28 |
}
|
|
|
29 |
|
| 1330 |
chandransh |
30 |
struct Vendor{
|
|
|
31 |
1:i64 id,
|
|
|
32 |
2:string name
|
|
|
33 |
}
|
|
|
34 |
|
| 2841 |
chandransh |
35 |
enum BillingType {
|
|
|
36 |
OURS = 0,
|
|
|
37 |
EXTERNAL = 1
|
|
|
38 |
}
|
|
|
39 |
|
| 483 |
rajveer |
40 |
/*
|
|
|
41 |
Warehouse fields details
|
|
|
42 |
location: it is full address
|
|
|
43 |
vendorString: some key for the warehouse
|
|
|
44 |
*/
|
| 85 |
ashish |
45 |
struct Warehouse{
|
|
|
46 |
1:i64 id,
|
| 752 |
chandransh |
47 |
2:string displayName,
|
|
|
48 |
3:string location,
|
|
|
49 |
4:status warehouseStatus,
|
|
|
50 |
5:i64 addedOn,
|
|
|
51 |
6:i64 lastCheckedOn,
|
|
|
52 |
7:string tinNumber,
|
|
|
53 |
8:string pincode,
|
|
|
54 |
9:string vendorString,
|
| 2824 |
chandransh |
55 |
10:WarehouseLocation logisticsLocation,
|
|
|
56 |
11:string vendor,
|
| 4375 |
anupam.sin |
57 |
12:BillingType billingType
|
| 85 |
ashish |
58 |
}
|
| 4024 |
chandransh |
59 |
|
| 115 |
ashish |
60 |
/* */
|
| 85 |
ashish |
61 |
struct ItemInventory{
|
|
|
62 |
1:i64 id,
|
| 4431 |
phani.kuma |
63 |
2:map<i64,i64> availability,
|
|
|
64 |
3:map<i64,i64> reserved
|
| 85 |
ashish |
65 |
}
|
|
|
66 |
|
| 483 |
rajveer |
67 |
|
| 85 |
ashish |
68 |
struct ItemInventoryHistory{
|
|
|
69 |
1:i64 item_id,
|
|
|
70 |
2:i64 warehouse_id,
|
|
|
71 |
3:i64 timestamp,
|
|
|
72 |
4:i64 availability
|
|
|
73 |
}
|
|
|
74 |
|
|
|
75 |
struct Item{
|
|
|
76 |
1:i64 id,
|
| 956 |
chandransh |
77 |
2:string productGroup
|
|
|
78 |
3:string brand,
|
|
|
79 |
4:string modelNumber,
|
| 2128 |
ankur.sing |
80 |
5:string modelName,
|
|
|
81 |
6:string color,
|
|
|
82 |
7:i64 category,
|
|
|
83 |
8:string comments,
|
|
|
84 |
9:i64 catalogItemId,
|
|
|
85 |
10:i64 featureId,
|
|
|
86 |
11:string featureDescription,
|
|
|
87 |
12:ItemInventory itemInventory,
|
| 2127 |
ankur.sing |
88 |
13:optional double mrp, //maxmimum retail price
|
| 4762 |
phani.kuma |
89 |
14:optional double sellingPrice, //Selling price
|
|
|
90 |
15:optional double weight,
|
|
|
91 |
16:i64 addedOn,
|
|
|
92 |
17:optional i64 startDate,
|
|
|
93 |
18:optional i64 retireDate,
|
|
|
94 |
19:status itemStatus,
|
|
|
95 |
20:string status_description,
|
|
|
96 |
21:map<string,string> otherInfo,
|
|
|
97 |
22:string bestDealText,
|
|
|
98 |
23:optional double bestDealValue,
|
|
|
99 |
24:bool defaultForEntity,
|
|
|
100 |
25:i64 updatedOn,
|
|
|
101 |
26:optional i64 bestSellingRank,
|
|
|
102 |
27:bool risky,
|
|
|
103 |
28:optional i32 expectedDelay,
|
|
|
104 |
29:optional i64 preferredWarehouse,
|
|
|
105 |
30:optional i64 defaultWarehouse,
|
|
|
106 |
31:optional bool isWarehousePreferenceSticky,
|
|
|
107 |
32:i32 warrantyPeriod,
|
|
|
108 |
33:optional i64 preferredVendor
|
| 85 |
ashish |
109 |
}
|
|
|
110 |
|
| 1343 |
chandransh |
111 |
struct VendorItemPricing{
|
| 1349 |
chandransh |
112 |
1:i64 vendorId,
|
|
|
113 |
2:i64 itemId,
|
| 1343 |
chandransh |
114 |
3:double transferPrice,
|
|
|
115 |
4:double mop,
|
|
|
116 |
5:double dealerPrice
|
|
|
117 |
}
|
|
|
118 |
|
| 1967 |
rajveer |
119 |
struct Category{
|
|
|
120 |
1:i64 id,
|
|
|
121 |
2:string label,
|
|
|
122 |
3:string description,
|
|
|
123 |
4:i64 parent_category_id,
|
|
|
124 |
/**
|
|
|
125 |
* This field should not be used.
|
|
|
126 |
*/
|
|
|
127 |
5:list<i64> children_category_ids
|
| 4762 |
phani.kuma |
128 |
6:string display_name
|
| 1967 |
rajveer |
129 |
}
|
| 2113 |
ankur.sing |
130 |
|
|
|
131 |
struct VendorItemMapping{
|
|
|
132 |
1:i64 vendorId,
|
|
|
133 |
2:string itemKey,
|
| 4762 |
phani.kuma |
134 |
3:i64 itemId
|
| 2113 |
ankur.sing |
135 |
}
|
| 2983 |
chandransh |
136 |
|
|
|
137 |
struct ItemShippingInfo{
|
|
|
138 |
1:bool isActive,
|
|
|
139 |
2:optional bool isRisky,
|
|
|
140 |
3:optional i64 quantity
|
|
|
141 |
}
|
|
|
142 |
|
| 3556 |
rajveer |
143 |
struct Source{
|
|
|
144 |
1:i64 id,
|
|
|
145 |
2:string name,
|
|
|
146 |
3:string identifier
|
|
|
147 |
}
|
|
|
148 |
|
|
|
149 |
struct SourceItemPricing{
|
|
|
150 |
1:i64 sourceId,
|
|
|
151 |
2:i64 itemId,
|
|
|
152 |
3:double mrp,
|
|
|
153 |
4:double sellingPrice
|
|
|
154 |
}
|
|
|
155 |
|
| 4024 |
chandransh |
156 |
struct AvailableAndReservedStock {
|
|
|
157 |
1:i64 itemId,
|
|
|
158 |
2:i64 available,
|
|
|
159 |
3:i64 reserved,
|
|
|
160 |
4:i64 minimumStock
|
|
|
161 |
}
|
|
|
162 |
|
| 4295 |
varun.gupt |
163 |
struct ProductNotificationRequest {
|
|
|
164 |
1:Item item,
|
|
|
165 |
2:string email,
|
|
|
166 |
3:i64 addedOn
|
|
|
167 |
}
|
|
|
168 |
|
|
|
169 |
struct ProductNotificationRequestCount {
|
|
|
170 |
1:Item item,
|
|
|
171 |
2:i64 count
|
|
|
172 |
}
|
|
|
173 |
|
| 121 |
ashish |
174 |
exception InventoryServiceException{
|
| 85 |
ashish |
175 |
1:i64 id,
|
|
|
176 |
2:string message
|
|
|
177 |
}
|
|
|
178 |
|
| 3374 |
rajveer |
179 |
service InventoryService extends GenericService.GenericService{
|
| 763 |
rajveer |
180 |
|
| 85 |
ashish |
181 |
/**
|
|
|
182 |
Availability and inventory attributes
|
|
|
183 |
*/
|
|
|
184 |
//all add and update methods - added by Ashish
|
| 123 |
ashish |
185 |
i64 addItem(1:Item item) throws (1:InventoryServiceException cex),
|
|
|
186 |
i64 updateItem(1:Item item) throws (1:InventoryServiceException cex),
|
| 121 |
ashish |
187 |
i64 addWarehouse(1:Warehouse warehouse) throws (1:InventoryServiceException cex),
|
| 2983 |
chandransh |
188 |
|
|
|
189 |
/**
|
| 4332 |
anupam.sin |
190 |
add a new vendor
|
|
|
191 |
*/
|
|
|
192 |
i64 addVendor(1:Vendor vendor) throws (1:InventoryServiceException cex),
|
|
|
193 |
bool addWarehouseVendorMapping(1:i64 warehouse_id, 2:i64 vendorId),
|
|
|
194 |
list<Vendor> getVendorsForWarehouse(1:i64 warehouse_id),
|
|
|
195 |
list<Warehouse> getWarehousesForVendor(1:i64 vendorId),
|
|
|
196 |
|
|
|
197 |
/**
|
| 2983 |
chandransh |
198 |
Checks if the item given to the corresponding itemId is active. If it's active,
|
|
|
199 |
whether it's risky and if it's risky, its inventory position.
|
|
|
200 |
*/
|
|
|
201 |
ItemShippingInfo isActive(1:i64 itemId) throws (1:InventoryServiceException isex),
|
|
|
202 |
|
| 2033 |
rajveer |
203 |
string getItemStatusDescription(1:i64 itemId) throws (1:InventoryServiceException isex),
|
| 3323 |
chandransh |
204 |
|
|
|
205 |
/**
|
|
|
206 |
Stores the incremental warehouse updates of items.
|
|
|
207 |
*/
|
|
|
208 |
void updateInventoryHistory(1:i64 warehouse_id, 2:string timestamp, 3:map<string, i64> availability) throws (1:InventoryServiceException cex),
|
|
|
209 |
|
|
|
210 |
/**
|
|
|
211 |
Stores the final inventory stocks of items.
|
|
|
212 |
*/
|
| 483 |
rajveer |
213 |
void updateInventory(1:i64 warehouse_id, 2:string timestamp, 3:map<string, i64> availability) throws (1:InventoryServiceException cex),
|
| 2983 |
chandransh |
214 |
|
| 4320 |
rajveer |
215 |
/**
|
|
|
216 |
Add the inventory to existing stock.
|
|
|
217 |
*/
|
|
|
218 |
void addInventory(1:i64 itemId, 2:i64 warehouseId, 3:i64 quantity) throws (1:InventoryServiceException cex),
|
|
|
219 |
|
| 103 |
ashish |
220 |
//all delete methods
|
| 121 |
ashish |
221 |
void retireWarehouse(1:i64 warehouse_id) throws (1:InventoryServiceException cex),
|
| 103 |
ashish |
222 |
|
|
|
223 |
//Item management apis
|
| 121 |
ashish |
224 |
void startItemOn(1:i64 item_id, 2:i64 timestamp) throws (1:InventoryServiceException cex),
|
|
|
225 |
void retireItemOn(1:i64 item_id, 2:i64 timestamp) throws (1:InventoryServiceException cex),
|
|
|
226 |
void changeItemStatus(1:i64 item_id, 2:i64 timestamp, 3:status newstatus) throws (1:InventoryServiceException cex),
|
| 85 |
ashish |
227 |
//Other accessor methods - added by Ashish
|
| 121 |
ashish |
228 |
Item getItem(1:i64 item_id) throws (1:InventoryServiceException cex),
|
| 632 |
rajveer |
229 |
list<Item> getItemsByCatalogId(1:i64 catalog_item_id) throws (1:InventoryServiceException cex),
|
| 4934 |
amit.gupta |
230 |
list<Item> getValidItemsByCatalogId(1:i64 catalog_item_id) throws (1:InventoryServiceException cex),
|
| 121 |
ashish |
231 |
list<Item> getAllItems(1:bool isActive) throws (1:InventoryServiceException cex),
|
|
|
232 |
list<Item> getAllItemsByStatus(1:status itemStatus) throws (1:InventoryServiceException cex),
|
| 4431 |
phani.kuma |
233 |
//ItemInventory getItemInventory(1:i64 item_id) throws (1:InventoryServiceException cex),
|
| 632 |
rajveer |
234 |
ItemInventory getItemInventoryByItemId(1:i64 item_id) throws (1:InventoryServiceException cex),
|
|
|
235 |
//ItemInventory getItemInventoryByCatalogId(1:i64 item_id) throws (1:InventoryServiceException cex),
|
| 121 |
ashish |
236 |
i64 getItemAvailibilityAtWarehouse(1:i64 warehouse_id, 2:i64 item_id) throws (1:InventoryServiceException cex),
|
| 2076 |
rajveer |
237 |
bool markItemAsContentComplete(1:i64 entityId, 2:i64 category, 3:string brand, 4:string modelName, 5:string modelNumber) throws (1:InventoryServiceException cex),
|
| 646 |
chandransh |
238 |
|
| 3355 |
chandransh |
239 |
/**
|
| 3848 |
chandransh |
240 |
Gets at most 'limit' items starting at the given offset. Returns an empty list if there are no more items at the given offset.
|
|
|
241 |
*/
|
|
|
242 |
list<Item> getAllItemsInRange(1:i64 offset, 2:i64 limit) throws (1:InventoryServiceException cex),
|
|
|
243 |
|
|
|
244 |
/**
|
|
|
245 |
Gets at most 'limit' items starting at the given offset in the given status. Returns an empty list if there are no more items at the given offset.
|
|
|
246 |
*/
|
|
|
247 |
list<Item> getAllItemsByStatusInRange(1:status itemStatus, 2:i64 offset, 3:i64 limit) throws (1:InventoryServiceException cex),
|
|
|
248 |
|
|
|
249 |
/**
|
|
|
250 |
Gets a count of all items by status
|
|
|
251 |
*/
|
|
|
252 |
i32 getItemCountByStatus(1:bool useStatus, 2:status itemStatus),
|
|
|
253 |
/**
|
| 3355 |
chandransh |
254 |
Determines the warehouse that should be used to fulfil an order for the given item.
|
|
|
255 |
It first checks all the warehouses which are in the logistics location given by the
|
|
|
256 |
warehouse_loc parameter. If none of the warehouses there have any inventory, then the
|
|
|
257 |
preferred warehouse for the item is used.
|
| 1157 |
rajveer |
258 |
|
| 3355 |
chandransh |
259 |
Returns an ordered list of size 4 with following elements in the given order:
|
|
|
260 |
1. Logistics location of the warehouse which was finally picked up to ship the order.
|
|
|
261 |
2. Id of the warehouse which was finally picked up.
|
|
|
262 |
3. Inventory size in the selected warehouse.
|
|
|
263 |
4. Expected delay added by the category manager.
|
| 646 |
chandransh |
264 |
*/
|
|
|
265 |
list<i64> getItemAvailabilityAtLocation(1:i64 warehouse_loc, 2:i64 item_id) throws (1:InventoryServiceException isex),
|
| 3355 |
chandransh |
266 |
|
| 121 |
ashish |
267 |
list<Warehouse> getAllWarehouses(1:bool isActive) throws (1:InventoryServiceException cex),
|
| 1343 |
chandransh |
268 |
|
|
|
269 |
/**
|
|
|
270 |
Returns the warehouse with the given id.
|
|
|
271 |
*/
|
| 121 |
ashish |
272 |
Warehouse getWarehouse(1:i64 warehouse_id) throws (1:InventoryServiceException cex),
|
|
|
273 |
list<Warehouse> getAllWarehousesForItem(1:i64 item_id) throws (1:InventoryServiceException cex),
|
| 502 |
rajveer |
274 |
list<Item> getAllItemsForWarehouse(1:i64 warehouse_id) throws (1:InventoryServiceException cex),
|
|
|
275 |
|
| 862 |
chandransh |
276 |
/**
|
|
|
277 |
Increases the reservation count for an item in a warehouse. Should always succeed normally.
|
|
|
278 |
*/
|
|
|
279 |
bool reserveItemInWarehouse(1:i64 itemId, 2:i64 warehouseId, 3:double quantity) throws (1:InventoryServiceException cex),
|
|
|
280 |
|
|
|
281 |
/**
|
|
|
282 |
Decreases the reservation count for an item in a warehouse. Should always succeed normally.
|
|
|
283 |
*/
|
|
|
284 |
bool reduceReservationCount(1:i64 itemId, 2:i64 warehouseId, 3:double quantity) throws (1:InventoryServiceException cex),
|
|
|
285 |
|
| 502 |
rajveer |
286 |
// for home page .... best deals, best sellers and latest arrivals
|
| 588 |
chandransh |
287 |
list<Item> getBestSellers() throws (1:InventoryServiceException isex),
|
| 1924 |
rajveer |
288 |
list<i64> getBestSellersCatalogIds(1:i64 beginIndex, 2:i64 totalItems, 3:string brand, 4:i64 category) throws (1:InventoryServiceException cex),
|
| 588 |
chandransh |
289 |
i64 getBestSellersCount() throws (1:InventoryServiceException cex),
|
|
|
290 |
|
|
|
291 |
list<Item> getBestDeals() throws (1:InventoryServiceException isex),
|
| 1924 |
rajveer |
292 |
list<i64> getBestDealsCatalogIds(1:i64 beginIndex, 2:i64 totalItems, 3:string brand, 4:i64 category) throws (1:InventoryServiceException cex),
|
| 588 |
chandransh |
293 |
i64 getBestDealsCount() throws (1:InventoryServiceException cex),
|
|
|
294 |
|
| 2975 |
chandransh |
295 |
/**
|
|
|
296 |
Returns a list of items sorted in the descending order by start date.
|
|
|
297 |
The list is limited to the 'latest_arrivals_count' configuraiton parameter.
|
|
|
298 |
*/
|
| 588 |
chandransh |
299 |
list<Item> getLatestArrivals() throws (1:InventoryServiceException isex),
|
| 2975 |
chandransh |
300 |
|
|
|
301 |
/**
|
|
|
302 |
Returns the list of catalog ids of latest arrivals in the given categories of the given brand.
|
|
|
303 |
To ignore the categories, pass the list as empty. To ignore brand, pass it as null.
|
|
|
304 |
*/
|
|
|
305 |
list<i64> getLatestArrivalsCatalogIds(1:i64 beginIndex, 2:i64 totalItems, 3:string brand, 4:list<i64> categories) throws (1:InventoryServiceException cex),
|
|
|
306 |
|
|
|
307 |
/**
|
|
|
308 |
Get the total number of latest arrivals we are willing to show.
|
|
|
309 |
The count's upper bound is the 'latest_arrivals_count' configuraiton parameter.
|
|
|
310 |
*/
|
| 632 |
rajveer |
311 |
i64 getLatestArrivalsCount() throws (1:InventoryServiceException cex),
|
|
|
312 |
|
| 1157 |
rajveer |
313 |
|
|
|
314 |
i64 generateNewEntityID(),
|
|
|
315 |
|
|
|
316 |
/**
|
| 1343 |
chandransh |
317 |
Returns the pricing information of an item associated with the vendor of the given warehouse.
|
|
|
318 |
Raises an exception if either the item, vendor or the associated pricing information can't be found.
|
|
|
319 |
*/
|
| 4283 |
anupam.sin |
320 |
VendorItemPricing getItemPricing(1:i64 itemId, 2:i64 vendorId) throws (1:InventoryServiceException cex),
|
| 1343 |
chandransh |
321 |
|
|
|
322 |
/**
|
| 1157 |
rajveer |
323 |
* Store category object and retrieve it
|
|
|
324 |
*/
|
| 1967 |
rajveer |
325 |
/**
|
| 632 |
rajveer |
326 |
bool putCategoryObject(1:binary object),
|
|
|
327 |
binary getCategoryObject()
|
| 1967 |
rajveer |
328 |
*/
|
|
|
329 |
|
|
|
330 |
/**
|
|
|
331 |
* All category related functions
|
|
|
332 |
*/
|
|
|
333 |
bool addCategory(1:Category category),
|
|
|
334 |
Category getCategory(1:i64 id),
|
| 1990 |
ankur.sing |
335 |
list<Category> getAllCategories(),
|
| 1967 |
rajveer |
336 |
|
| 1990 |
ankur.sing |
337 |
/**
|
|
|
338 |
Returns the list of vendor pricing information of an item.
|
|
|
339 |
Raises an exception if item not found corresponding to itemId
|
|
|
340 |
*/
|
|
|
341 |
list<VendorItemPricing> getAllItemPricing(1:i64 itemId) throws (1:InventoryServiceException cex),
|
|
|
342 |
|
|
|
343 |
|
|
|
344 |
/**
|
| 2113 |
ankur.sing |
345 |
Adds vendor prices corresponding to the item. If pricing already exists then updates the prices.
|
| 1990 |
ankur.sing |
346 |
Raises an exception if either the item or vendor can't be found corresponding to their ids.
|
|
|
347 |
*/
|
| 2113 |
ankur.sing |
348 |
void addVendorItemPricing(1:VendorItemPricing vendorItemPricing) throws (1:InventoryServiceException cex),
|
| 1990 |
ankur.sing |
349 |
|
| 2063 |
ankur.sing |
350 |
/**
|
|
|
351 |
Return list of all vendors
|
|
|
352 |
*/
|
| 2113 |
ankur.sing |
353 |
list<Vendor> getAllVendors(),
|
| 2063 |
ankur.sing |
354 |
|
| 2113 |
ankur.sing |
355 |
/**
|
| 4423 |
phani.kuma |
356 |
Returns the list of similar items.
|
|
|
357 |
*/
|
|
|
358 |
list<Item> getAllSimilarItems(1:i64 itemId),
|
|
|
359 |
|
|
|
360 |
/**
|
|
|
361 |
Adds similar item.
|
|
|
362 |
*/
|
|
|
363 |
Item addSimilarItem(1:i64 itemId, 2:i64 catalogItemId) throws (1:InventoryServiceException cex),
|
|
|
364 |
|
|
|
365 |
/**
|
|
|
366 |
Delete similar item.
|
|
|
367 |
*/
|
|
|
368 |
bool deleteSimilarItem(1:i64 itemId, 2:i64 catalogItemId) throws (1:InventoryServiceException cex),
|
|
|
369 |
|
|
|
370 |
/**
|
| 2356 |
ankur.sing |
371 |
Adds VendorItemMapping. Updates VendorItemMapping if exists corresponding to the item key.
|
| 2113 |
ankur.sing |
372 |
*/
|
| 2356 |
ankur.sing |
373 |
void addVendorItemMapping(1:string key, 2:VendorItemMapping vendorItemMapping) throws (1:InventoryServiceException cex),
|
| 2113 |
ankur.sing |
374 |
|
|
|
375 |
/**
|
|
|
376 |
Returns the list of vendor item mapping corresponding to itemId passed as parameter.
|
|
|
377 |
Raises an exception if item not found corresponding to itemId
|
|
|
378 |
*/
|
|
|
379 |
list<VendorItemMapping> getVendorItemMappings(1:i64 itemId) throws (1:InventoryServiceException cex),
|
|
|
380 |
|
|
|
381 |
/**
|
| 4725 |
phani.kuma |
382 |
Checks if similar item exists (with same Brand, ModelNumber, ModelName, Color)
|
| 2113 |
ankur.sing |
383 |
If yes, returns the itemId else returns 0
|
|
|
384 |
*/
|
| 4725 |
phani.kuma |
385 |
i64 checkSimilarItem(1:string brand, 2:string modelNumber, 3:string modelName, 4:string color),
|
| 2284 |
ankur.sing |
386 |
|
|
|
387 |
/**
|
|
|
388 |
Marks/Unmarks an item as risky. This flag is used for automatic marking of an item as INACTIVE in case of zero inventory.
|
|
|
389 |
*/
|
| 2356 |
ankur.sing |
390 |
void changeItemRiskyFlag(1:i64 itemId, 2:bool risky),
|
|
|
391 |
|
|
|
392 |
/**
|
|
|
393 |
Returns list of items marked as risky.
|
|
|
394 |
*/
|
|
|
395 |
list<Item> getItemsByRiskyFlag(),
|
|
|
396 |
|
|
|
397 |
/**
|
| 4957 |
phani.kuma |
398 |
Returns list of items with any status except PHASED_OUT and filtered by category, brand.
|
| 2356 |
ankur.sing |
399 |
*/
|
| 4957 |
phani.kuma |
400 |
list<Item> getItemsForMasterSheet(1:string category, 2:string brand),
|
| 2807 |
rajveer |
401 |
|
|
|
402 |
/**
|
|
|
403 |
Returns list of catalog ids of items with same similarity index as of the given itemId
|
|
|
404 |
*/
|
|
|
405 |
list<i64> getSimilarItemsCatalogIds(1:i64 beginIndex, 2:i64 totalItems, 3:i64 itemId),
|
| 3079 |
rajveer |
406 |
|
|
|
407 |
/**
|
|
|
408 |
Add user requests for out of stock items. Once user will ask for notify me an entry will
|
|
|
409 |
*/
|
| 3086 |
rajveer |
410 |
bool addProductNotification(i64 itemId, string email),
|
| 3079 |
rajveer |
411 |
|
| 3086 |
rajveer |
412 |
/**
|
|
|
413 |
Send the product notifications to the users for items which has stock.
|
|
|
414 |
*/
|
| 3348 |
varun.gupt |
415 |
bool sendProductNotifications(),
|
| 3079 |
rajveer |
416 |
|
| 3348 |
varun.gupt |
417 |
/**
|
|
|
418 |
Returns list of brand names for a given category Id
|
|
|
419 |
*/
|
| 3556 |
rajveer |
420 |
list<string> getAllBrandsByCategory(1:i64 categoryId),
|
| 4957 |
phani.kuma |
421 |
|
|
|
422 |
/**
|
|
|
423 |
Returns list of brand names
|
|
|
424 |
*/
|
|
|
425 |
list<string> getAllBrands(),
|
|
|
426 |
|
| 3556 |
rajveer |
427 |
/**
|
|
|
428 |
Return list of all sources
|
|
|
429 |
*/
|
|
|
430 |
list<Source> getAllSources(),
|
|
|
431 |
|
|
|
432 |
/**
|
|
|
433 |
Returns the pricing information of an item. If no information is found, exception will be thrown.
|
|
|
434 |
*/
|
|
|
435 |
SourceItemPricing getItemPricingBySource(1:i64 itemId, 2:i64 sourceId) throws (1:InventoryServiceException cex),
|
|
|
436 |
|
|
|
437 |
/**
|
|
|
438 |
Adds prices to be displayed corresponding to the item if user comes from a source.
|
|
|
439 |
If item is not found or source is not found, it will throw exception.
|
|
|
440 |
*/
|
|
|
441 |
void addSourceItemPricing(1:SourceItemPricing sourceItemPricing) throws (1:InventoryServiceException cex),
|
|
|
442 |
|
|
|
443 |
/**
|
|
|
444 |
Returns the list of source pricing information of an item.
|
|
|
445 |
Raises an exception if item not found corresponding to itemId
|
|
|
446 |
*/
|
|
|
447 |
list<SourceItemPricing> getAllSourcePricing(1:i64 itemId) throws (1:InventoryServiceException cex),
|
|
|
448 |
|
|
|
449 |
/**
|
|
|
450 |
Get the item for a given itemId and sourceId. MRP and sellingPrice will be updated for source if we have different prices for source.
|
|
|
451 |
*/
|
| 3872 |
chandransh |
452 |
Item getItemForSource(1:i64 item_id, 2:optional i64 sourceId) throws (1:InventoryServiceException cex),
|
|
|
453 |
|
|
|
454 |
/**
|
|
|
455 |
Searches items matching the the given terms in the catalog and returns results within the specified range.
|
|
|
456 |
*/
|
|
|
457 |
list<Item> searchItemsInRange(1:list<string> searchTerms, 2:i64 offset, 3:i64 limit),
|
|
|
458 |
|
|
|
459 |
/**
|
|
|
460 |
Gets the count of search results for the given search terms so that the user can go through all the pages.
|
|
|
461 |
*/
|
| 4024 |
chandransh |
462 |
i32 getSearchResultCount(1:list<string> searchTerms),
|
|
|
463 |
|
|
|
464 |
/**
|
| 4063 |
chandransh |
465 |
Returns a list of inventory stock for items for which there are pending orders for the given vendor.
|
| 4024 |
chandransh |
466 |
*/
|
| 4295 |
varun.gupt |
467 |
list<AvailableAndReservedStock> getPendingOrdersInventory(1:i64 vendorid),
|
|
|
468 |
|
|
|
469 |
/**
|
|
|
470 |
Returns a list of product notifications added after a supplied datetime
|
|
|
471 |
*/
|
|
|
472 |
list<ProductNotificationRequest> getProductNotifications(1:i64 startDateTime),
|
|
|
473 |
|
|
|
474 |
/**
|
|
|
475 |
Returns a list of count of requests for product notification against each item
|
|
|
476 |
*/
|
|
|
477 |
list<ProductNotificationRequestCount> getProductNotificationRequestCount(1:i64 startDateTime)
|
| 4370 |
anupam.sin |
478 |
|
|
|
479 |
/**
|
|
|
480 |
This method creates a purchase order from an excel sheet containing Item Id and Quantity column and returns the PO Id.
|
|
|
481 |
*/
|
|
|
482 |
string processPurchaseOrder(1:string filename 2:i32 vendorId) throws (1:InventoryServiceException cex)
|
| 4649 |
phani.kuma |
483 |
|
|
|
484 |
/**
|
|
|
485 |
This method adds a log to authorize table with Item Id, username who authorized the change, reason.
|
|
|
486 |
*/
|
|
|
487 |
bool addAuthorizationLog(1:i64 itemId, 2:string username, 3:string reason) throws (1:InventoryServiceException cex)
|
| 4295 |
varun.gupt |
488 |
}
|