From 2cc85c64f1c64a2dbaeae276a3e2ca8420de76b7 Mon Sep 17 00:00:00 2001
From: WXL <wl_5969728@163.com>
Date: 星期三, 22 四月 2026 18:09:58 +0800
Subject: [PATCH] 上报转运调试
---
node_modules/uview-plus/libs/function/index.js | 16 +++++++++++-----
1 files changed, 11 insertions(+), 5 deletions(-)
diff --git a/node_modules/uview-plus/libs/function/index.js b/node_modules/uview-plus/libs/function/index.js
index cc6e82a..8d785ed 100644
--- a/node_modules/uview-plus/libs/function/index.js
+++ b/node_modules/uview-plus/libs/function/index.js
@@ -158,8 +158,13 @@
// 閫氳繃while鍘嗛亶锛岃繖閲屼富瑕佹槸涓轰簡H5闇�瑕佸灞傝В鏋愮殑闂
while (parent) {
// 鐖剁粍浠�
- name = name.replace(/up-([a-zA-Z0-9-_]+)/g, 'u-$1')
- if (parent.$options && parent.$options.name !== name) {
+ let name2 = ''
+ if (name.startsWith('up-')) {
+ name2 = name.replace(/up-([a-zA-Z0-9-_]+)/g, 'u-$1')
+ } else if (name.startsWith('u-')) {
+ name2 = name.replace(/u-([a-zA-Z0-9-_]+)/g, 'up-$1')
+ }
+ if (parent.$options && parent.$options.name !== name && parent.$options.name !== name2) {
// 濡傛灉缁勪欢鐨刵ame涓嶇浉绛夛紝缁х画涓婁竴绾у鎵�
parent = parent.$parent
} else {
@@ -376,7 +381,7 @@
date = new Date(Number(dateTime))
}
// 妫�鏌ユ槸鍚︿负UTC鏍煎紡鐨勬椂闂村瓧绗︿覆 (2024-12-18T02:25:31.432Z)
- else if (typeof dateTime === 'string' && /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$/.test(dateTime)) {
+ else if (typeof dateTime === 'string' && /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d{1,3})?(Z|[+-]\d{2}:\d{2})?$/.test(dateTime)) {
date = new Date(dateTime)
}
// 鍏朵粬閮借涓虹鍚� RFC 2822 瑙勮寖
@@ -645,8 +650,8 @@
* @param {*} event
*/
export function formValidate(instance, event) {
- const formItem = $parent.call(instance, 'u-form-item')
- const form = $parent.call(instance, 'u-form')
+ const formItem = $parent.call(instance, 'up-form-item')
+ const form = $parent.call(instance, 'up-form')
// 濡傛灉鍙戠敓鍙樺寲鐨刬nput鎴栬�卼extarea绛夛紝鍏剁埗缁勪欢涓湁u-form-item鎴栬�卽-form绛夛紝灏辨墽琛宖orm鐨剉alidate鏂规硶
// 鍚屾椂灏唂orm-item鐨刾ros浼犻�掔粰form锛岃鍏惰繘琛岀簿纭璞¢獙璇�
if (formItem && form) {
@@ -870,3 +875,4 @@
genLightColor,
rpx2px
}
+
--
Gitblit v1.9.3