I have create new event in kendo scheduler.There is some problems in my scheduler.I want to show delete button only authorize person who is created this event.And I want to hide delete button who is not created this event,Only show event scheduler and hide icon.
I am so tired but not solved this problems please help
I think that you need to create different types of users and give them different perks. For example, the person who created that event will be an administrator. You have to create some function where the administrator will have the create and the destroy properties as true. To other users, you'll set those properties false. As for the hiding or not buttons, I suggest you to make your own custom edit form template. This was just a general idea but I hope you get the bigger picture.
updated answer:
Not only I think you should implement the CRUD operations manually but also customize the Scheduler behavior. Just like you can wire edit event and hide the save button if an user is not authorized or just like you can wire a save event and control wheather you allow or not event modifications, the same can be made with a delete event. Anyway, from what I understood, I think that using a custom editor template to control the state of any components should be enough. Basically, define a custom template and allow/disable/hide/show some widgets depending on the user that is logged in. The credentials can be loaded and used directly in the template. Check this dojo, it might be useful.
Related
What is the current way to do a custom button with some js in it?
We are building a custom button that needs to be able to read from the current contact (email address, phone, mailing address), and run a few lines of js. (We also need to create a call record.)
But how/where is this done in salesforce these days?
This page doesn't point me anywhere:
https://help.salesforce.com/apex/HTViewHelpDoc?id=customize_enterprise.htm
And this explanation of the new method in Lightning isn't clear where the js lives:
https://developer.salesforce.com/forums/?id=906F0000000BWr4IAG
Where is the needed example/doc?
If you are using buttons on custom visualforce page there are no any problems with defining custom JS function for it. For example, if you use <apex:commandButton/> you can use such attributes as onclick, onkeydown, onkeyup and other. See more information in documentation.
If you are using buttons on object layouts, you can create custom button and chose executing of JS as a behavior, see attached screenshot.
If you mean some other cases, please, describe it.
There's a search box on the top of Salesforce. Is it possible to override(re-implement) it? Like catching the click event, popping up dialog, or customizing the search result page...
I went over the Visualforce development guide, it seems I can't do this with Visualforce. Any suggestions?
You'd need to use custom sidebar components.
In one of them place javascript that will intercept the events from the global search -> and make that event invoke whatever you want.
I was trying to understand how DotNetNuke dynamically loads web user controls (.ascx) that have statically defined event handlers. I've tried to go through the documentations available on DotNetNuke's website, but couldn't find a proper answer to my question.
Assume that the user control has a button inside it and has its click event specified in the .ascx file. The user control does not wire up the event handlers inside the page_load() or init(). So if the user control is dynamically loaded without wiring up the event handlers in the page_load() on every load, why does the event handler of the button still work? What is the process that DotNetNuke uses to create a module out of the ASCX file? It would also be great if anyone can point me to some documentation.
It simply loads the control early in the page lifecycle, there is nothing all that magical on how this works. They are regular ascx controls. The key is the definition of "AutoEventWireup" on the ascx.
We are using tab control in our project. While using this control i came across a few issues like
- When the tab control loads, it invokes constructor of all the xaml pages that form the individual tabs. Can this be avoided?
Is there any event with tab control that we can use to identify dirty data on the previous tab that i may have visited. I mean can i prevent user from navigating to some other tab before saving the changes on current tab.
You should be able to avoid the instantiation of each xaml page in the individual tabs by adding the content to the tabs dynamically, right before they are shown for the first time. You might be able to get away with doing this on the tab control's SelectionChanged event.
The tab control does not have a dirty state management. At best, you individual containers/pages will have to handle the dirty state.
I mean can i prevent user
from navigating to some other tab
before saving the changes on current
tab.
I don't think you can prevent it. We have something similar in our app and the route we have chosen is if the page is validated then the Tabs becomes enabled so they can either click save or navigate to a different tab. In case they navigate to a different tab without clicking on save we will perform save for them. I think as a user perspective this is a good thing!
I am looking at the report viewer WinForms control in SSRS 2005 and want to know if you can have actions do something other than call a URL or show another report. My boss likes the report viewer control but wants to know if you can set it up so that if you click on a cell it could open up another form.
I think the "Action" property is the right tool for this, but I don't see any options to run code... all I see is "Go TO Bookmark","Jump to Report", and "Go to URL". Is there an event that the control exposes that I could use to determine which cell was clicked or some other way I can do this?
Looking at the documentation, there's a Hyperlink event on the ReportViewer control that is fired whenever the user clicks on a link within a report. You might be able to handle that event, set Cancel to true, and take your own action.
Just to clarify - this would mean using the "Go to URL" action but specifying a URL that you can parse yourself. For example, "http://example.com?action=ShowHelloWorld". Then you could parse the e.Hyperlink property and decide what action to take.