Domanda

Ho sviluppato un modello Web personalizzato in base a "BDR # 0" in SP 2013. Funziona perfettamente e posso distribuirlo utilizzando la funzione di ambito del sito.Il modello Web è sviluppato aggiungendo un modulo in VS 2012 che include file elements.xml e onet.xml come segue:

Inserisci Descrizione dell'immagine qui

Voglio distribuire il modello web presso l'ambito dell'azienda agricola, ma quando implemendo utilizzando la funzionalità Amministration Scope, fornisce un errore seguente:

Project Item "DCWEBTEMPLATE" non può essere implementato tramite una funzione con ambito aziendale. Cosa c'è che non va ?

È stato utile?

Soluzione

This happens because your DCWebTemplate is a module.

You can't use a module to deploy to farm. If you check your spi-file you can see the attribute SupportedDeploymentScopes is only web and site.

<ProjectItem Type="Microsoft.VisualStudio.SharePoint.Module" SupportedTrustLevels="All" SupportedDeploymentScopes="Web, Site" xmlns="http://schemas.microsoft.com/VisualStudio/2010/SharePointTools/SharePointProjectItemModel">

Instead you should use a Empty Element item. Below is the spi for that type.

<ProjectItem Type="Microsoft.VisualStudio.SharePoint.GenericElement" DefaultFile="Elements.xml" SupportedTrustLevels="All" SupportedDeploymentScopes="Web, Site, WebApplication, Farm, Package" xmlns="http://schemas.microsoft.com/VisualStudio/2010/SharePointTools/SharePointProjectItemModel">

Altri suggerimenti

WebTemplate isn't allowed in Farm scoped features. See Elements by Scope even though it's for SP2010 it can be used as a guideline for SP2013.

The best you can do is WebApplications scope

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a sharepoint.stackexchange
scroll top