Built files from Bizgaze WebServer
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

partitionmanager.js 2.7KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
  2. function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
  3. return new (P || (P = Promise))(function (resolve, reject) {
  4. function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
  5. function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
  6. function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
  7. step((generator = generator.apply(thisArg, _arguments || [])).next());
  8. });
  9. };
  10. var Unibase;
  11. (function (Unibase) {
  12. let Platform;
  13. (function (Platform) {
  14. let Apps;
  15. (function (Apps) {
  16. let Managers;
  17. (function (Managers) {
  18. class PartitionManager extends Platform.Core.BaseManager {
  19. createPartitionTables(PartitionId) {
  20. return __awaiter(this, void 0, void 0, function* () {
  21. const url = 'apis/v4/unibase/platform/partitions/createpartitiontables/partitionid/' + PartitionId;
  22. return yield this.dataHelper().postAsync(url, null).then(function (response) {
  23. if (response.result !== null)
  24. response.result = JSON.parse(response.result);
  25. return response;
  26. });
  27. });
  28. }
  29. refreshAllPartitions() {
  30. return __awaiter(this, void 0, void 0, function* () {
  31. const url = 'apis/v4/unibase/platform/partitions/refreshallpartitions/np';
  32. return yield this.dataHelper().postAsync(url, null).then(function (response) {
  33. if (response.result !== null)
  34. response.result = JSON.parse(response.result);
  35. return response;
  36. });
  37. });
  38. }
  39. static Instance() {
  40. if (this._instance === undefined)
  41. this._instance = new PartitionManager();
  42. return this._instance;
  43. }
  44. }
  45. Managers.PartitionManager = PartitionManager;
  46. })(Managers = Apps.Managers || (Apps.Managers = {}));
  47. })(Apps = Platform.Apps || (Platform.Apps = {}));
  48. })(Platform = Unibase.Platform || (Unibase.Platform = {}));
  49. })(Unibase || (Unibase = {}));