function commonCollectOrderDesktop(collect_order: ViewModel.CollectOrder, state: State, index: number) {
return (<tr key={index}>
<td><input type="checkbox" className='check'/></td>
<td>{collect_order.id}</td>
<td>{getObjectByIdAndName(collect_order.warehouse_id, state.array_of_warehouse)}</td>
<td>{getObjectByIdAndName(collect_order.legal_entity_id, state.array_of_legal_entity)}</td>
<td>{collect_order.creation_date_time}</td>
<td>{collect_order.count_of_product}</td>
</tr>);
}
{state.array_of_collect_order.length > 0
? (<button onClick={(event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => {
event.preventDefault();
console.log(state.array_of_collect_order)
for (let i of state.array_of_collect_order) {
console.log (i["id"])-это для тестов
}
}}>Собрать
{state.array_of_collect_order.length} -вместо длины стейта массива здесь должно быть кол выбранных чекбоксов
{defineTitle((state.array_of_collect_order.length), "заказ", "заказа", "заказов")}
</button>)
: null
}