BlackBearFTW
BlackBearFTW
Explore posts from servers
RRefine
Created by extended-salmon on 11/5/2024 in #ask-any-question
Api request on button press
So I have a resource where the status can be approved or rejected by doing /budget-requests/{id}/approve or ..../reject, what hooks can I use to call this on button press?
5 replies
RRefine
Created by wee-brown on 11/2/2024 in #ask-any-question
Implement Oauth PCKE flow
Hi, I want to implement social logins into custom auth, but these all require a callback route and I was wondering how to deal with all that on refine.
5 replies
RRefine
Created by genetic-orange on 10/28/2024 in #ask-any-question
useList, get current pageSize and pageIndex
Hi, how can I get the current pageSize and pageIndex, like useTable has in its tableProps but then for useList
4 replies
RRefine
Created by equal-jade on 10/18/2024 in #ask-any-question
do not reset fields on submit
How can I stop refine from resetting all fields on submit at the login and register forms
12 replies
RRefine
Created by national-gold on 10/9/2024 in #ask-any-question
Make sure toggle is enabled if edit has a value
In react and antd design, I have this component, I want the toggle to be checked on the edit page IF the fields have a value, but only by default, you should still be able to untoggle it without unsetting the value manually: <Row> <Col span={2}> <Form.Item name="bidWindowToggle" valuePropName="checked" label={t("buildings.fields.offerSettings.bidWindowToggle", "Bid Window")} > <Switch /> </Form.Item> </Col> <Col span={22}> <Form.Item noStyle shouldUpdate={(prevValues, currentValues) => { // Check if the toggle has changed if (prevValues.bidWindowToggle !== currentValues.bidWindowToggle) { // If toggled off, set startDate and endDate to null if (!currentValues.bidWindowToggle) { form.setFieldsValue({ offerSettings: { startDate: null, endDate: null, } }); } return true; // Return true to trigger a re-render } return false; // No update needed }} > {({ getFieldValue }) => getFieldValue('bidWindowToggle') === true ? ( <Form.Item
8 replies
RRefine
Created by conscious-sapphire on 9/26/2024 in #ask-any-question
How can I have a form inside the table of a List in antd design
I want to have a table and for each row I would like to be able to have a cell that has a form input for a field called label, how can I do this in antd design?
12 replies
RRefine
Created by extended-salmon on 9/25/2024 in #ask-any-question
redirect on delete
How can I make sure the show page redirects back to where it came from when the resource is deleted?
5 replies
RRefine
Created by frozen-sapphire on 8/2/2024 in #ask-any-question
listen to form values for changes
How can I listen to form values being changed in antd
16 replies
RRefine
Created by yammering-amber on 8/2/2024 in #ask-any-question
Antd design watch form input for value changes
ant design has a useWatch hook, this doesn't work in refine when using useForm, but I want to watch for changes, what can I do?
9 replies
RRefine
Created by grumpy-cyan on 7/31/2024 in #ask-any-question
Disable and hide refresh button on show page
Hi, I would like to disable and hide the refresh button on the show button, while still keeping the other buttons
10 replies
RRefine
Created by correct-apricot on 7/26/2024 in #ask-any-question
invalidate state of useTable hook
Hi, my goal is to force useTable to refetch its data, basically refresh, when I click a header button on the list page, how can I do this?
5 replies
RRefine
Created by unwilling-turquoise on 7/26/2024 in #ask-any-question
Refresh button for list in edit page
Hi, I am using refine and I disabled the show page so it goes to the edit page right away. However I modified the edit page to contain the list (antd design) of sub resources. For example I have buildings as primary resource and as sub resource I have offers, these offers show (relevant to the current building). However I would like to add a refresh button at the top of the list to refresh the items of the list or maybe even add real time updates in the future.
17 replies
RRefine
Created by rare-sapphire on 7/25/2024 in #ask-any-question
custom handle edit page field
Hi, I have a checkbox that dynamically shows an input when checked. this input is called realtorFee and represent a field in the backend, now the toggle is called realtorFeeToggle which is just a frontend conditional input to show that field. This works on the create page just fine, but on the edit page the switch is always off, even if the realtorFee has a value. How can I modify my antd design edit page for my resource so the toggle is enabled when realtorFee has a value (not null)?
5 replies
RRefine
Created by sensitive-blue on 7/11/2024 in #ask-any-question
delete many example dataprovider
@kapa.ai can you show me an example implementation for deleteMany for a rest data provider
5 replies
RRefine
Created by unwilling-turquoise on 7/9/2024 in #ask-any-question
Login route disable to query param
I would like to disable the to route query param that is given to the login for some specific routes (or all routes), using react-router-dom
11 replies
RRefine
Created by extended-salmon on 7/5/2024 in #ask-any-question
How can I support my antd design table to have drag and drop?
I want my users to be able to reorder the rows in a table by dragging and dropping
5 replies
RRefine
Created by other-emerald on 6/24/2024 in #ask-any-question
Different sider for show and other specific resource pages.
I want my detail pages to show a different sider than the one on the list page. The scenario I am trying to create is having a sider with projects and customers and then when a specific project is clicked, there should be a more detailed sider, with for example todo's, billing, invoices, etc
5 replies
RRefine
Created by genetic-orange on 6/21/2024 in #ask-any-question
Remove query params pageIndex and PageSize on non list pages
Currently it by default keeps the pageSize and pageIndex query parameter in the url when visting the show, edit, delete, create page. I want to only have those in the list page
5 replies
RRefine
Created by adverse-sapphire on 6/13/2024 in #ask-any-question
translate inside accessControlProvider
How can I use the translate methods from i18n inside the access control provider to translate error messages?
10 replies
RRefine
Created by uninterested-red on 6/13/2024 in #ask-any-question
CanAccess in react-router-dom
How can I use CanAccess with react-router-dom
7 replies