bx-rest 0.1.5 → 0.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -754,7 +754,6 @@ class SessionKeyServices extends BaseServices {
754
754
  getAuth() {
755
755
  switch (BX_REST_SETTINGS.auth.key) {
756
756
  case 'auth':
757
- console.log('Cookies.get(\'auth\')', CookiesServices.get('auth'));
758
757
  return CookiesServices.get('auth');
759
758
  default:
760
759
  if (window.BX && window.BX.bitrix_sessid()) {
@@ -806,7 +805,6 @@ class SessionKeyServices extends BaseServices {
806
805
  return false;
807
806
  }
808
807
  getAuthParams() {
809
- console.log('BX_REST_SETTINGS', BX_REST_SETTINGS);
810
808
  switch (BX_REST_SETTINGS.auth.source) {
811
809
  case 'cookies':
812
810
  return this.getAuth();
@@ -1225,7 +1223,9 @@ const $kill = 'kill';
1225
1223
  const $template = 'template';
1226
1224
  const $activity = 'activity';
1227
1225
  const $robot = 'robot';
1228
- const $send = 'send';
1226
+ const $send = 'send';
1227
+ const $share = 'share';
1228
+ const $blogcomment = 'blogcomment';
1229
1229
 
1230
1230
  class BaseMapServices extends BaseServices {
1231
1231
  }
@@ -1816,6 +1816,64 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
1816
1816
  }]
1817
1817
  }], ctorParameters: function () { return [{ type: BXRestBizprocWorkflow }, { type: BXRestBizprocActivity }, { type: BXRestBizprocTask }, { type: BXRestBizprocRobot }, { type: BXRestBizprocEvent }]; } });
1818
1818
 
1819
+ class BXRestLogBlogPost {
1820
+ constructor(http) {
1821
+ this.http = http;
1822
+ this.url = {
1823
+ add: [$log, $blogpost, $add],
1824
+ // getusers: {
1825
+ // important: 'log.blogpost.getusers.important' // Отдает массив ID пользователей, прочитавших Важное сообщение
1826
+ // },
1827
+ get: [$log, $blogpost, $get],
1828
+ delete: [$log, $blogpost, $delete],
1829
+ share: [$log, $blogpost, $share],
1830
+ update: [$log, $blogpost, $update], // Изменяет сообщение Живой Ленты
1831
+ };
1832
+ }
1833
+ add(param) {
1834
+ return this.http.post(this.url.add, param);
1835
+ }
1836
+ }
1837
+ BXRestLogBlogPost.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestLogBlogPost, deps: [{ token: HttpBXServices }], target: i0.ɵɵFactoryTarget.Injectable });
1838
+ BXRestLogBlogPost.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestLogBlogPost, providedIn: 'root' });
1839
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestLogBlogPost, decorators: [{
1840
+ type: Injectable,
1841
+ args: [{
1842
+ providedIn: 'root'
1843
+ }]
1844
+ }], ctorParameters: function () { return [{ type: HttpBXServices }]; } });
1845
+
1846
+ class BXRestLogBlogComment {
1847
+ constructor() {
1848
+ this.url = {
1849
+ add: [$log, $blogcomment, $add], // Добавляет комментарий к сообщению Живой ленты
1850
+ };
1851
+ }
1852
+ }
1853
+ BXRestLogBlogComment.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestLogBlogComment, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1854
+ BXRestLogBlogComment.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestLogBlogComment, providedIn: 'root' });
1855
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestLogBlogComment, decorators: [{
1856
+ type: Injectable,
1857
+ args: [{
1858
+ providedIn: 'root'
1859
+ }]
1860
+ }] });
1861
+
1862
+ class BXRestLog {
1863
+ constructor(blogPost, blogComment) {
1864
+ this.blogPost = blogPost;
1865
+ this.blogComment = blogComment;
1866
+ }
1867
+ }
1868
+ BXRestLog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestLog, deps: [{ token: BXRestLogBlogPost }, { token: BXRestLogBlogComment }], target: i0.ɵɵFactoryTarget.Injectable });
1869
+ BXRestLog.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestLog, providedIn: 'root' });
1870
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestLog, decorators: [{
1871
+ type: Injectable,
1872
+ args: [{
1873
+ providedIn: 'root'
1874
+ }]
1875
+ }], ctorParameters: function () { return [{ type: BXRestLogBlogPost }, { type: BXRestLogBlogComment }]; } });
1876
+
1819
1877
  class Navvy {
1820
1878
  constructor(snackBar) {
1821
1879
  this.snackBar = snackBar;
@@ -2600,6 +2658,65 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
2600
2658
  }]
2601
2659
  }], ctorParameters: function () { return [{ type: BXRestNavvyBizprocWorkflow }, { type: BXRestNavvyLists }]; } });
2602
2660
 
2661
+ class BXRestNavvyLogBlogPost {
2662
+ constructor(BXRestLogBlogPost, Navvy) {
2663
+ this.BXRestLogBlogPost = BXRestLogBlogPost;
2664
+ this.Navvy = Navvy;
2665
+ this.url = {
2666
+ add: [$log, $blogpost, $add],
2667
+ // getusers: {
2668
+ // important: 'log.blogpost.getusers.important' // Отдает массив ID пользователей, прочитавших Важное сообщение
2669
+ // },
2670
+ get: [$log, $blogpost, $get],
2671
+ delete: [$log, $blogpost, $delete],
2672
+ share: [$log, $blogpost, $share],
2673
+ update: [$log, $blogpost, $update], // Изменяет сообщение Живой Ленты
2674
+ };
2675
+ }
2676
+ add(param) {
2677
+ return this.Navvy.mapAndSnackBarError(this.BXRestLogBlogPost.add(param), 'При добавлении поста');
2678
+ }
2679
+ }
2680
+ BXRestNavvyLogBlogPost.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvyLogBlogPost, deps: [{ token: BXRestLogBlogPost }, { token: Navvy }], target: i0.ɵɵFactoryTarget.Injectable });
2681
+ BXRestNavvyLogBlogPost.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvyLogBlogPost, providedIn: 'root' });
2682
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvyLogBlogPost, decorators: [{
2683
+ type: Injectable,
2684
+ args: [{
2685
+ providedIn: 'root'
2686
+ }]
2687
+ }], ctorParameters: function () { return [{ type: BXRestLogBlogPost }, { type: Navvy }]; } });
2688
+
2689
+ class BXRestNavvyLogBlogComment {
2690
+ constructor() {
2691
+ this.url = {
2692
+ add: [$log, $blogcomment, $add], // Добавляет комментарий к сообщению Живой ленты
2693
+ };
2694
+ }
2695
+ }
2696
+ BXRestNavvyLogBlogComment.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvyLogBlogComment, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
2697
+ BXRestNavvyLogBlogComment.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvyLogBlogComment, providedIn: 'root' });
2698
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvyLogBlogComment, decorators: [{
2699
+ type: Injectable,
2700
+ args: [{
2701
+ providedIn: 'root'
2702
+ }]
2703
+ }] });
2704
+
2705
+ class BXRestNavvyLog {
2706
+ constructor(blogPost, blogComment) {
2707
+ this.blogPost = blogPost;
2708
+ this.blogComment = blogComment;
2709
+ }
2710
+ }
2711
+ BXRestNavvyLog.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvyLog, deps: [{ token: BXRestNavvyLogBlogPost }, { token: BXRestNavvyLogBlogComment }], target: i0.ɵɵFactoryTarget.Injectable });
2712
+ BXRestNavvyLog.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvyLog, providedIn: 'root' });
2713
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvyLog, decorators: [{
2714
+ type: Injectable,
2715
+ args: [{
2716
+ providedIn: 'root'
2717
+ }]
2718
+ }], ctorParameters: function () { return [{ type: BXRestNavvyLogBlogPost }, { type: BXRestNavvyLogBlogComment }]; } });
2719
+
2603
2720
  class BXRestMapLists extends BaseMapServices {
2604
2721
  constructor(element) {
2605
2722
  super();
@@ -2616,39 +2733,41 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
2616
2733
  }], ctorParameters: function () { return [{ type: BXRestMapListsElement }]; } });
2617
2734
 
2618
2735
  class BXRest {
2619
- constructor(user, lists, tasks, disk, bizproc) {
2736
+ constructor(user, lists, tasks, disk, bizproc, log) {
2620
2737
  this.user = user;
2621
2738
  this.lists = lists;
2622
2739
  this.tasks = tasks;
2623
2740
  this.disk = disk;
2624
2741
  this.bizproc = bizproc;
2742
+ this.log = log;
2625
2743
  }
2626
2744
  }
2627
- BXRest.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRest, deps: [{ token: BXRestUser }, { token: BXRestLists }, { token: BXRestTasks }, { token: BXRestDisk }, { token: BXRestBizproc }], target: i0.ɵɵFactoryTarget.Injectable });
2745
+ BXRest.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRest, deps: [{ token: BXRestUser }, { token: BXRestLists }, { token: BXRestTasks }, { token: BXRestDisk }, { token: BXRestBizproc }, { token: BXRestLog }], target: i0.ɵɵFactoryTarget.Injectable });
2628
2746
  BXRest.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRest, providedIn: 'root' });
2629
2747
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRest, decorators: [{
2630
2748
  type: Injectable,
2631
2749
  args: [{
2632
2750
  providedIn: 'root'
2633
2751
  }]
2634
- }], ctorParameters: function () { return [{ type: BXRestUser }, { type: BXRestLists }, { type: BXRestTasks }, { type: BXRestDisk }, { type: BXRestBizproc }]; } });
2752
+ }], ctorParameters: function () { return [{ type: BXRestUser }, { type: BXRestLists }, { type: BXRestTasks }, { type: BXRestDisk }, { type: BXRestBizproc }, { type: BXRestLog }]; } });
2635
2753
  class BXRestNavvy {
2636
- constructor(user, lists, tasks, disk, bizproc) {
2754
+ constructor(user, lists, tasks, disk, bizproc, log) {
2637
2755
  this.user = user;
2638
2756
  this.lists = lists;
2639
2757
  this.tasks = tasks;
2640
2758
  this.disk = disk;
2641
2759
  this.bizproc = bizproc;
2760
+ this.log = log;
2642
2761
  }
2643
2762
  }
2644
- BXRestNavvy.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvy, deps: [{ token: BXRestNavvyUser }, { token: BXRestNavvyLists }, { token: BXRestNavvyTasks }, { token: BXRestNavvyDisk }, { token: BXRestNavvyBizproc }], target: i0.ɵɵFactoryTarget.Injectable });
2763
+ BXRestNavvy.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvy, deps: [{ token: BXRestNavvyUser }, { token: BXRestNavvyLists }, { token: BXRestNavvyTasks }, { token: BXRestNavvyDisk }, { token: BXRestNavvyBizproc }, { token: BXRestNavvyLog }], target: i0.ɵɵFactoryTarget.Injectable });
2645
2764
  BXRestNavvy.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvy, providedIn: 'root' });
2646
2765
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: BXRestNavvy, decorators: [{
2647
2766
  type: Injectable,
2648
2767
  args: [{
2649
2768
  providedIn: 'root'
2650
2769
  }]
2651
- }], ctorParameters: function () { return [{ type: BXRestNavvyUser }, { type: BXRestNavvyLists }, { type: BXRestNavvyTasks }, { type: BXRestNavvyDisk }, { type: BXRestNavvyBizproc }]; } });
2770
+ }], ctorParameters: function () { return [{ type: BXRestNavvyUser }, { type: BXRestNavvyLists }, { type: BXRestNavvyTasks }, { type: BXRestNavvyDisk }, { type: BXRestNavvyBizproc }, { type: BXRestNavvyLog }]; } });
2652
2771
  class BXRestMap {
2653
2772
  constructor(lists) {
2654
2773
  this.lists = lists;