Commit 133a10ec authored by 若依's avatar 若依 Committed by Gitee

!47 修复和优化前端 utils 工具函数

Merge pull request !47 from FungLeo/master
parents 6a84ae42 a09a342f
import { parseTime } from './ruoyi'
/** /**
* 表格时间格式化 * 表格时间格式化
*/ */
......
...@@ -68,10 +68,10 @@ export function addDateRange(params, dateRange) { ...@@ -68,10 +68,10 @@ export function addDateRange(params, dateRange) {
// 回显数据字典 // 回显数据字典
export function selectDictLabel(datas, value) { export function selectDictLabel(datas, value) {
var actions = []; var actions = [];
Object.keys(datas).map((key) => { Object.keys(datas).some((key) => {
if (datas[key].dictValue == ('' + value)) { if (datas[key].dictValue == ('' + value)) {
actions.push(datas[key].dictLabel); actions.push(datas[key].dictLabel);
return false; return true;
} }
}) })
return actions.join(''); return actions.join('');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment