This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var field = item.Fields[_fieldId]; | |
var type = FieldTypeManager.GetField(field); | |
if (type is LinkField) | |
{ | |
... | |
} | |
if (type is InternalLinkField) // such as drop tree controls | |
{ | |
... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using Sitecore.Form.Core.Renderings; | |
using Sitecore.Form.Web.UI.Controls; | |
namespace Custom.Form.Web.UI.Controls | |
{ | |
public class PreventDoubleClickFormRender : FormRender | |
{ | |
// disables submit button if group validator for submit is valid | |
private const string PreventDoubleSubmitJs = @"function disableSubmitButton(groupValidator, submitButton) {{ $(submitButton).disabled = Page_ClientValidate(groupValidator);}}"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Extends: Sitecore.Form.Core.Pipelines.FormSubmit | |
forms.config needs to be updated to: | |
<successAction> | |
<processor type="MyCustom.Pipelines.SuccessRedirect, MyLibrary"/> | |
<processor type="Sitecore.Form.Core.Pipelines.FormSubmit.FormatSuccessMessage, Sitecore.Forms.Core"/> | |
</successAction> | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getRoutes() { | |
return [ | |
{ | |
url: '/profiles', | |
config: { | |
templateUrl: 'Views/allprofiles', | |
controller: 'allprofiles' | |
} | |
}, { | |
url: '/profiles/:profileId', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getRoutes() { | |
return [ | |
{ | |
url: '/profiles', | |
config: { | |
templateUrl: 'Views/allprofiles?v=4', | |
controller: 'allprofiles' | |
} | |
}, { | |
url: '/profiles/:profileId', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<%@ Control Language="c#" AutoEventWireup="true" TargetSchema="http://schemas.microsoft.com/intellisense/ie5" %> | |
<div data-ng-controller="allprofiles as vm"> | |
<p><a class="btn btn-primary btn-lg" ng-click="vm.load();">Load Data</a></p> | |
<div class="row" ng-repeat="profile in vm.repository"> | |
<div class=" col-md-1"> | |
<a class="btn btn-danger btn-small" href="#profiles/{{profile.ID}}">Edit</a> | |
</div> | |
<div class="col-md-1">{{profile.DisplayName}}</div> | |
<div class="col-md-6">{{profile.ID}}</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<%@ Page language="c#" Codepage="65001" AutoEventWireup="true" %> | |
<%@ OutputCache Location="None" VaryByParam="none" %> | |
<sc:FieldRenderer ID="FieldRenderer1" runat="server" FieldName="details" /> | |
<sc:placeholder key="main" runat="server" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
app.config( | |
... | |
'$httpProvider', function($httpProvider) { | |
$httpProvider.defaults.headers.put = { 'X-Scitemwebapi-Username': 'admin' }; | |
$httpProvider.defaults.headers.put = { 'X-Scitemwebapi-Password': 'b' }; | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div data-ng-controller="allprofiles as vm"> | |
<p><a class="btn btn-primary btn-lg" ng-click="vm.load();">Load Data</a></p> | |
<div class="row" ng-repeat="profile in vm.repository"> | |
<div class=" col-md-1"> | |
<a class="btn btn-danger btn-small" href="#profiles/{{profile.ID}}">Edit</a> | |
</div> | |
<div class="col-md-1">{{profile.DisplayName}}</div> | |
<div class="col-md-6">{{profile.ID}}</div> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function () { | |
'use strict'; | |
// Controller name is handy for logging | |
var controllerId = 'allprofiles'; | |
// Define the controller on the module. | |
// Inject the dependencies. | |
// Point to the controller definition function. | |
angular.module('app').controller(controllerId, |
NewerOlder