iSeller Commerce
iSeller POS Retail
iSeller POS F&B
iSeller POS Express
Crosslight
WebUI
ClientUI
What's New
Download Trial
Web Solution
Mobile Solution
Enterprise Solution
Custom Development
Blog
Community
Latest Development Blogs
ForumPostTopic
Browse By Tag
Hello Crosslight Support,
I am using the lastest version of Crosslight and I am on iOS. I have a list of items and when I edit this list, I see the red delete circle with a minus inside on the left side of each list item. So far so good.
When I now click on one of the red circles, the cell moves to the left and on the right side a red "Delete" button appears. How can I change the title of this button, how can I localize the "Delete" text?
Additionally, is it possible to mark some list items as undeletable?
Thanks,
Thomas
Hello Arief,
Thank you very much for the sample.
Hi ThomasHere is the method that you can use:To localize the cell action:Change your Red Delete Button/cell action into Custom Cell Action, you canread it from this article:http://developer.intersoftpt.com/display/crosslight/Enable+Custom+Cell+Actions+with+Swipe+GestureAlso if you not yet read/implement about localization please read this article first: http://developer.intersoftpt.com/display/crosslight/Localizing+ResourcesI'm really recommend you to downloadboth samples (or just take a peek of their code in git)for examples you want to localize your delete, first you type this in your controller:this.EditActions.Add(new UIEditACtion("Delete", true)); then connecting the "Delete" with your Resource like this:this.EditActions.Add(new UIEditACtion(this.ViewModel.Resources.GetString("DeleteText"),true));This way your Edit action already localized.To mark some items as undeletable, i'm suggesting to create new properties inside your table/model for example bool IsDeletable.If you see the ios-swipe-gesture samples inside ItemListViewModel.cs, you can Handle all of it inside this: protected override bool CanExecuteEditAction(object parameter) { var editParameter = parameter as EditingParameter;
// Write interaction code here to conditionally disable an action /*if (editParameter.CustomAction == "More" && this.Item.IsCompleted) return false;*/
return true; }parameter actually also return items so you can done this:if(((Item)parameter).IsDeletable = false){return false}Hope this will help you!
so far I was not able to realize the localization of the "Delete" button. Please, take your Data Drawer Sample and go to the Single Delete page. Swipe to the left on a row item and see the red "Delete" button. Please, give me a sample how to localize this "Delete" button.
Hi Thomas,Sorry i forgot to attach the sample, here is the sample, https://onedrive.live.com/download?resid=9F657B5249D6BB8D!111&authkey=!AHgtdIMssIavQBQ&ithint=file%2czipI think the problem is because you also need to add code in the view model and binding provider which you can see here and hereHope that will helps!
or
Choose this if you're already a member of Intersoft Community Forum. You can link your OpenID account to your existing Intersoft Social ID.
Choose this if you don't have an Intersoft account yet. Your authenticated OpenID will be automatically linked to your new Intersoft account.
Enter your Wordpress Blogname