zrg
2026-01-08 c076dc095b915c1936eff1c853188cb21274ce09
utils/common.js
@@ -395,10 +395,7 @@
            console.log('播放暂停,销毁');
            innerAudioContext.destroy();
        });
      innerAudioContext.onStop(function() {
          console.log('播放暂停,销毁');
          innerAudioContext.destroy();
      })
    }
    // playSound(e) {
    //     // 全局维护一个音频实例,防止缓存溢出
@@ -467,7 +464,7 @@
        if(!RoleList) {
            RoleList = [
                /^[a-zA-Z]+$/,
                /\bid$/i
                /id$/i
            ]
        }
        if(!Array.isArray(RoleList)){
@@ -478,21 +475,25 @@
            }
        }
        
        let FieldListCache = Array(FieldList)
        let FieldListCache = Array(...FieldList)
        
        RoleList.forEach(role => {
            console.log(FieldListCache.filter(field => !role.test(field.ColmCols)))
            FieldListCache = FieldListCache.filter(field => !role.test(field.ColmCols))
            FieldListCache = FieldListCache.filter(elem => !role.test(elem.ColmCols))
        })
        
        FieldListCache = FieldListCache.filter(elem => !ExcludeKeys.includes(elem.ColmCols))
        return {
            status: true,
            data: FieldListCache,
            Message: ""
        }
    }
    emptyValueFilter(item, fieldList){
        return fieldList.filter(e => {
            return item[e.ColmCols]
        })
    }
}
export const CommonUtils = new commonUtils()