SiteScripts/SubsitesList.json
{ "$schema": "https://developer.microsoft.com/json-schemas/sp/site-design-script-actions.schema.json", "actions": [ { "verb": "createSPList", "listName": "Subsites List", "templateType": 100, "color": "4", "icon": "7", "subactions": [ { "verb": "addSPFieldXml", "schemaXml": "<Field ID=\"{fa564e0f-0c70-4ab9-b863-0177e6ddd247}\" Type=\"Text\" Name=\"Title\" DisplayName=\"Title\" Required=\"TRUE\" SourceID=\"http://schemas.microsoft.com/sharepoint/v3\" StaticName=\"Title\" FromBaseType=\"TRUE\" EnforceUniqueValues=\"FALSE\" Hidden=\"FALSE\" ReadOnly=\"FALSE\" CanToggleHidden=\"FALSE\" MaxLength=\"255\" Sealed=\"FALSE\" />" }, { "verb": "addSPFieldXml", "schemaXml": "<Field Type=\"Text\" DisplayName=\"URL\" EnforceUniqueValues=\"FALSE\" Required=\"FALSE\" Hidden=\"FALSE\" ReadOnly=\"FALSE\" CanToggleHidden=\"FALSE\" ID=\"{1479bc48-c911-4828-a748-ef24c189c04c}\" Name=\"URL\" StaticName=\"URL\" MaxLength=\"255\" PITarget=\"\" PrimaryPITarget=\"\" PIAttribute=\"\" PrimaryPIAttribute=\"\" Aggregation=\"\" Node=\"\" />" }, { "verb": "addSPFieldXml", "schemaXml": "<Field Type=\"Note\" DisplayName=\"Plan\" EnforceUniqueValues=\"FALSE\" Required=\"FALSE\" Hidden=\"FALSE\" ReadOnly=\"FALSE\" CanToggleHidden=\"FALSE\" CustomFormatter=\"{
 "$schema": "https://developer.microsoft.com/json-schemas/sp/column-formatting.schema.json",
 "elmType": "div",
 "txtContent": "@currentField",
 "attributes": {
 "class": "=if(indexOf(toLowerCase(@currentField),'delete') != -1, 'sp-field-severity--warning','')"
 }
}\" ID=\"{eec79256-6fc8-4c66-8652-08501b45186f}\" Name=\"Plan\" StaticName=\"Plan\" RichText=\"FALSE\" RichTextMode=\"Compatible\" IsolateStyles=\"FALSE\" AppendOnly=\"FALSE\" NumLines=\"6\" PITarget=\"\" PrimaryPITarget=\"\" PIAttribute=\"\" PrimaryPIAttribute=\"\" Aggregation=\"\" Node=\"\" />" }, { "verb": "addSPFieldXml", "schemaXml": "<Field Type=\"Choice\" DisplayName=\"Status\" EnforceUniqueValues=\"FALSE\" Required=\"FALSE\" Hidden=\"FALSE\" ReadOnly=\"FALSE\" CanToggleHidden=\"FALSE\" CustomFormatter=\"{"elmType":"div","style":{"flex-wrap":"wrap","display":"flex"},"children":[{"elmType":"div","style":{"box-sizing":"border-box","padding":"4px 8px 5px 8px","display":"flex","border-radius":"16px","height":"24px","align-items":"center","white-space":"nowrap","overflow":"hidden","margin":"4px 4px 4px 4px"},"attributes":{"class":{"operator":":","operands":[{"operator":"==","operands":["@currentField","Review Plan"]},"sp-css-backgroundColor-blueBackground37",{"operator":":","operands":[{"operator":"==","operands":["@currentField","Plan Approved"]},"sp-css-backgroundColor-successBackground50",{"operator":":","operands":[{"operator":"==","operands":["@currentField","Completed"]},"sp-css-backgroundColor-warningBackground50",{"operator":":","operands":[{"operator":"==","operands":["@currentField",""]},"",{"operator":":","operands":[{"operator":"==","operands":["@currentField","Holding"]},"sp-css-backgroundColor-blockingBackground50","sp-field-borderAllRegular sp-field-borderAllSolid sp-css-borderColor-neutralSecondary"]}]}]}]}]}},"children":[{"elmType":"span","style":{"line-height":"16px","height":"14px"},"attributes":{"iconName":{"operator":":","operands":[{"operator":"==","operands":["@currentField","Review Plan"]},"",{"operator":":","operands":[{"operator":"==","operands":["@currentField","Plan Approved"]},"",{"operator":":","operands":[{"operator":"==","operands":["@currentField","Completed"]},"",{"operator":":","operands":[{"operator":"==","operands":["@currentField",""]},"",{"operator":":","operands":[{"operator":"==","operands":["@currentField","Holding"]},"",""]}]}]}]}]}}},{"elmType":"span","style":{"overflow":"hidden","text-overflow":"ellipsis","padding":"0 3px"},"txtContent":"@currentField","attributes":{"class":{"operator":":","operands":[{"operator":"==","operands":["@currentField","Review Plan"]},"",{"operator":":","operands":[{"operator":"==","operands":["@currentField","Plan Approved"]},"",{"operator":":","operands":[{"operator":"==","operands":["@currentField","Completed"]},"",{"operator":":","operands":[{"operator":"==","operands":["@currentField",""]},"",{"operator":":","operands":[{"operator":"==","operands":["@currentField","Holding"]},"",""]}]}]}]}]}}}]}],"templateId":"BgColorChoicePill"}\" ID=\"{ab702905-eb26-401b-a93f-5d71fa5d796d}\" Name=\"Status\" StaticName=\"Status\" Format=\"Dropdown\" FillInChoice=\"FALSE\" PITarget=\"\" PrimaryPITarget=\"\" PIAttribute=\"\" PrimaryPIAttribute=\"\" Aggregation=\"\" Node=\"\"><Default>Review Plan</Default><CHOICES><CHOICE>Review Plan</CHOICE><CHOICE>Plan Approved</CHOICE><CHOICE>Completed</CHOICE><CHOICE>Holding</CHOICE></CHOICES></Field>" }, { "verb": "addSPFieldXml", "schemaXml": "<Field Type=\"Text\" DisplayName=\"Hub Name\" EnforceUniqueValues=\"FALSE\" Required=\"FALSE\" Hidden=\"FALSE\" ReadOnly=\"FALSE\" CanToggleHidden=\"FALSE\" ID=\"{469ab0d4-1e36-4563-bfa3-32867d127031}\" Name=\"HubName\" StaticName=\"HubName\" MaxLength=\"255\" PITarget=\"\" PrimaryPITarget=\"\" PIAttribute=\"\" PrimaryPIAttribute=\"\" Aggregation=\"\" Node=\"\" />" }, { "verb": "addSPFieldXml", "schemaXml": "<Field Type=\"DateTime\" DisplayName=\"Date to move\" EnforceUniqueValues=\"FALSE\" Required=\"FALSE\" Hidden=\"FALSE\" ReadOnly=\"FALSE\" CanToggleHidden=\"FALSE\" ID=\"{9ccfee9d-86fa-4d62-b6cc-0b429d091a1b}\" Name=\"Datetomove\" StaticName=\"Datetomove\" Format=\"DateOnly\" FriendlyDisplayFormat=\"Disabled\" PITarget=\"\" PrimaryPITarget=\"\" PIAttribute=\"\" PrimaryPIAttribute=\"\" Aggregation=\"\" Node=\"\" />" }, { "verb": "addSPView", "name": "All Items", "viewFields": [ "Edit", "LinkTitleNoMenu", "URL", "Status", "Plan", "HubName", "Datetomove" ], "query": "<OrderBy><FieldRef Name=\"Title\" /></OrderBy>", "rowLimit": 30, "isPaged": true, "makeDefault": true, "formatterJSON": "", "replaceViewFields": true }, { "verb": "addSPView", "name": "Datasheet", "viewFields": [ "Edit", "LinkTitleNoMenu", "URL", "Status", "Plan", "HubName" ], "query": "", "rowLimit": 100, "isPaged": true, "replaceViewFields": true } ] } ] } |