31 lines
829 B
JavaScript
31 lines
829 B
JavaScript
import { Button } from "antd";
|
|
import React from "react";
|
|
import { connect } from "react-redux";
|
|
import { createStructuredSelector } from "reselect";
|
|
import { setModalContext } from "../../redux/modals/modals.actions";
|
|
|
|
const mapStateToProps = createStructuredSelector({});
|
|
|
|
const mapDispatchToProps = (dispatch) => ({
|
|
setRefundPaymentContext: (context) => dispatch(setModalContext({ context: context, modal: "refund_payment" }))
|
|
});
|
|
|
|
function Test({ setRefundPaymentContext, refundPaymentModal }) {
|
|
console.log("refundPaymentModal", refundPaymentModal);
|
|
return (
|
|
<div>
|
|
<Button
|
|
onClick={() =>
|
|
setRefundPaymentContext({
|
|
context: {}
|
|
})
|
|
}
|
|
>
|
|
Open Modal
|
|
</Button>
|
|
</div>
|
|
);
|
|
}
|
|
|
|
export default connect(mapStateToProps, mapDispatchToProps)(Test);
|