@gct-paas/excel 0.1.39-beta.47 → 0.1.39-beta.48

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 (65) hide show
  1. package/dist/{BaseComponent-B4z-0IvX.js → BaseComponent-CkMnlfWd.js} +1 -1
  2. package/dist/{barcode-design-CkIF3AdC.js → barcode-design-BNIpxEzc.js} +1 -1
  3. package/dist/base/index.es.js +4 -4
  4. package/dist/{diagonal-design-CBGnh101.js → diagonal-design-6V7cgcn8.js} +1 -1
  5. package/dist/{dynamic-table-action-ZAmTIvcp.js → dynamic-table-action-BP2qzgdK.js} +16 -1
  6. package/dist/excel.css +2 -2
  7. package/dist/{exceljs.min-BdYR3omv.js → exceljs.min-U1z8AVud.js} +1 -1
  8. package/dist/{font-editor-C40nR0g-.js → font-editor-CSzJYS59.js} +1 -1
  9. package/dist/{index-BhwTs4qO.js → index-B3YLauBl.js} +1 -1
  10. package/dist/{index-9bqJP9tH.js → index-BB53z_-a.js} +1 -1
  11. package/dist/{index-DxBNlXoA.js → index-BJJhezsz.js} +1 -1
  12. package/dist/{index-CJNVJa0j.js → index-BcC37bc7.js} +1 -1
  13. package/dist/{index-CSl64wAM.js → index-Bv0fTe8J.js} +2 -2
  14. package/dist/{index-YqLRgg7Y.js → index-CNRHbj9w.js} +1 -1
  15. package/dist/{index-CwFhzKly.js → index-CUGjf_Fd.js} +1 -1
  16. package/dist/{index-DHtjlchw.js → index-CbuzkPgj.js} +153 -134
  17. package/dist/{index-6v9F3V5a.js → index-CpkuDCgX.js} +2 -2
  18. package/dist/{index-BTUEzj0j.js → index-CySEm8X9.js} +1 -1
  19. package/dist/{index-BJg7lRhl.js → index-D3hjkCfG.js} +1 -1
  20. package/dist/{index-BYLb70Wd.js → index-DCo1rBlu.js} +1 -1
  21. package/dist/{index-CLFvRsjI.js → index-DhqQJJs2.js} +1 -1
  22. package/dist/{index-jzjOcKYl.js → index-DnQudjER.js} +1 -1
  23. package/dist/{index-r-T7O_NL.js → index-DqfszGp-.js} +1 -1
  24. package/dist/{index-BQMXQ1X0.js → index-DvdGxeYk.js} +1 -1
  25. package/dist/{index-CRyXfD1E.js → index-DzTuqBBO.js} +1 -1
  26. package/dist/{index-CbkZXECS.js → index-GaM0ytTB.js} +2 -2
  27. package/dist/{index-DPrC3u3G.js → index-Kqrb380-.js} +2 -2
  28. package/dist/{index-BJOhGaZ4.js → index-OPfmMfF_.js} +1 -1
  29. package/dist/{index-C3YwX02a.js → index-Tipg-sO8.js} +1 -1
  30. package/dist/{index-BMTx6T5g.js → index-YkLm0Y3J.js} +2 -2
  31. package/dist/{index-Dp514iQN.js → index-xYZbueZ3.js} +2 -2
  32. package/dist/{index-C8ZmRWFO.js → index-yFn4abw6.js} +3 -3
  33. package/dist/index.es.js +1 -1
  34. package/dist/{pagination-design-DvuhHy_g.js → pagination-design-76z2fn1w.js} +1 -1
  35. package/dist/paper-widget-design-DUDTSxnG.js +4 -0
  36. package/dist/{print-runtime-instance-CjKnPN_O.js → print-runtime-instance-DY_6z5Uq.js} +1 -1
  37. package/dist/{print-snapshot-renderer-Cjtv_a17.js → print-snapshot-renderer-CqQ4eP1O.js} +3 -3
  38. package/dist/{qrcode-design-Bmz1I857.js → qrcode-design-U0jIXrqb.js} +1 -1
  39. package/dist/seal-design-Dw48cvB6.js +4 -0
  40. package/dist/{single-field-drop-DME3ih-W.js → single-field-drop-DbtML4gi.js} +1 -1
  41. package/dist/src/nocode-base/src/hooks/material-consume/material-consume-table-controller.d.ts +3 -1
  42. package/dist/src/nocode-base/src/hooks/material-consume/types.d.ts +2 -0
  43. package/dist/src/online-form/src/views/designer/hooks/useAllSpreadSheets.d.ts +12 -0
  44. package/dist/src/online-form/src/views/designer/hooks/useSpreadSheet.d.ts +9 -1
  45. package/dist/src/online-form/src/views/designer/modules/panel/panel-data-init-config/object-init/hooks/useObjectInit.d.ts +1 -0
  46. package/dist/src/online-form/src/views/designer/modules/panel/sub-table/comps/use-dynamic-sub-table-panel.d.ts +6 -0
  47. package/dist/src/online-form/src/views/designer/types/index.d.ts +2 -0
  48. package/dist/{sub-table-factory-9_e9NXAk.js → sub-table-factory-yVCjr6FI.js} +1 -1
  49. package/dist/{text-design-CCgUDgoT.js → text-design-dXb2-ItC.js} +1 -1
  50. package/dist/{trace-like-wrapper-BUq72oS3.js → trace-like-wrapper-Buykmr-D.js} +1 -1
  51. package/dist/{value-editor.vue_vue_type_style_index_0_lang-WNhb31ms.js → value-editor.vue_vue_type_style_index_0_lang-61EKSPm5.js} +1 -1
  52. package/dist/{widget-barcode-BZnKdE1G.js → widget-barcode-CxZ9Ttpq.js} +2 -2
  53. package/dist/{widget-diagonal-BklDdpSM.js → widget-diagonal-CdgIjqi5.js} +2 -2
  54. package/dist/{widget-image-C_UvhchS.js → widget-image-DbxFfFj0.js} +1 -1
  55. package/dist/{widget-line-DY28Dncn.js → widget-line-CLlxgXXK.js} +1 -1
  56. package/dist/{widget-pagination-CfYnms-D.js → widget-pagination-BVVkO_wj.js} +2 -2
  57. package/dist/{widget-power-CoFnc1vr.js → widget-power-BO7U8ObS.js} +2 -2
  58. package/dist/{widget-qrcode-CKMRpndx.js → widget-qrcode-BzgEPny7.js} +2 -2
  59. package/dist/{widget-rangelimit-yZ0Omj6J.js → widget-rangelimit-Bl3SsD07.js} +2 -2
  60. package/dist/{widget-serialnumber-SYVYekOJ.js → widget-serialnumber-DfZfCGyk.js} +1 -1
  61. package/dist/{widget-text-D6vtAr4i.js → widget-text-BmuYvZG5.js} +3 -3
  62. package/dist/{widget-timediff-FSvEPH5s.js → widget-timediff-hOTu4X-j.js} +1 -1
  63. package/package.json +1 -1
  64. package/dist/paper-widget-design-CAz9s6te.js +0 -4
  65. package/dist/seal-design-BDuIghlX.js +0 -4
@@ -1,4 +1,4 @@
1
- import { h as normalizeFieldWidth } from "./dynamic-table-action-ZAmTIvcp.js";
1
+ import { h as normalizeFieldWidth } from "./dynamic-table-action-BP2qzgdK.js";
2
2
  import { get, pick } from "lodash-es";
3
3
  import { F as FIELD_TYPE } from "./dynamic-table-action.vue_vue_type_style_index_0_scoped_53d7e66c_lang-DTkBFPUl.js";
4
4
  import { f as fontStyleAttrs } from "./config.enum-B8UZQTON.js";
@@ -1,6 +1,6 @@
1
1
  import { defineComponent, ref, computed, watch, openBlock, createElementBlock, normalizeStyle, normalizeClass, createElementVNode, toDisplayString, createCommentVNode } from "vue";
2
2
  import { pick } from "lodash-es";
3
- import { u as useSpreadSheet, h as useModelFields, l as loadBwip } from "./index-DHtjlchw.js";
3
+ import { u as useSpreadSheet, h as useModelFields, l as loadBwip } from "./index-CbuzkPgj.js";
4
4
  import { Q as PaperWidgeValueType, a7 as _export_sfc } from "./dynamic-table-action.vue_vue_type_style_index_0_scoped_53d7e66c_lang-DTkBFPUl.js";
5
5
  import "dayjs";
6
6
  import "ant-design-vue";
@@ -1,12 +1,12 @@
1
1
  import { E as api, _ as PlatformEnum, F as FIELD_TYPE, bc as getRowId, bd as findRuntimeTableRow, b5 as RenderModeEnum, C as ComponentTypeEnum, aF as Dependency_ENUM, aE as ASSIGNMENTSTRATEGY_ENUM, bn as fetchHistoryConsume, bo as isBomGranted, aT as renderUtils, bm as uuid2, bp as parseFrontConfig, aI as CheckDsTypeEnum, aC as transformUtils, bq as baseDataUtils, X as FormTypeEnum, br as normalizeToArray, bs as safeParseArray, bt as BpmnNodeTypeEnum, bu as mergeByMultiKey, a7 as _export_sfc, bv as evaluateInspectionDecisionRule, bw as useNocodeEmitter, bx as commonUtils, aG as EntityModelCategoryEnum } from "../dynamic-table-action.vue_vue_type_style_index_0_scoped_53d7e66c_lang-DTkBFPUl.js";
2
2
  import { aL, aN, a_, a0, by, bz, B, bA, y, af, bB, bC, bD, bb, bE, aQ, av, aM, aJ, aK, bF, ag, ak, bG, bH, aD, a2, ae, aw, aO, $, ai, L, bI, bJ, bK, O, p, P, a9, o, Q, A, bL, bM, au, at, a5, a1, a3, a4, a6, f, bN, aj, an, ah, bO, bP, bQ, bR, ba, bS, bT, bU, bV, bW, bX, bY, bZ, b_, b$, be, c0, c1, aW, c2, a$, b0, c3, c4, c5, c6, c7, c8, c9, ca, cb, cc, aV, cd, b1, b8, ce, cf, al, t, aP, cg, ch, bf, aX } from "../dynamic-table-action.vue_vue_type_style_index_0_scoped_53d7e66c_lang-DTkBFPUl.js";
3
- import { a2 as getRuntimeDataFieldId, O as parseRuntimeFieldPath, a3 as buildRuntimeFieldPath, a4 as resolveRuntimeFieldProps, a5 as resolveRuntimeFieldState, a6 as assembleRules, a7 as isAttachFieldActive, P as calculateFormula, a8 as getRuntimeDependencyOutputKey, a9 as isRowAddedInCurrentFormChange, c as getParseFormulaVarInfos, w as MaterialConsumptionPatternEnum, aa as MaterialConsumeTableController, ab as setFormulaParamsConfig, ac as normalizeRuntime, V as createRuntimeInstanceContext, ad as initializeSealFields, U as RuntimeFormStateStore, ae as RuntimeSheetService, g as getBusinessFieldKey, af as validateObjectBomQtyOnSubmit, ag as areValidationCommentsEqual, ah as closeValidatorPopovers, ai as enrichFormChangeRowDetails, N as NCB_PROVIDE, W as RuntimeInstanceRegistry, aj as useMaterialBalance, ak as collectFormChangeFieldLocations, al as nextFormChangeRowViewHistoryId } from "../dynamic-table-action-ZAmTIvcp.js";
4
- import { B as B2, am, k, a1 as a12, an as an2, $ as $2, ao, a0 as a02, F, ap, aq, ar, as, at as at2, M, a, au as au2, b, av as av2, aw as aw2, ax, ay, az, aA, aB, aC, C, aD as aD2, t as t2, aE, d, aF, aG, aH, aI, r, E, aJ as aJ2, aK as aK2, aL as aL2, aM as aM2, l, G, j, aN as aN2, aO as aO2, aP as aP2, aQ as aQ2, aR, aS, aT, y as y2, v, aU, z, p as p2, aV as aV2, s, aW as aW2, R, S, u, A as A2, T, o as o2, q, Q as Q2, m, x } from "../dynamic-table-action-ZAmTIvcp.js";
3
+ import { a2 as getRuntimeDataFieldId, O as parseRuntimeFieldPath, a3 as buildRuntimeFieldPath, a4 as resolveRuntimeFieldProps, a5 as resolveRuntimeFieldState, a6 as assembleRules, a7 as isAttachFieldActive, P as calculateFormula, a8 as getRuntimeDependencyOutputKey, a9 as isRowAddedInCurrentFormChange, c as getParseFormulaVarInfos, w as MaterialConsumptionPatternEnum, aa as MaterialConsumeTableController, ab as setFormulaParamsConfig, ac as normalizeRuntime, V as createRuntimeInstanceContext, ad as initializeSealFields, U as RuntimeFormStateStore, ae as RuntimeSheetService, g as getBusinessFieldKey, af as validateObjectBomQtyOnSubmit, ag as areValidationCommentsEqual, ah as closeValidatorPopovers, ai as enrichFormChangeRowDetails, N as NCB_PROVIDE, W as RuntimeInstanceRegistry, aj as useMaterialBalance, ak as collectFormChangeFieldLocations, al as nextFormChangeRowViewHistoryId } from "../dynamic-table-action-BP2qzgdK.js";
4
+ import { B as B2, am, k, a1 as a12, an as an2, $ as $2, ao, a0 as a02, F, ap, aq, ar, as, at as at2, M, a, au as au2, b, av as av2, aw as aw2, ax, ay, az, aA, aB, aC, C, aD as aD2, t as t2, aE, d, aF, aG, aH, aI, r, E, aJ as aJ2, aK as aK2, aL as aL2, aM as aM2, l, G, j, aN as aN2, aO as aO2, aP as aP2, aQ as aQ2, aR, aS, aT, y as y2, v, aU, z, p as p2, aV as aV2, s, aW as aW2, R, S, u, A as A2, T, o as o2, q, Q as Q2, m, x } from "../dynamic-table-action-BP2qzgdK.js";
5
5
  import { toRaw, watch, toRef, computed, defineComponent, openBlock, createElementBlock, createElementVNode, toDisplayString, ref, provide, onUnmounted, markRaw, reactive, onBeforeUnmount } from "vue";
6
6
  import { cloneDeep, defaults, isEmpty, merge } from "lodash-es";
7
7
  import "dayjs";
8
- import { S as SubTableCoreFactory, R as RuntimeInstanceController } from "../sub-table-factory-9_e9NXAk.js";
9
- import { A as A3, D, M as M2, a as a7, P as P2, b as b2, c, d as d2, e, W, f as f2, g, h } from "../sub-table-factory-9_e9NXAk.js";
8
+ import { S as SubTableCoreFactory, R as RuntimeInstanceController } from "../sub-table-factory-yVCjr6FI.js";
9
+ import { A as A3, D, M as M2, a as a7, P as P2, b as b2, c, d as d2, e, W, f as f2, g, h } from "../sub-table-factory-yVCjr6FI.js";
10
10
  import { B as B3, F as F2, M as M3, a as a8, u as u2 } from "../mb-render-C7bYBZNr.js";
11
11
  const InstanceStatusValues = {
12
12
  /** 作废状态 */
@@ -1,5 +1,5 @@
1
1
  import { defineComponent, computed, openBlock, createBlock } from "vue";
2
- import { h as useModelFields, D as Diagonal } from "./index-DHtjlchw.js";
2
+ import { h as useModelFields, D as Diagonal } from "./index-CbuzkPgj.js";
3
3
  import { al as resolveDiagonalVertex, a7 as _export_sfc } from "./dynamic-table-action.vue_vue_type_style_index_0_scoped_53d7e66c_lang-DTkBFPUl.js";
4
4
  import "lodash-es";
5
5
  import "dayjs";
@@ -6030,6 +6030,7 @@ class MaterialConsumeTableController {
6030
6030
  return this.actualBomEntries.map((i) => {
6031
6031
  return {
6032
6032
  product_id_: i.product_id_,
6033
+ qty_required_uom_id_: i.uom_id_ || void 0,
6033
6034
  ...materialNoNum === void 0 ? {} : { qty_required_: Number(i.qty_required_) * Number(materialNoNum) },
6034
6035
  bom_entry_id_: i.id_
6035
6036
  };
@@ -6214,6 +6215,9 @@ class MaterialConsumeTableController {
6214
6215
  this.setDefaultValue(row);
6215
6216
  try {
6216
6217
  const plan = await this.bomEntriesValidator.validateScanCanInsert(row, this.actualTableData);
6218
+ if (plan) {
6219
+ row.qty_required_uom_id_ = plan.target.bomEntry.uom_id_ || void 0;
6220
+ }
6217
6221
  const existingRequiredQty = this.isCustomRequiredQty && plan ? this.actualTableData.find(
6218
6222
  (item) => plan.target.isRowInGroup(item) && item.qty_required_ != null
6219
6223
  )?.qty_required_ : void 0;
@@ -6587,11 +6591,22 @@ class MaterialConsumeTableController {
6587
6591
  this.updateRowConsumed();
6588
6592
  this.updateGroupQtyConsumedTotal();
6589
6593
  }
6594
+ /** 同步 BOM 主物料的需求数量单位,未关联 BOM 的行保留原单位。 */
6595
+ syncRequiredUomFromBom(row) {
6596
+ const validator = this.bomEntriesValidator;
6597
+ const productId = row.product_id_;
6598
+ const bound = row.bom_entry_id_ ? validator.bomEntryValidators.find((item) => item.bomEntry.id_ === row.bom_entry_id_) : void 0;
6599
+ const matched = productId ? bound?.productIds.includes(productId) ? bound : validator.findUtilByProductId(productId) : void 0;
6600
+ if (matched || bound) {
6601
+ row.qty_required_uom_id_ = matched?.bomEntry.uom_id_ || void 0;
6602
+ }
6603
+ }
6590
6604
  /**
6591
- * 设置默认值,如工序,需求数量/已消耗数量
6605
+ * 设置默认值,如工序,需求数量/需求数量单位/已消耗数量
6592
6606
  * @param row
6593
6607
  */
6594
6608
  setDefaultValue(row) {
6609
+ this.syncRequiredUomFromBom(row);
6595
6610
  if (!row.routing_operation_id_) {
6596
6611
  row.routing_operation_id_ = this.tmplBomController.operationId;
6597
6612
  }
package/dist/excel.css CHANGED
@@ -3332,7 +3332,7 @@ img[data-v-57e657ee] {
3332
3332
  .data-group__index--row[data-v-d28554d6] {
3333
3333
  left: 6px;
3334
3334
  }
3335
- .num-input[data-v-10739a10] {
3335
+ .num-input[data-v-e327dc6f] {
3336
3336
  margin-left: 25px;
3337
3337
  width: 50px !important;
3338
3338
  }
@@ -4184,7 +4184,7 @@ img[data-v-57e657ee] {
4184
4184
  .gct-sheet-status__label[data-v-1db7a3a4] {
4185
4185
  font-weight: bold;
4186
4186
  margin-right: 8px;
4187
- }.ant-spin-spinning[data-v-467f6f1b] {
4187
+ }.ant-spin-spinning[data-v-39141cf4] {
4188
4188
  height: 100%;
4189
4189
  width: 100%;
4190
4190
  position: absolute;
@@ -1,5 +1,5 @@
1
1
  import { M as commonjsGlobal, N as getDefaultExportFromCjs } from "./dynamic-table-action.vue_vue_type_style_index_0_scoped_53d7e66c_lang-DTkBFPUl.js";
2
- import { c as commonjsRequire } from "./index-DHtjlchw.js";
2
+ import { c as commonjsRequire } from "./index-CbuzkPgj.js";
3
3
  function _mergeNamespaces(n, m) {
4
4
  for (var i = 0; i < m.length; i++) {
5
5
  const e = m[i];
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, computed, resolveComponent, openBlock, createElementBlock, createElementVNode, createVNode, unref, normalizeClass, withCtx, normalizeStyle } from "vue";
2
2
  import { A as AlignEditor } from "./align-editor-CRjMBiv1.js";
3
3
  import { pick } from "lodash-es";
4
- import { z as _sfc_main$1, C as ColorPicker } from "./index-DHtjlchw.js";
4
+ import { z as _sfc_main$1, C as ColorPicker } from "./index-CbuzkPgj.js";
5
5
  import { a7 as _export_sfc } from "./dynamic-table-action.vue_vue_type_style_index_0_scoped_53d7e66c_lang-DTkBFPUl.js";
6
6
  const _hoisted_1 = { class: "ks-row-middle mb-6px" };
7
7
  const _sfc_main = /* @__PURE__ */ defineComponent({
@@ -3,7 +3,7 @@ import { C as ComponentTypeEnum } from "./dynamic-table-action.vue_vue_type_styl
3
3
  import "vue";
4
4
  import "dayjs";
5
5
  import "ant-design-vue";
6
- import { B as BaseComponent } from "./BaseComponent-B4z-0IvX.js";
6
+ import { B as BaseComponent } from "./BaseComponent-CkMnlfWd.js";
7
7
  class Department extends BaseComponent {
8
8
  component = ComponentTypeEnum.Department;
9
9
  wrapperCmpConfig({ data }) {
@@ -3,7 +3,7 @@ import "vue";
3
3
  import { pick, has, isEmpty, cloneDeep, get } from "lodash-es";
4
4
  import "dayjs";
5
5
  import "ant-design-vue";
6
- import { A as AsyncGctOnlineComponents } from "./index-DHtjlchw.js";
6
+ import { A as AsyncGctOnlineComponents } from "./index-CbuzkPgj.js";
7
7
  class Tr {
8
8
  component = "tr";
9
9
  wrapperCmpConfig({ data, parent }) {
@@ -3,7 +3,7 @@ import { C as ComponentTypeEnum, av as DecimalDisplayMode, au as RangeCompareOp,
3
3
  import "vue";
4
4
  import "dayjs";
5
5
  import "ant-design-vue";
6
- import { B as BaseComponent } from "./BaseComponent-B4z-0IvX.js";
6
+ import { B as BaseComponent } from "./BaseComponent-CkMnlfWd.js";
7
7
  class InputDouble extends BaseComponent {
8
8
  component = ComponentTypeEnum.InputDouble;
9
9
  wrapperCmpConfig({ data }) {
@@ -3,7 +3,7 @@ import { C as ComponentTypeEnum, F as FIELD_TYPE, au as RangeCompareOp, at as Ra
3
3
  import "vue";
4
4
  import "dayjs";
5
5
  import "ant-design-vue";
6
- import { B as BaseComponent } from "./BaseComponent-B4z-0IvX.js";
6
+ import { B as BaseComponent } from "./BaseComponent-CkMnlfWd.js";
7
7
  class DateTimepicker extends BaseComponent {
8
8
  component = ComponentTypeEnum.DateTimepicker;
9
9
  wrapperCmpConfig({ data }) {
@@ -3,8 +3,8 @@ import "vue";
3
3
  import "lodash-es";
4
4
  import "dayjs";
5
5
  import "ant-design-vue";
6
- import { B as BaseComponent } from "./BaseComponent-B4z-0IvX.js";
7
- import { g as getTraceLikeSelectProps } from "./trace-like-wrapper-BUq72oS3.js";
6
+ import { B as BaseComponent } from "./BaseComponent-CkMnlfWd.js";
7
+ import { g as getTraceLikeSelectProps } from "./trace-like-wrapper-Buykmr-D.js";
8
8
  class RdoSelect extends BaseComponent {
9
9
  component = ComponentTypeEnum.RdoSelect;
10
10
  wrapperCmpConfig({ data }) {
@@ -3,7 +3,7 @@ import { C as ComponentTypeEnum } from "./dynamic-table-action.vue_vue_type_styl
3
3
  import "vue";
4
4
  import "dayjs";
5
5
  import "ant-design-vue";
6
- import { B as BaseComponent } from "./BaseComponent-B4z-0IvX.js";
6
+ import { B as BaseComponent } from "./BaseComponent-CkMnlfWd.js";
7
7
  class UploadFile extends BaseComponent {
8
8
  component = ComponentTypeEnum.UploadFile;
9
9
  wrapperCmpConfig({ data }) {
@@ -4,7 +4,7 @@ import "vue";
4
4
  import { pick } from "lodash-es";
5
5
  import "dayjs";
6
6
  import "ant-design-vue";
7
- import { n as normalizeSpacerWidth, g as getFieldWidget } from "./index-DHtjlchw.js";
7
+ import { n as normalizeSpacerWidth, g as getFieldWidget } from "./index-CbuzkPgj.js";
8
8
  class CombineFields {
9
9
  component = ComponentTypeEnum.CombineFields;
10
10
  wrapperCmpConfig({ data }) {