diff --git a/cutejava-front/src/utils/KitUtil.js b/cutejava-front/src/utils/KitUtil.js index cad8e0c8..6c62e35d 100644 --- a/cutejava-front/src/utils/KitUtil.js +++ b/cutejava-front/src/utils/KitUtil.js @@ -254,19 +254,22 @@ export function FormatRowEnvStr(row, column, cellValue, index) { return '' } -export function IsEmpty(obj) { - if (obj === undefined) { - // console.error('is undefined') - return true - } - if (obj === '') { - // console.error('is ""') - return true - } - if (obj === 'undefined') { - // console.error('is "undefined"') - return true - } - // console.error('is null') - return obj === null +/** + * 判断字符串是否不是空白字符串 + * 功能等同于 Java Hutool 的 StrUtil.isNotBlank + * @param {string} str - 待检查的字符串 + * @returns {boolean} - 如果字符串不是空白则返回 true,否则返回 false + */ +export function IsNotBlank(str) { + return str != null && String(str).trim().length > 0 +} + +/** + * 判断字符串是否是空白字符串 + * 功能等同于 Java Hutool 的 StrUtil.isBlank + * @param {string} str - 待检查的字符串 + * @returns {boolean} - 如果字符串是空白则返回 true,否则返回 false + */ +export function IsBlank(str) { + return str == null || String(str).trim().length === 0 } diff --git a/cutejava-front/src/views/components/advanced/CuteFormDialog.vue b/cutejava-front/src/views/components/advanced/CuteFormDialog.vue index ea839faf..43022d99 100644 --- a/cutejava-front/src/views/components/advanced/CuteFormDialog.vue +++ b/cutejava-front/src/views/components/advanced/CuteFormDialog.vue @@ -110,7 +110,9 @@ export default { .container-form { overflow-y: scroll; /* 启用滚动 */ scrollbar-width: none; /* Firefox */ - padding-right: 20px; + padding-top: 10px; + padding-left: 15px; + padding-right: 15px; -ms-overflow-style: none; /* Internet Explorer 10+ */ max-height: calc(100vh - 200px); /* 调整高度以适应页头和底部按钮 */ } diff --git a/cutejava-front/src/views/components/advanced/CuteFormDialogPro.vue b/cutejava-front/src/views/components/advanced/CuteFormDialogPro.vue index 92202e84..0e3d30b1 100644 --- a/cutejava-front/src/views/components/advanced/CuteFormDialogPro.vue +++ b/cutejava-front/src/views/components/advanced/CuteFormDialogPro.vue @@ -14,28 +14,42 @@ :modal="false" >
- + + + + + @@ -88,9 +108,11 @@