Detail Product
This commit is contained in:
		| @@ -209,12 +209,14 @@ export const DesktopLayout = observer(() => { | |||||||
|                 icon={<ProfileOutlined />} |                 icon={<ProfileOutlined />} | ||||||
|                 title="Payback" |                 title="Payback" | ||||||
|               > |               > | ||||||
|  |                 {store.authentication.userData.role !== "Retail" && ( | ||||||
|                 <Menu.Item key="payback-to-user"> |                 <Menu.Item key="payback-to-user"> | ||||||
|                   <Link to={LINKS.PAYBACK}> |                   <Link to={LINKS.PAYBACK}> | ||||||
|                     <PayCircleOutlined /> |                     <PayCircleOutlined /> | ||||||
|                     <span>Payback To</span> |                     <span>Payback To</span> | ||||||
|                   </Link> |                   </Link> | ||||||
|                 </Menu.Item> |                 </Menu.Item> | ||||||
|  |                 )} | ||||||
|                 {store.authentication.userData.role !== "Admin" && ( |                 {store.authentication.userData.role !== "Admin" && ( | ||||||
|                 <Menu.Item key="payback-from-user"> |                 <Menu.Item key="payback-from-user"> | ||||||
|                   <Link to={LINKS.PAYBACKFROMUSER}> |                   <Link to={LINKS.PAYBACKFROMUSER}> | ||||||
|   | |||||||
| @@ -127,12 +127,14 @@ export const MenuList = observer((props) => { | |||||||
|         </Menu.Item> |         </Menu.Item> | ||||||
|       )} |       )} | ||||||
|       <SubMenu key="payback-main" icon={<ProfileOutlined />} title="Payback"> |       <SubMenu key="payback-main" icon={<ProfileOutlined />} title="Payback"> | ||||||
|         <Menu.Item key="payback-to-user"> |         {store.authentication.userData.role !== "Retail" && ( | ||||||
|           <Link to={LINKS.PAYBACK}> |           <Menu.Item key="payback-to-user"> | ||||||
|             <PayCircleOutlined /> |             <Link to={LINKS.PAYBACK}> | ||||||
|             <span>Payback To</span> |               <PayCircleOutlined /> | ||||||
|           </Link> |               <span>Payback To</span> | ||||||
|         </Menu.Item> |             </Link> | ||||||
|  |           </Menu.Item> | ||||||
|  |         )} | ||||||
|         {store.authentication.userData.role !== "Admin" && ( |         {store.authentication.userData.role !== "Admin" && ( | ||||||
|           <Menu.Item key="payback-from-user"> |           <Menu.Item key="payback-from-user"> | ||||||
|             <Link to={LINKS.PAYBACKFROMUSER}> |             <Link to={LINKS.PAYBACKFROMUSER}> | ||||||
|   | |||||||
| @@ -25,7 +25,7 @@ import { | |||||||
| import { MembershipModal } from "./MembershipModal"; | import { MembershipModal } from "./MembershipModal"; | ||||||
| import { BreadcumbComponent } from "../../component/BreadcumbComponent"; | import { BreadcumbComponent } from "../../component/BreadcumbComponent"; | ||||||
| import { LINKS } from "../../routes/app"; | import { LINKS } from "../../routes/app"; | ||||||
| import { Link,useHistory } from "react-router-dom"; | import { Link, useHistory } from "react-router-dom"; | ||||||
| import { ModalLoaderContext } from "../../utils/modal"; | import { ModalLoaderContext } from "../../utils/modal"; | ||||||
|  |  | ||||||
| const { Search } = Input; | const { Search } = Input; | ||||||
| @@ -223,9 +223,9 @@ export const Membership = observer(() => { | |||||||
|               history.push(LINKS.DETAILUSER.replace(":id", record.id)); |               history.push(LINKS.DETAILUSER.replace(":id", record.id)); | ||||||
|               //console.log(record.id) |               //console.log(record.id) | ||||||
|             }} |             }} | ||||||
|             > |           > | ||||||
|               Detail |             Detail | ||||||
|             </Button> |           </Button> | ||||||
|         </Space> |         </Space> | ||||||
|       ), |       ), | ||||||
|     }, |     }, | ||||||
| @@ -399,11 +399,14 @@ export const Membership = observer(() => { | |||||||
|                     > |                     > | ||||||
|                       <List.Item.Meta |                       <List.Item.Meta | ||||||
|                         className={["cariparkir-container"].join(" ")} |                         className={["cariparkir-container"].join(" ")} | ||||||
|                         title={item.username} |                         title={item.name} | ||||||
|                         description={ |                         description={ | ||||||
|                           <div style={{}}> |                           <div style={{}}> | ||||||
|                             <p> |                             <p> | ||||||
|                               <small>Username : {item.username}</small> <br /> |                               <small>Role : {item.roleName}</small> <br /> | ||||||
|  |                               <small>Saldo Supplier : {item.amount}</small>{" "} | ||||||
|  |                               <br /> | ||||||
|  |                               <small>Saldo System : {item.amount}</small> <br /> | ||||||
|                             </p> |                             </p> | ||||||
|                           </div> |                           </div> | ||||||
|                         } |                         } | ||||||
| @@ -415,7 +418,16 @@ export const Membership = observer(() => { | |||||||
|                             margin: 0, |                             margin: 0, | ||||||
|                           }} |                           }} | ||||||
|                         > |                         > | ||||||
|                           {item.username} |                           <Button | ||||||
|  |                             type={ | ||||||
|  |                               item?.isActive === true ? "danger" : "primary" | ||||||
|  |                             } | ||||||
|  |                             onClick={() => | ||||||
|  |                               changeStatus(item?.id, item?.isActive) | ||||||
|  |                             } | ||||||
|  |                           > | ||||||
|  |                             {item?.isActive === true ? "Inactive" : "Active"} | ||||||
|  |                           </Button> | ||||||
|                         </p> |                         </p> | ||||||
|                       </div> |                       </div> | ||||||
|                     </List.Item> |                     </List.Item> | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user