I'm busy building a simple CRUD system in Orchard. I've created a custom Content Item called "Teacher", which has a few fields like name, email address, phone number, etc.
I've create a custom form that uses the Content Item "Teacher" and saves the submission to the database. Now I can edit this submission from the Admin section, but I would like to make it editable from the Front UI too. Any idea what the best way is to proceed with this?
Found the answer. Copied the Edit View and Method from Orchard.Core.Contents AdminController to ItemController.
Related
I am unable to understand how forms work in shopware. I need to update the contact page with my own style but when I add content into the contact page cannot see that content on page when I browse it.
Could you please let me know how to create a page and what need to be done to add a form to that page?
You are aware that the contact form is handled via configuration that can be done in the shopware backend's content > form section? there you will find a list of existing forms that can be modified by clicking the pen icon. A window will open where you can configure the forms name, the recipient email address, subject, email template as well as the form html content that will be shown in the frontend and the message that appears after submitting the form.
If you intend to change the layout (html and/or css) of the forms you need to override the forms template files:
frontend/forms/elements.tpl
frontend/forms/header.tpl
frontend/forms/index.tpl
Kind regards!
I need to create a "custom" web page in Orchard. As I understand it, below are the steps I need to take to do so. Before I go down this somewhat lengthy process, are there any steps I'm missing or that I can skip?
Create a model
Create a content part and content part record which use the above model
Create a driver which implements the Display method which returns the "shape" of the content part
Create a shape template to render the shape returned from the above driver
Create a content type which holds the content part
Create a page which holds the content type
Add the page to my site
This page is "custom", in the sense that it needs to pull data from a web service and display it in an interactive way. When the user makes changes, those changes will need to be sent back to the web service.
Those are really steps for creating a content item. You would want to create a content item if your page should be treated as content - e.g. administrators can create, edit, publish, unpublish, and finally delete your page.
If you just want to create a simple page, then there is nothing to stop you from creating your own ASP MVC controller. You can define routes for it using Orchard's routing, and if you decorate it with a [Themed] attribute, it will even inherit the site's theme.
I want to add Emails to navigation so It can be used like any other entity. Editing sitemap is not a problem but it does not work in the expected way.
First, of all it shows all entities, not emails only. And consequently there are filters for other activities which are unwanted.
How do I make email-view that does not show other activities?
Create a new view in CRM showing the records you wish to see
Create a HTML web resource, with an iFrame pointing to the URL of the view you just created. It will look something like this /advancedfind/advfind.aspx?AutoRun=true&QueryId=%7b495B7974-58AC-E234-92D4-EE155D107003%7d&ViewType=4230&etn=email
Point your sitemap to the new web resource
Is it possible to have a field in the current item be changed by clicking a URL? The field would be a choice field with predefined choices.
Such as if the item field is currently:
Status: 2
If a user clicks the link, the field would now be:
Status: 3
If not, is there any other way for a user to easily change a field in the current item without actually haveing to visit the item?
Thanks!
Not Out Of The Box (OOTB) - but you've a few options.
Write an ASPX page to do what you want
Use something like SPServices and javascript to update the list item via the web services.
Use the Client Object Model (2010 only)
By the way - changing stuff on a 'get' can be dangerous as you can do malicious things - for example imagine you have a page that deletes the users account without any prompting (exact example doesn't matter) - what if someone clicks on that link by mistake or even worse what about an email sent with an image with that page as source URL - simply viewing the email could delete the users account.
It's not possible by using a GET request, but SharePoint 2010 is offering a RESTful API to manage ListItems from any client
The REST API is located within the virtual WebServices folgder under each SharePoint Site.
http://YourSharePointSite/_vti_bin/ListData.svc.
To perform an update on SharePoint ListItems you have to create a PUT Request. For more information on SharePoints REST API you should have a look at this MSDN site, there are also a lot of samples linked from this article.
Thorsten
I would like to create something in SharePoint that allows users to request access to particular documents and then for me to be able assign access for a period. Would this be possible in SharePoint? If so, how would i go about doing this? What must i use?
Thanks in advance!
Set up a SharePoint Group for those documents and then allow users to request membership to the group.
This is how I would do it:
Add a hyperlink column to the Document Library
Add a 'New Item' event handler to the DL which adds the url to the hyperlink column, and point the hyperlink to your own ASP.Net page (or even the DL itself), with details of the document required (ID et al) in the GET string. Call this hyperlink 'Request Access' or something similar.
Create a webpart which checks the GET string for the right variables, identifies the user (currently logged in user viewing the page the webpart is on) and sends you an email informing you of the request. Add this webpart to the target ASP.Net page in step 2.
When a document is added, the event handler will update the hyperlink column with the required hyperlink. When a user requires access, they will click on the properly formed hyperlink, which will take you to a page with the receiver webpart on it. The receiver webpart will get the required information from the GET string, inform you via email, and also inform the user that the request has been received.
Although I'm sure theres a better way to do this...
You can modify the "popup" menu that's shown while hovering over the document. Add a link to that menu, here's an example of how to change the hover menu:
www.articlestreet.com/computers/send-a-sharepoint-document-library-file-as-email.html