Skip to content

Commit 14ff8d2

Browse files
Fix user management images issue
1 parent e18d371 commit 14ff8d2

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

src/components/FormItems/items/ImagesViewItem.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
1-
import React, { Component } from "react";
1+
import React from "react";
22
import PropTypes from "prop-types";
33
import ImagesUploader from "../uploaders/ImagesUploader";
44

55
const ImagesViewItem = (props) => {
66
const { value, label } = props;
7+
console.log("VALUE", value)
8+
console.log("LABEL", label)
79

810
const valueAsArray = () => {
911
if (!value) {
@@ -15,7 +17,7 @@ const ImagesViewItem = (props) => {
1517
return [value];
1618
}
1719

18-
if (!!valueAsArray().length) {
20+
if (!valueAsArray().length) {
1921
return null;
2022
}
2123

src/components/FormItems/uploaders/ImagesUploader.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,15 +135,15 @@ const ImagesUploader = (props) => {
135135
className="btn btn-link"
136136
onClick={() => doPreviewImage(item)}
137137
>
138-
<i className="la la-search"></i>
138+
<i className="la la-search"/>
139139
</button>
140140
{!readonly && (
141141
<button
142142
type="button"
143143
className="btn btn-link ml-2"
144144
onClick={() => handleRemove(item.id)}
145145
>
146-
<i className="la la-times"></i>
146+
<i className="la la-times"/>
147147
</button>
148148
)}
149149
</div>

src/components/Users/list/UsersListTable.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ const UsersListTable = (props) => {
2828
const { rows, dispatch, loading, idToDelete, modalOpen } = props;
2929
const [tableWidth, setTableWidth] = useState(window.innerWidth);
3030

31+
console.log("ROWS", rows)
32+
3133
const handleDelete = () => {
3234
dispatch(actions.doDelete(idToDelete))
3335
}
@@ -85,7 +87,7 @@ const UsersListTable = (props) => {
8587

8688
const columns = [
8789
{
88-
dataField: "avatar",
90+
dataField: "avatars",
8991
sort: true,
9092
formatter: dataFormat.imageFormatter,
9193
text: "Avatar",

0 commit comments

Comments
 (0)