primary_care_admin_binder 0.1.199 → 0.1.200

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.
Files changed (2) hide show
  1. package/dist/index.cjs.js +14 -36
  2. package/package.json +1 -1
package/dist/index.cjs.js CHANGED
@@ -8285,14 +8285,15 @@ var fetchData = /*#__PURE__*/function () {
8285
8285
  // in-memory AuthContext on login/refresh - this package can't import that
8286
8286
  // module directly, and the token is intentionally never persisted to
8287
8287
  // localStorage, so a plain window global is the bridge.
8288
- token = jwtToken || (typeof window !== "undefined" ? window.binderAuthToken : undefined);
8288
+ token = jwtToken || (typeof window !== "undefined" ? window.token : undefined);
8289
8289
  __options = {
8290
8290
  method: "POST",
8291
8291
  credentials: "include",
8292
- headers: token ? {
8292
+ headers: token ? _objectSpread2({
8293
8293
  "Content-Type": "application/json"
8294
- // "jwtToken": token
8295
- } : {
8294
+ }, token && {
8295
+ "jwtToken": token
8296
+ }) : {
8296
8297
  "Content-Type": "application/json"
8297
8298
  },
8298
8299
  body: {}
@@ -25097,50 +25098,27 @@ var DRUG_MASTER_SAVE = createAsyncThunk("drugMasterSlice/drug_catalog_master_sav
25097
25098
  })));
25098
25099
  var RULE_GROUP_DROPDOWN = createAsyncThunk("drugMasterSlice/getGroup", /*#__PURE__*/function () {
25099
25100
  var _ref24 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee13(payload, action) {
25100
- var _rejectWithValue, body, options, _res, response, _t10;
25101
+ var response, _t10;
25101
25102
  return _regenerator().w(function (_context13) {
25102
25103
  while (1) switch (_context13.p = _context13.n) {
25103
25104
  case 0:
25104
25105
  _context13.p = 0;
25105
- _rejectWithValue = action.rejectWithValue;
25106
- body = {};
25107
- body = JSON.stringify(drugCatalogMasterQuery$1.ruleGroup());
25108
- options = {
25109
- method: "Post",
25110
- headers: {
25111
- "Content-Type": "application/json",
25112
- Accept: "application/json"
25113
- },
25114
- body: body
25115
- };
25106
+ action.rejectWithValue;
25116
25107
  _context13.n = 1;
25117
- return fetch(__readQdmQueries__, options);
25108
+ return fetchData({
25109
+ body: JSON.stringify(drugCatalogMasterQuery$1.ruleGroup())
25110
+ }, __readQdmQueries__);
25118
25111
  case 1:
25119
- _res = _context13.v;
25120
- if (_res.ok) {
25121
- _context13.n = 2;
25122
- break;
25123
- }
25124
- return _context13.a(2, _rejectWithValue(_objectSpread2(_objectSpread2({}, defaultReject), {}, {
25125
- message: _res === null || _res === void 0 ? void 0 : _res.statusText,
25126
- Code: _res.status
25127
- })));
25128
- case 2:
25129
- _context13.n = 3;
25130
- return _res.json();
25131
- case 3:
25132
25112
  response = _context13.v;
25133
- return _context13.a(2, _objectSpread2(_objectSpread2({}, response), {}, {
25134
- Code: _res.status
25135
- }));
25136
- case 4:
25137
- _context13.p = 4;
25113
+ return _context13.a(2, response);
25114
+ case 2:
25115
+ _context13.p = 2;
25138
25116
  _t10 = _context13.v;
25139
25117
  return _context13.a(2, rejectWithValue(_objectSpread2(_objectSpread2({}, defaultReject), {}, {
25140
25118
  message: _t10.message
25141
25119
  })));
25142
25120
  }
25143
- }, _callee13, null, [[0, 4]]);
25121
+ }, _callee13, null, [[0, 2]]);
25144
25122
  }));
25145
25123
  return function (_x6, _x7) {
25146
25124
  return _ref24.apply(this, arguments);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "primary_care_admin_binder",
3
- "version": "0.1.199",
3
+ "version": "0.1.200",
4
4
  "description": "",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.esm.js",