block.js
16 lines
| 1 | const pisol_dtt_warning = ({ cart, extensions }) => { |
| 2 | |
| 3 | return React.createElement("div", { |
| 4 | className: 'alert alert-warning pisol-dtt-block-warning' |
| 5 | }, "Custom field of Order Date, Time and Pickup location cant be added in block based checkout page, you should make your checkout page using short code ", React.createElement('strong',null,'[woocommerce_checkout]'), " In order to collect delivery date, time and pickup location from customer. (This warning is only visible to administrator and not to your customers)"); |
| 6 | |
| 7 | }; |
| 8 | |
| 9 | const pisol_dtt_render = () => { |
| 10 | return React.createElement(wc.blocksCheckout.ExperimentalOrderMeta, null, React.createElement(pisol_dtt_warning, null)); |
| 11 | }; |
| 12 | |
| 13 | wp.plugins.registerPlugin('pisol-dtt', { |
| 14 | render: pisol_dtt_render, |
| 15 | scope: 'woocommerce-checkout', |
| 16 | }); |