Added methods in open and fix problems
This commit is contained in:
@ -1,5 +1,7 @@
|
||||
import { IItems } from "../../interfaces/items.interface";
|
||||
|
||||
export interface IDataItem{
|
||||
category?: string;
|
||||
categoryItems?: string;
|
||||
ItemValue: object | string | number;
|
||||
ItemValue: string | IItems | number;
|
||||
}
|
@ -8,7 +8,7 @@ import { IDataItem } from './urils.interface';
|
||||
* @returns {IDataItem | IItems} возвращает сформированный объект
|
||||
*/
|
||||
|
||||
export function getFormatItem(dataItem:IDataItem , index: number):IDataItem | IItems {
|
||||
export function getFormatItem(dataItem:any , index: number) : IItems {
|
||||
const random = Math.random().toString(36).substring(2, 10);
|
||||
let item: IItems;
|
||||
|
||||
@ -20,6 +20,7 @@ export function getFormatItem(dataItem:IDataItem , index: number):IDataItem | II
|
||||
title: dataItem,
|
||||
value: index
|
||||
}
|
||||
|
||||
return item;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user