mirror of
https://github.com/cheveguerra/whatsapp-web.js.git
synced 2026-04-18 03:29:14 +00:00
* - Get products and orders * - Get products and orders * - Eslint fixes * - Eslint fixes * allow downloading media for products * products and orders work on normal accounts Co-authored-by: Renato Jop <renato.jop@consystec-corp.com> Co-authored-by: Pedro Lopez <pedroslopez@me.com> Co-authored-by: Pedro S. Lopez <pslamoros@hotmail.com>
25 lines
533 B
JavaScript
25 lines
533 B
JavaScript
const Base = require('./Base');
|
|
|
|
class ProductMetadata extends Base {
|
|
constructor(client, data) {
|
|
super(client);
|
|
|
|
if (data) this._patch(data);
|
|
}
|
|
|
|
_patch(data) {
|
|
/** Product ID */
|
|
this.id = data.id;
|
|
/** Retailer ID */
|
|
this.retailer_id = data.retailer_id;
|
|
/** Product Name */
|
|
this.name = data.name;
|
|
/** Product Description */
|
|
this.description = data.description;
|
|
|
|
return super._patch(data);
|
|
}
|
|
|
|
}
|
|
|
|
module.exports = ProductMetadata; |