UNPKG

devexpress-reporting

Version:

DevExpress Reporting provides the capability to develop a reporting application to create and customize reports.

71 lines (70 loc) 3.46 kB
/** * DevExpress HTML/JS Reporting (designer\controls\xrCrossTab.js) * Version: 20.2.13 * Build date: Apr 10, 2023 * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED * License: https://www.devexpress.com/Support/EULAs/universal.xml */ "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 ko = require("knockout"); var analytics_internal_1 = require("@devexpress/analytics-core/analytics-internal"); var analytics_utils_1 = require("@devexpress/analytics-core/analytics-utils"); var settings_1 = require("../utils/settings"); var metadata_1 = require("./metadata/properties/metadata"); var metadataGroups_1 = require("./metadata/properties/metadataGroups"); var xrControl_1 = require("./xrControl"); var _xrTodoControl_1 = require("./_xrTodoControl"); var XRCrossTabViewModel = (function (_super) { __extends(XRCrossTabViewModel, _super); function XRCrossTabViewModel(model, parent, serializer) { if (serializer === void 0) { serializer = new analytics_utils_1.ModelSerializer(); } var _this = _super.call(this, model, parent, serializer) || this; _this.cells = analytics_utils_1.deserializeArray(model['Cells'], function (item) { return new CrossTabCellViewModel(item, _this, serializer); }); return _this; } XRCrossTabViewModel.prototype.getControlFactory = function () { return settings_1.controlsFactory(); }; return XRCrossTabViewModel; }(_xrTodoControl_1.UnknownViewModel)); exports.XRCrossTabViewModel = XRCrossTabViewModel; var CrossTabCellViewModel = (function (_super) { __extends(CrossTabCellViewModel, _super); function CrossTabCellViewModel(model, parent, serializer) { if (serializer === void 0) { serializer = new analytics_utils_1.ModelSerializer(); } return _super.call(this, model, parent, serializer) || this; } CrossTabCellViewModel.prototype.getInfo = function () { return metadataGroups_1.unknownSerializationsInfo.concat([metadata_1.text]); }; CrossTabCellViewModel.prototype.getControlFactory = function () { return settings_1.controlsFactory(); }; return CrossTabCellViewModel; }(_xrTodoControl_1.UnknownViewModel)); exports.CrossTabCellViewModel = CrossTabCellViewModel; var XRCrossTabSurface = (function (_super) { __extends(XRCrossTabSurface, _super); function XRCrossTabSurface(control, context) { var _this = _super.call(this, control, context) || this; _this.cells = ko.observableArray(); _this._disposables.push(analytics_internal_1.createObservableArrayMapCollection(control.cells, _this.cells, function (item) { return new xrControl_1.XRControlSurface(item, context); })); return _this; } return XRCrossTabSurface; }(xrControl_1.XRControlSurface)); exports.XRCrossTabSurface = XRCrossTabSurface;