jQuery Ajax CRUD in ASP.NET Core MVC using Popup Dialog
HTML-код
- Опубликовано: 1 окт 2024
- 🍒 Related Videos
Asp.Net Core MVC CRUD Operations: • Asp.Net Core MVC CRUD ...
Expense Tracker App in Asp.Net Core MVC: • Build an Expense Track...
MVC Login & User Registration: • Asp.Net Core MVC & Ide...
CRUD without EF in Asp.Net Core MVC: • CRUD without Entity Fr...
Image Upload in Asp.Net Core MVC: • Asp.Net Core MVC Image...
More MVC Tutorials: • Asp.Net Core MVC Tutorial
📂 GitHub Repository
► bit.ly/33KTJAu
💖 Channel Support
➤ Paypal: bit.ly/3L36ut4
➤ UPI App: geni.us/ScanQR...
➤ Amazon: geni.us/Amazon...
💌 For Business Inquiries
➤ codaffection@gmail.com
🚶♂️ Follow us
Facebook : / codaffection
Discord : / discord
Twitter : / codaffection
---
All about jQuery Ajax CRUD in ASP.NET Core MVC using a Modal Popup Dialog
In this tutorial, we've implemented jQuery Ajax CRUD in ASP.NET Core MVC using Modal Popup dialog. Today, these types of user interface/ methods are used in enterprise applications so that we can avoid reloading the page to do operations on a single controller.
Context discussed :
- MVC Controller with CRUD Operations with EF Core.
- Open the form in the Modal Popup Dialog.
- Submit the form with the jQuery ajax post.
- Show loading spinner while waiting for request-response.
- etc
#jQueryAjax #AspNetCore #CodAffection
goo.gl/bPcyXW : Buy me a Coffee
bit.ly/36IA1cH : AspNet Core MVC CRUD
bit.ly/3Pn2S7y : Expense Tracker App in AspNet Core MVC
bit.ly/403lUVC : MVC Login & User Registration
bit.ly/3muhseC : CRUD without EF in AspNet Core MVC
bit.ly/39B6xdh : Image Upload in AspNet Core MVC
bit.ly/30fPDMg : More MVC Tutorials
you all probably dont care but does someone know of a method to log back into an instagram account..?
I was dumb lost my login password. I love any assistance you can offer me!
@Kaison Duncan Instablaster :)
@Emmitt Troy thanks so much for your reply. I found the site through google and I'm in the hacking process now.
Looks like it's gonna take quite some time so I will reply here later with my results.
@Emmitt Troy It worked and I now got access to my account again. Im so happy!
Thanks so much you really help me out!
@Kaison Duncan You are welcome :D
25:28 - ctrl+f5 - reloads the current page including the browser cache. It's called Hard reload. It means that the browser will not use the current cache but will be forced to download again all the files (js files, images, scripts, …). You will have the most fresh version of the page sent by the server.
@codAffection First of all Great Video Sir !!! , There is a Small Bug in it After Editing a row ,It stores the Values Of the row which Edited , so if we Click New transaction its Opening with the filled Value in it of Edited row ...
solution = >
I also had the same issue. The fix worked for me as well. Thank-you.
Thanks for the update.
Great @Syed your solution fixes the bug.
Thank you Syed for the update, it works!
The project has a bug, after updating a record if you press New transaction button the modal loads the last edited record, but to solve it just update the for New transaction passing an Id=0 instead of null. The anchor could be like this:
Nueva Transacción
Regards. Good content btw!! congratulations CodAffection! 👍
Thank you for this tutorial, please add pagination in table.. (without exist component for example datatable or etc..) - please implement 0-100 in this project. I hope you should so happy :)
Validations are not working In AddOrEdit.cshtml
Oussama May 9, 2020 at 4:26 am - Reply
When i click update and save new informations, then reclick for Add popup (should be empty), I found weirdly filled with the last element updated…
when I checked the html code i find the URL.Action of new(Add) contain in route values the id of last updated…
How this is possible? and how i can fix it
Salim Bozkurt May 29, 2020 at 2:54 pm - Reply
Hi. Same problem. there is no problem when I use just string url. But when if I use Url.Action there occurs a problem.
After the any update proccess, New transaction button’s url contain last route values.
why ? I think problem is about RenderRazorViewToString helper.
same, did you resolve it ?
@@marilu9138 No but, I noticed that if I use the url action just like as below, there no occurs problem. I used id=0 instead of null.
@Url.Action(“AddOrEdit”,”Product”, new {id=0}, Context.Request.Scheme)
@@salimbozkurt9617 thanks , i was using only 0, i Will try later
@@marilu9138 Yepe. It works. Thanks, I had the same problem
your an Amazing bro our country does not have any pay-pall so i cant... is there a source code for this
Really amazing 😍,
very very useful video 👍👍🎉
Very well explained 🤩🤩
Why does my Index page not showing the updated data after I submit the form. I always need to refresh the page then I can see the changes!?
Have you found the solution please?
Thank you for this job, it was amazing. Can you do another similiar without using the helpers?
I'm getting a problem when using helper class with "TagHelper". It's doesn't render the page to string and return empty html when a tag helper is present in the returning view .
Did any one else encounter the problem ???
i have same problem
Hello sir without scaffolding crud operation banao asp.net MVC EntityFramework please sir
Its very nice way of explanation . If you don't mind I have few question which make me confuse 1. is this a good practice to have interface for repository ? or the way you deal with EF please explain Regards
@CodAffection Kindly help me this out if you know about this, i am getting error when i am creating a controller as same you were creating
Error There was an error running the selected code generator: 'Package restore failed. Rolling back package changes for 'CrudCoreWithAjax'.'
That is a very great tutorial. I have learn alot from yours, by the way if I would like to add pagination feature in _ViewAll.chtml partial view, how could we do?
I also want to ask???????????
thank you
Hello, thanks for your contribution,
I have a small inconvenience, the Json response is arriving empty, why is that problem.
Helper.RenderRazorViewToString (this, "_ViewAll", _context.Processes.ToList ()).
for this reason the index is empty, and I have to refresh the page to show the list.
Please have you found the solution yet?
Hello sir, lot of thanx for this important tuto in Ajax, every things works normally but i have one Remark in my case After doing an update for one record the add new Buton Open The modal with the last One populated in the form instead of permiting to add new transaction. Thx
modal('show') not working as per the tutorial. Driving me crazy and the online documentation is incomplete. Guess why?!
Thanks!
Hello, the submit button updates table and brings it "inside" the modalpopup! I've tried to google and followed everything you did but it seems like I am missing something?? any help in this regard?
I practice this project and i did not add anything new to it but when i click to submit or check the validation , it prints whole AddorEdit file and other information on the browser .... all the code is same as yours... What could be the issue , please help.
In 37:00 , I am doing my project through ADO.NET connection. Same procedure used to implement. How to write the code in json object redirection in ADO.NET connection. In my project I am using IConfuguration. In your project updated model i.e -context.Transactions.ToList() is used.
My project this code not work. After create new transaction then submit it is not redirect to index page. Please reply.
Is there any error message?
@@CodAffection No. But it doesn't redirect. I have used
return Json(new {isValid = true, redirectToUrl = Url.Action("Index, Book")});
this return statemet used and also change jquery. Now my code is work.
@@alwaysprudvi Thanks for the update, it might be due to the framework version update. good try. happy coding.
@@CodAffection Thank you for your videos. Upload the more videos on .NET.
Hello, which version of Visual Studio 2019 gives errors?
This good video, however am getting this error on the POST function. "TypeError: 'append' called on an object that does not implement interface FormData." I have done everything according to your video. Please help get solution to this error.
Oh boom! Got the solution, it was typo error....Thanks alot CodAffection for wonderful tutorial
No source code?
how to make validation errors disappear after leaving the input (as normal ) without posting the form ??
also, if the form has a dropdownlist it lost it's function after posting the form with error
Sir When i add data its not showing in Table ===> after referesing page its coming ===> Please Help me
Every thing is Working just data is coming in table after referesing Page .... don't know whats going on
Thank you for this wonderful tutorial,
download does not exists
How to create a messenger app using asp. Net mvc
Can you please share the css, thanks
best tutorial I learned all basics of .net from your videos ... highly recommended........ please upload more
where is the code of this project????? found anyone??????
In this method how can I use already created table from sql database?
Thanks for the job well done. your style of handling jQuery ajax is so superb, I have adopted that style from you long time ago. You are surely among the best tutors on youtube
Thanks for your wonderful feedback. keep learning and sharing.
sir how to load Category and brand drop dwon Model in this Model getting null dropdwons
36:00 thanks for uploading this video , I have been searching for such indepth validation using modal
you are always welcome.
hi sir , i am actually making a shopping cart kind of project , can you please make a tutorial on shopping cart on ASP.NET CORE and ANGULAR it will be a great help,
thankyou
Sir, I use @using X.PagedList.Mvc.Core; @using X.PagedList; for project, But it doesn't work, there is a solution for paging.
There is a bug in the code, when you update a transaction the information keeps saved and then when you clic on NEW TRANSACTION the information saved doesnt let you create a new transaction, please how can I fix this problem???
Why contentType in the jquery post function is false? It shouldn't be - application/x-www-form-urlencoded?
we can't access to this link bit.ly/3e1oXpQ
Very Informative. Liked it a lot. During this lockdown will watch all the videos to update my knowledge.
You change pages too fast, even before I could read your code. Difficult to follow for first time learners. when you are writing a code, give 5-10s to read it. Or else I have to keep stopping and playing the video.
You took hidden field for Transaction ID so how is it getting populated by default? I used Identity in the table but getting error while submitting the data.
Thank you for this great effort ^_^ , but how to append a file in jQueryAjaxPost function?
This is very helpful tutorial, Only thing we are not able to convert _viewall into data table ajax call, after save record view is unable to reload, its stuck and once we refresh its appears please advise. Otherwise this is a complete tutorial to implement in real life project. Its a humble request.
pls reply can we do the same in asp.net ??????
or can you make video on asp.net using popup with jquery..........
pls reply
Great. I need Web Api 2 Registration and Password Email Confirmation Tutorial!!!
very nice tutorial thanks
AWEEESOME..Post thax a lott
Please without EF Core
Hi... I had a problem with update it's not work every time I try to update it's insert as new record ... I follow your steps and use your source code in your website article ... can you help please?
Thank you very much sir. at 36.38, what if I want to return to a different controller instead of "this", how do I put the controller in place of the "this" keyword
😀👍
could you help me I do like this video but I want to add dropdown list from other relation table (rather than display the id Idisplay
did you watch my master detail videos? where I have discussed such topics.
Лучший 🔥
Огромное спасибо 👍
Comprehensive explanation. Thanks for knowledgeable sharing.
Super awesome video. I had been waiting for this for a long time. One request though. How can we implement jQuery DataTables in this?
we've covered that in one previous tutorial, it should work.
ruclips.net/video/_qIYBgWTlTo/видео.html
ruclips.net/video/u147Q0NY6Qg/видео.html
Nice, tks video help me
Do you work as freelancer? Plz reply.
How to implement client side (unobtrusive) validation or best fluent validaiton ? I tried but i couldn't run, please help me ?
I've discussed the same in one of my previous tutorial here - ruclips.net/video/DI_YppvLgJ8/видео.html
Let me know if there is anything left explain.
@@CodAffection thanks. i solved my problem. i implemented fluent validation.
Will it work in .NET 6?
popup not working
Thank you for this wonderful tutorial,
I applied these codes in one of my projects, it works correctly but in my views (creation, modification) which opens in modal, the javascript code does not work.
Make sure you have a reference to either the Bootstrap JS CDN or the downloaded local Bootstrap JS file in your _Layout view
great video
Thank you very much. This video help me a lot in creating my site for student grade. Especially in teachers part of site because teacher has to add , edit and sometime maybe delete grades.
All Ok but when data insert modal not hide auto and after delete page not auto refesh
Excellent tutorial. Thank you!!
Glad you liked it.
Hello i want to query that if we have multiple selectbox in for how can we get value from that in comma seperated ways
Kindly Source of this Code (Project File)
Thank you
Bro . If I want to be a full stack web developer and I decide to build my first application on MERN stack . So React js is a libaray ! Is it necessary to learn (angular js ) a framework also . Or I can make web application without framework also . Library also works instead of framework. ???
OutStanding Yaaar..
Great work and quick. There is a bug, when you add for the second time, it keeps the previous id
Asp.net cor (y)
Great tutorial, thanks again
Thank you!! Please keep the ASP.NET Core tutorials coming!!! Amazing!!!
Sure, Keep learning and sharing.
Nice tutorial, why is the source code different from the vidoe?
There is a bug currently. When you Update an entry and then go to create a new entry the previous information is still loaded and you cannot save a new entry into the database. FYI. Easy fix.
Aha, please share the fix. TYVM!
Hi, Thank You for these valuable tutorials. I have one issue in this tutorial, once I edit a form, clicking on New Transaction will pop up the data that I already have updated, Please how to fix
Thank you for this great tutorial! I really appreciate your approach to deal with jQuery Ajax CRUD using Popup Dialog in Asp.Net Core. I just have a question. How can I enable client side validation with this approach ?
Glad it was helpful!
I've discussed client side validation with same topic in one of my old video.
here is the link : ruclips.net/video/DI_YppvLgJ8/видео.html
you might need to make few adjustments inorder to adapt with latest versions.
let me know how it goes. hopefully in future if I update the tutorial I will include client side validation.
Thanks for this great tutorial!
tried to use in the mobile browser unfortunately do not open popups ...
Sir your website is down. What is the problem?
"This Website's IP Has Been Changed"
Please upload a video tutorial about server side processing of data table with ajax in asp.net core....keep uploading more videos on asp.net core.
Anyone know why he unchecks configure for https in the creation at the beginning?
This tutorial is just BOOOM! Thank you so much!
көп уақытты айтады гой
Thank you so much for another great video. It's very helpful. I have a request. Do you have video for authenticating to Active Directory while managing user list and roles in application database? So, when user comes to the web app using windows computer browser, it uses the logged in authentication and passes the authenticated username to application. It looks up the authenticated username in application user table and corresponding role. Thanks,
Thanks,
No video for Azure Active Directory yet. suggestion noted.
Hi!!! tk's for the amazing tutorial... can you share source code to download?
Best regards!
:)
Is this work with MVC Application
Thanks alot ,this is awesome tutorial
Hi your tutorials are very use full. I need your help. please let me know the mvc and web API based project solution architecture for hrms
Thanks, i came here for spinner code, when enter without values at "New Transaction". validation messages show with spinner simultaneously. help me with that.
Help, please, how to color the line in red if the value in the column is "No"?
And no source code ...
@CodeAffection : link project file please ..
Thank you very much sir. Tell me, how do i make sure that my datatable does not go away after adding a new record with the popup?
thanks for the comment.
didn't understand your question.
could you give the time in the video you are referring to.
Thank you for this video. It helps me.
Thanks for the video. Can you make a video on MVC. Net core using model view?