@gct-paas/word 0.2.43-patch.1 → 0.2.43
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.
package/dist/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @gct-paas/word v0.2.43
|
|
1
|
+
/*! @gct-paas/word v0.2.43 */
|
|
2
2
|
import { Fragment, Suspense, Teleport, Transition, TransitionGroup, cloneVNode, computed, createApp, createBlock, createCommentVNode, createElementBlock, createElementVNode, createSlots, createStaticVNode, createTextVNode, createVNode, defineAsyncComponent, defineComponent, getCurrentInstance, getCurrentScope, guardReactiveProps, h, inject, isRef, isVNode, markRaw, mergeModels, mergeProps, nextTick, normalizeClass, normalizeProps, normalizeStyle, onBeforeMount, onBeforeUnmount, onMounted, onScopeDispose, onUnmounted, openBlock, provide, reactive, readonly, ref, render, renderList, renderSlot, resolveComponent, resolveDynamicComponent, shallowRef, toDisplayString, toHandlers, toRaw, toRef, toValue, unref, useAttrs, useCssVars, useModel, useSlots, vModelRadio, vModelText, vShow, watch, watchEffect, withCtx, withDirectives, withKeys, withModifiers } from "vue";
|
|
3
3
|
import da, { PopperWrapper } from "floating-vue";
|
|
4
4
|
import VueKonva from "vue-konva";
|
|
@@ -127310,7 +127310,7 @@ async function queryIsBomGranted() {
|
|
|
127310
127310
|
/** 按物料+批次查询复检日期(仅日期,不含时分秒) */
|
|
127311
127311
|
async function getReinspectionDate(params) {
|
|
127312
127312
|
var _res$data;
|
|
127313
|
-
if (!params.material_no_id_ && !params.material_no_) return
|
|
127313
|
+
if (!params.material_no_id_ && !params.material_no_) return;
|
|
127314
127314
|
const res = await postApi({
|
|
127315
127315
|
modelCategory: "entity",
|
|
127316
127316
|
modelKey: "em_production_identification",
|
|
@@ -127320,22 +127320,23 @@ async function getReinspectionDate(params) {
|
|
|
127320
127320
|
id_: params.material_no_id_,
|
|
127321
127321
|
"product_id_.versionEq": params.product_id_
|
|
127322
127322
|
} });
|
|
127323
|
-
const
|
|
127324
|
-
|
|
127325
|
-
|
|
127326
|
-
|
|
127327
|
-
|
|
127328
|
-
|
|
127329
|
-
|
|
127323
|
+
const record = (res === null || res === void 0 || (_res$data = res.data) === null || _res$data === void 0 ? void 0 : _res$data[0]) ?? (res === null || res === void 0 ? void 0 : res.data);
|
|
127324
|
+
const raw = (record === null || record === void 0 ? void 0 : record.re_inspection_date_) ?? (record === null || record === void 0 ? void 0 : record.retest_date_);
|
|
127325
|
+
if (raw == null || raw === "") return;
|
|
127326
|
+
const parsed = dayjs(raw);
|
|
127327
|
+
if (!parsed.isValid()) return;
|
|
127328
|
+
return parsed.format("YYYY-MM-DD");
|
|
127329
|
+
}
|
|
127330
|
+
/** 物料+批次查复检日期;缺任一参数不查;无日期放过;小于当天则 throw */
|
|
127330
127331
|
async function assertReinspectionDate(opts) {
|
|
127331
127332
|
if (!opts.product_id_ || !opts.material_no_ && !opts.material_no_id_) return;
|
|
127332
|
-
const
|
|
127333
|
+
const date = await getReinspectionDate({
|
|
127333
127334
|
product_id_: opts.product_id_,
|
|
127334
127335
|
material_no_: opts.material_no_,
|
|
127335
127336
|
material_no_id_: opts.material_no_id_
|
|
127336
127337
|
});
|
|
127337
|
-
if (
|
|
127338
|
-
if (
|
|
127338
|
+
if (!date) return;
|
|
127339
|
+
if (dayjs(date).isBefore(dayjs(), "day")) throw new Error("已超物料复检日期,该物料不可用");
|
|
127339
127340
|
}
|
|
127340
127341
|
function pickProductBaseId(option) {
|
|
127341
127342
|
var _option$_OPCT;
|
|
@@ -129731,7 +129732,7 @@ var init_material_consume_table_controller = __esmMin((() => {
|
|
|
129731
129732
|
}
|
|
129732
129733
|
}
|
|
129733
129734
|
/**
|
|
129734
|
-
*
|
|
129735
|
+
* 物料+批次查复检日期;缺任一参数不查;无日期放过;小于当天则 throw
|
|
129735
129736
|
*/
|
|
129736
129737
|
async validateReinspectionDate(opts) {
|
|
129737
129738
|
await assertReinspectionDate(opts);
|
package/dist/runtime/canvas/table/render/material-consume/material-consume-table-controller.d.ts
CHANGED
|
@@ -262,7 +262,7 @@ export declare class MaterialConsumeTableController {
|
|
|
262
262
|
/** 校验有效期 */
|
|
263
263
|
validateExpiration(row: IMaterialConsumeData): void;
|
|
264
264
|
/**
|
|
265
|
-
*
|
|
265
|
+
* 物料+批次查复检日期;缺任一参数不查;无日期放过;小于当天则 throw
|
|
266
266
|
*/
|
|
267
267
|
private validateReinspectionDate;
|
|
268
268
|
/**
|
|
@@ -71,11 +71,8 @@ export declare function getReinspectionDate(params: {
|
|
|
71
71
|
product_id_: string;
|
|
72
72
|
material_no_?: string;
|
|
73
73
|
material_no_id_?: string;
|
|
74
|
-
}): Promise<
|
|
75
|
-
|
|
76
|
-
validateDate?: string;
|
|
77
|
-
}>;
|
|
78
|
-
/** 物料+批次查复检日期、有效期;缺任一参数不查;无日期放过;小于当天则 throw */
|
|
74
|
+
}): Promise<string | undefined>;
|
|
75
|
+
/** 物料+批次查复检日期;缺任一参数不查;无日期放过;小于当天则 throw */
|
|
79
76
|
export declare function assertReinspectionDate(opts: {
|
|
80
77
|
product_id_?: string;
|
|
81
78
|
material_no_?: string;
|