We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Update Column Category and position in column after dragging, update db

Hi, 

I'm currently having an issue with the sqlite database and updating the category after dragging an item to a new column. I kind of having it working when dragging to a new column, but it'll randomly crash sometimes, and when I drag it to the column it will sometimes randomly place it in a random position with in the column, or the last, or even sometimes where I actually wanted it. It's very buggy but I'm using the DragEnd event, you can see it on my bugfix_columnmove branch. My Card Drag End event is at the very bottom of BoardView.xaml.cs, starting at line 347. 

The changes I made from the master branch to the point that I'm at is in the single commit made inside bugfix_columnmove, commit 2494247. 

Link to branch: https://github.com/hjohnson12/KanbanBoardUWP/tree/bugfix_columnmove

If you need any additional context, please let me know 🙂

Thank you!!


10 Replies

LA Lavanya Anaimuthu Syncfusion Team July 21, 2019 09:33 AM UTC

Hi Hunter, 
 
Greetings from Syncfusion, 
 
We were able to reproduce both the column position issue and ArgumentOutOfRange exception in our side. We are checking the feasibility to provide solution, we will update you the status in three business day on 24th July, 2019. Appreciate your patience until then. 
 
Regards, 
Lavanya A. 



HU Hunter July 21, 2019 03:21 PM UTC

Hi, 

Thank you for the reply!

Sure thing, I haven't updated the branch with my example on it so if you need to reference it for anything, should be good :) 

Thank you team! 

Best Regards,
Hunter


HU Hunter July 21, 2019 10:52 PM UTC

Hi team, 

Just wanted to update with a few details. I forgot to mention that one thing I noticed before on that branch was when I drag one to the column, it reorders by the order it is in my database... 

Well, I just tested manually changing the category by the category combo box of a task in the edit pane. When I move it to a column with other tasks, it orders it by the way it was created in the database (or collection). You should be able to see that on this version too, fixing one may fix the other. But thought I'd mention it!

Thank you for the help. Hoping we can get this figured out together, definitely a strange bug


LR Lakshmi Radha Krishnan Syncfusion Team July 25, 2019 03:33 AM UTC

 

Hi Hunter,

 

We have validated the issue “Incorrect card index when changing the card category in the CardDragEnd event”. We will fix this issue and will provide patch for this issue on or before Aug 8th, 2019. Appreciate your patience until then.

 

Regards,

Lakshmi R.



MK Muneesh Kumar G Syncfusion Team August 8, 2019 10:51 AM UTC

Hi Hunter, 
  
Thanks for your patience.  
  
We would like to mention you that selected card category will be updated automatically to the target column category once the CardDragEnd event is completed.  
  
As we have further investigated the reported issue, you are updating selected card detail to database in CardDragEnd event. If you want to update selected card category with target column category, you can use CardDragEnd event argument e.TargetKey which holds the target column category. 
  
For your reference, we have modified your sample and it can be downloaded from the below link: 
  
  
Please revert us if your requirement differs from this. 
  
Thanks, 
Muneesh Kumar G. 
 



HU Hunter August 8, 2019 11:11 AM UTC

Hi Muneesh, 

Thank you for your response! 

I ran a quick test of the sample before I had to head to work, and the column move seems to be working as expected so far, I'll do deeper testing later today once I'm off!

I did notice that once I restart the program, the tasks are ordered in the columns by the order they were created still. Is there a way so that they stay in the same positions I put them in after restarting the application? Or is that something that needs to manually be done somehow? 

Thank you for your teams help, it's been much appreciated!


MK Muneesh Kumar G Syncfusion Team August 8, 2019 11:25 AM UTC

Hi Hunder, 
 
Thanks for your update.  
 
SfKanban loads its columns and cards based on the provided ItemsSource. So, if you keep updating the data in DB and retrieve the updated data then set it to SfKanban ItemsSource means SfKanban shows the updated view while restarting the application.  
  
Thanks, 
Muneesh Kumar G. 
 



HU Hunter August 8, 2019 12:10 PM UTC

Ahh, I see, that makes sense! What do you think with SfKanban would be the best route to keep track of where the task cards were after restarting the application? IF even doing something for that is possible, given your information!



HU Hunter August 9, 2019 01:28 AM UTC

Hi Muneesh, 

I tested your sample and included it with my latest updates and it seems to be working with column move! 😊 I put the update with the latest changes from another branch, and put it into a new branch named colfix, here's the link: https://github.com/hjohnson12/KanbanBoardUWP/tree/colfix . 

I was thinking it would fix the deletion issue on thread 146246 I was having, but I can verify that it still happens. Hopefully the latest changes on this new branch can help fix the issue! Would you like me to post a link to the new branch in that thread for the team? 


LR Lakshmi Radha Krishnan Syncfusion Team August 9, 2019 01:36 PM UTC

Hi Hunter,

 

We are glad to know that the given solution works. We have fixed the issue "Null reference exception while deleting the card" mentioned in this forum 146246. It will be included in our upcoming weekly NuGet which is available on Aug 13th, 2019.

 

Regards,

Lakshmi R.



Loader.
Live Chat Icon For mobile
Up arrow icon