Adding Content Backend fields
Hi,
I have added a new backend field in Content block from using this:
Find Controls > ContentBackend > Views > ContentBackendInsert / ContentBackendEdit > Sections > MainSection > Fields. ContentBackendInsert is the name of the view used to insert content items, while ContentBackendEdit is the view for editing.
Now, I have the field added in the backend to be inserted into the database also. I found a code snippet:
App.WorkWith()
.DynamicData()
.Type(typeof(Telerik.Sitefinity.GenericContent.Model.ContentItem))
.Field()
.TryCreateNew("BranchName", typeof(string))
.SaveChanges(true);
Hello,
This task is achievable with External Scripts. This is a relevant thread: http://www.sitefinity.com/devnet/forums/sitefinity-4-x/general-discussions/how-to-implement-moving-of-items-up-and-down.aspx
You can create a service that executes your code snippet and an external script for the ContentBackendInsert view that makes the service call.
You can register your script through Administration -> Settings -> Advanced -> Content -> Controls -> ContentBackend -> Views -> ContentBackendInsert -> Scripts.
The event you need is onSaved ( this._binder.add_onSaved([your method here]) ).