@overmap-ai/core 1.0.78-identifiers.2 → 1.0.78-identifiers.4

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.
@@ -2810,7 +2810,7 @@ const $ = P(
2810
2810
  return b(t.filter((n) => i.has(n.uuid)));
2811
2811
  })
2812
2812
  ), bI = A(
2813
- p([oc, (t, e) => e], (t, e) => b(t.filter((s) => s.organization_owner === e)))
2813
+ p([oc, (t, e) => e], (t, e) => b(t.filter((s) => s.organization === e)))
2814
2814
  ), vm = {
2815
2815
  isRehydrated: !1
2816
2816
  }, dc = T({
@@ -5757,7 +5757,7 @@ class h_ extends v {
5757
5757
  method: o.GET,
5758
5758
  url: "/categories/",
5759
5759
  queryParams: {
5760
- project__organization_owner: e
5760
+ project__organization: e
5761
5761
  },
5762
5762
  blocks: [],
5763
5763
  blockers: []
@@ -5871,7 +5871,7 @@ class p_ extends He {
5871
5871
  method: o.GET,
5872
5872
  url: "/document-attachments/",
5873
5873
  queryParams: {
5874
- document__project__organization_owner: s
5874
+ document__project__organization: s
5875
5875
  },
5876
5876
  blocks: [],
5877
5877
  blockers: []
@@ -5969,7 +5969,7 @@ class m_ extends v {
5969
5969
  method: o.GET,
5970
5970
  url: "/documents/",
5971
5971
  queryParams: {
5972
- project__organization_owner: e
5972
+ project__organization: e
5973
5973
  },
5974
5974
  blockers: [],
5975
5975
  blocks: []
@@ -8187,21 +8187,25 @@ class G_ extends v {
8187
8187
  }
8188
8188
  class B_ extends v {
8189
8189
  add(e) {
8190
- const s = _(e);
8191
- this.dispatch($n(s));
8192
- const i = this.enqueueRequest({
8190
+ var a;
8191
+ const { store: s } = this.client, i = _({
8192
+ ...e,
8193
+ created_by: (a = s.getState().userReducer.currentUser) == null ? void 0 : a.id
8194
+ });
8195
+ this.dispatch($n(i));
8196
+ const n = this.enqueueRequest({
8193
8197
  description: "Add project access",
8194
8198
  method: o.POST,
8195
8199
  url: "/project-accesses/",
8196
- payload: k(s),
8197
- blockers: [s.organization_access, s.project],
8198
- blocks: [s.uuid]
8200
+ payload: k(i),
8201
+ blockers: [i.organization_access, i.project],
8202
+ blocks: [i.uuid]
8199
8203
  });
8200
- return i.then((n) => {
8201
- this.dispatch(St(n));
8202
- }).catch((n) => {
8203
- throw this.dispatch(Gn(s.uuid)), n;
8204
- }), [s, i];
8204
+ return n.then((r) => {
8205
+ this.dispatch(St(r));
8206
+ }).catch((r) => {
8207
+ throw this.dispatch(Gn(i.uuid)), r;
8208
+ }), [i, n];
8205
8209
  }
8206
8210
  update(e) {
8207
8211
  const { store: s } = this.client, i = Bn(e.uuid)(s.getState()), n = {
@@ -8246,7 +8250,7 @@ class B_ extends v {
8246
8250
  method: o.GET,
8247
8251
  url: "/project-accesses/",
8248
8252
  queryParams: {
8249
- project__organization_owner: e
8253
+ project__organization: e
8250
8254
  },
8251
8255
  blockers: [],
8252
8256
  blocks: []
@@ -8300,7 +8304,7 @@ class L_ extends He {
8300
8304
  method: o.GET,
8301
8305
  url: `${this.url}/`,
8302
8306
  queryParams: {
8303
- project__organization_owner: s
8307
+ project__organization: s
8304
8308
  },
8305
8309
  blockers: [],
8306
8310
  blocks: []
@@ -8462,7 +8466,7 @@ class H_ extends v {
8462
8466
  method: o.GET,
8463
8467
  url: "/projects/",
8464
8468
  queryParams: {
8465
- organization_owner: e
8469
+ organization: e
8466
8470
  },
8467
8471
  blockers: [],
8468
8472
  blocks: []
@@ -8474,21 +8478,25 @@ class H_ extends v {
8474
8478
  }
8475
8479
  class W_ extends v {
8476
8480
  add(e) {
8477
- const s = _(e);
8478
- this.dispatch(Em(s));
8479
- const i = this.enqueueRequest({
8481
+ var a;
8482
+ const { store: s } = this.client, i = _({
8483
+ ...e,
8484
+ created_by: (a = s.getState().userReducer.currentUser) == null ? void 0 : a.id
8485
+ });
8486
+ this.dispatch(Em(i));
8487
+ const n = this.enqueueRequest({
8480
8488
  description: "Create team membership",
8481
8489
  method: o.POST,
8482
8490
  url: "/team-memberships/",
8483
- payload: k(s),
8491
+ payload: k(i),
8484
8492
  blockers: [e.team],
8485
- blocks: [s.uuid]
8493
+ blocks: [i.uuid]
8486
8494
  });
8487
- return i.then((n) => {
8488
- this.dispatch(Jn(n));
8495
+ return n.then((r) => {
8496
+ this.dispatch(Jn(r));
8489
8497
  }).catch(() => {
8490
- this.dispatch(Xn(s.uuid));
8491
- }), [s, i];
8498
+ this.dispatch(Xn(i.uuid));
8499
+ }), [i, n];
8492
8500
  }
8493
8501
  async delete(e) {
8494
8502
  const { store: s } = this.client, i = s.getState(), n = jm(e)(i);
@@ -8527,26 +8535,26 @@ class W_ extends v {
8527
8535
  }
8528
8536
  class K_ extends v {
8529
8537
  add(e) {
8530
- const s = _({
8538
+ var a;
8539
+ const { store: s } = this.client, i = _({
8531
8540
  ...e,
8532
- submitted_at: (/* @__PURE__ */ new Date()).toISOString()
8533
- // TODO: uncomment once supported
8534
- // created_by: state.userReducer.currentUser.uuid,
8541
+ submitted_at: (/* @__PURE__ */ new Date()).toISOString(),
8542
+ created_by: (a = s.getState().userReducer.currentUser) == null ? void 0 : a.id
8535
8543
  });
8536
- this.dispatch(zm(s));
8537
- const i = this.enqueueRequest({
8544
+ this.dispatch(zm(i));
8545
+ const n = this.enqueueRequest({
8538
8546
  description: "Create team",
8539
8547
  method: o.POST,
8540
8548
  url: "/teams/",
8541
- payload: k(s),
8549
+ payload: k(i),
8542
8550
  blockers: [],
8543
- blocks: [s.uuid]
8551
+ blocks: [i.uuid]
8544
8552
  });
8545
- return i.then((n) => {
8546
- this.dispatch(Tt(n));
8553
+ return n.then((r) => {
8554
+ this.dispatch(Tt(r));
8547
8555
  }).catch(() => {
8548
- this.dispatch(ea(s.uuid));
8549
- }), [s, i];
8556
+ this.dispatch(ea(i.uuid));
8557
+ }), [i, n];
8550
8558
  }
8551
8559
  update(e) {
8552
8560
  const { store: s } = this.client, i = ta(e.uuid)(s.getState());