UNPKG

wechat-work

Version:
32 lines 1.59 kB
"use strict"; var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { extendStatics(d, b); function __() { this.constructor = d; } d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); }; })(); Object.defineProperty(exports, "__esModule", { value: true }); var app_message_type_enum_1 = require("../enums/app-message-type.enum"); var app_message_base_class_1 = require("./app-message-base.class"); var NewsAppMessage = /** @class */ (function (_super) { __extends(NewsAppMessage, _super); function NewsAppMessage(articles, agentId, targetUserIds, targetDepartmentIds, targetTags, safe) { var _this = this; if (!targetUserIds && !targetDepartmentIds && !targetTags) { throw Error("one of targetUserIds,targetDepartmentIds,targetTags should be set."); } _this = _super.call(this, targetUserIds, targetDepartmentIds, targetTags, agentId, app_message_type_enum_1.EnumAppMessageType.Text, safe) || this; _this.news = { articles: articles }; return _this; } return NewsAppMessage; }(app_message_base_class_1.AppMessageBase)); exports.NewsAppMessage = NewsAppMessage; //# sourceMappingURL=news-app-message.class.js.map