Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions app/admin-shell/scripts/admin-shell-overrides.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,8 @@ module.exports = {
'pats',
'featureFlags',
'petoberfest',
'channels'
'channels',
'channel-collections'
],

//
Expand Down Expand Up @@ -163,7 +164,8 @@ module.exports = {
pats: 'pt',
featureFlags: 'ffl',
petoberfest: 'pb',
channels: 'ch'
channels: 'ch',
'channel-collections': 'cc'
},

//
Expand Down
6 changes: 4 additions & 2 deletions app/admin-shell/webapp/controller/Shell.controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,8 @@ sap.ui.define([
petoberfest: "petoberfest",
petoberfestContests: "petoberfestContests",
topicClusters: "topicClusters",
channels: "channels"
channels: "channels",
channelCollections: "channelCollections"
};

var NAV_KEY_TO_TITLE = {
Expand Down Expand Up @@ -119,7 +120,8 @@ sap.ui.define([
petoberfest: "Pet Photo Moderation",
petoberfestContests: "Petoberfest Contests",
topicClusters: "Topic Clusters",
channels: "Channels"
channels: "Channels",
channelCollections: "Channel Collections"
};

return Controller.extend("sap.tutorials.admin.shell.controller.Shell", {
Expand Down
26 changes: 25 additions & 1 deletion app/admin-shell/webapp/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@
"sap.tutorials.admin.pats": "./components/pats",
"sap.tutorials.admin.featureFlags": "./components/featureFlags",
"sap.tutorials.admin.petoberfest": "./components/petoberfest",
"sap.tutorials.admin.channels": "./components/channels"
"sap.tutorials.admin.channels": "./components/channels",
"sap.tutorials.admin.channelCollections": "./components/channel-collections"
},
"models": {
"admin": {
Expand Down Expand Up @@ -386,6 +387,12 @@
"settings": {},
"componentData": {},
"lazy": true
},
"channelCollectionsComponent": {
"name": "sap.tutorials.admin.channelCollections",
"settings": {},
"componentData": {},
"lazy": true
}
},
"services": {
Expand Down Expand Up @@ -906,6 +913,16 @@
}
]
},
{
"name": "channelCollections",
"pattern": "channel-collections",
"target": [
{
"name": "channelCollectionsTarget",
"prefix": "cc"
}
]
},
{
"name": "feedbackDashboard",
"pattern": "feedback/dashboard",
Expand Down Expand Up @@ -1256,6 +1273,13 @@
"viewLevel": 1,
"prefix": "ch"
},
"channelCollectionsTarget": {
"type": "Component",
"usage": "channelCollectionsComponent",
"id": "channelCollectionsTarget",
"viewLevel": 1,
"prefix": "cc"
},
"feedbackDashboardTarget": {
"viewName": "TutorialFeedbackDashboard",
"viewLevel": 1
Expand Down
1 change: 1 addition & 0 deletions app/admin-shell/webapp/model/navigation.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
{ "key": "advocates", "title": "Advocates" },
{ "key": "alerts", "title": "Alerts" },
{ "key": "channels", "title": "Channels" },
{ "key": "channelCollections", "title": "Channel Collections" },
{ "key": "operations", "title": "Featured Tasks" }
]
},
Expand Down
15 changes: 15 additions & 0 deletions app/admin/channel-collections/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"name": "channel-collections-admin",
"version": "0.0.1",
"private": true,
"description": "Channel Collections - Admin Fiori Elements",
"sapux": true,
"scripts": {
"start": "fiori run --open index.html",
"build": "ui5 build --clean-dest"
},
"devDependencies": {
"@sap/ux-specification": "latest",
"@ui5/cli": "^4.0.0"
}
}
12 changes: 12 additions & 0 deletions app/admin/channel-collections/ui5.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
specVersion: "4.0"
metadata:
name: sap.tutorials.admin.channelCollections
type: application
framework:
name: SAPUI5
version: "1.136.0"
libraries:
- name: sap.m
- name: sap.ui.core
- name: sap.ushell
- name: sap.fe.templates
4 changes: 4 additions & 0 deletions app/admin/channel-collections/webapp/Component.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
sap.ui.define(["sap/fe/core/AppComponent"], function (AppComponent) {
"use strict";
return AppComponent.extend("sap.tutorials.admin.channelCollections.Component", { metadata: { manifest: "json" } });
});
2 changes: 2 additions & 0 deletions app/admin/channel-collections/webapp/i18n/i18n.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
appTitle=Channel Collections
appDescription=Manage editorial channel collections
79 changes: 79 additions & 0 deletions app/admin/channel-collections/webapp/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
{
"_version": "1.65.0",
"sap.app": {
"id": "sap.tutorials.admin.channelCollections",
"type": "application",
"title": "{{appTitle}}",
"description": "{{appDescription}}",
"applicationVersion": { "version": "0.0.1" },
"i18n": "i18n/i18n.properties",
"dataSources": {
"mainService": {
"uri": "/admin/",
"type": "OData",
"settings": { "odataVersion": "4.0" }
}
},
"crossNavigation": {
"inbounds": {
"ChannelCollections-manage": {
"semanticObject": "ChannelCollections",
"action": "manage",
"title": "{{appTitle}}",
"signature": { "parameters": {}, "additionalParameters": "allowed" }
}
}
}
},
"sap.ui5": {
"dependencies": {
"minUI5Version": "1.136.0",
"libs": { "sap.fe.templates": {} }
},
"models": {
"": {
"dataSource": "mainService",
"preload": true,
"settings": {
"synchronizationMode": "None",
"operationMode": "Server",
"autoExpandSelect": true,
"earlyRequests": true
}
},
"i18n": {
"type": "sap.ui.model.resource.ResourceModel",
"settings": { "bundleName": "sap.tutorials.admin.channelCollections.i18n.i18n" }
}
},
"routing": {
"routes": [
{ "name": "ChannelCollectionsList", "pattern": ":?query:", "target": "ChannelCollectionsList" },
{ "name": "ChannelCollectionsObject", "pattern": "ChannelCollections({key}):?query:", "target": "ChannelCollectionsObject" }
],
"targets": {
"ChannelCollectionsList": {
"type": "Component",
"id": "ChannelCollectionsList",
"name": "sap.fe.templates.ListReport",
"options": {
"settings": {
"contextPath": "/ChannelCollections",
"initialLoad": "Enabled"
}
}
},
"ChannelCollectionsObject": {
"type": "Component",
"id": "ChannelCollectionsObject",
"name": "sap.fe.templates.ObjectPage",
"options": {
"settings": {
"contextPath": "/ChannelCollections"
}
}
}
}
}
}
}
19 changes: 19 additions & 0 deletions db/channels.cds
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
namespace com.sap.developers.ims;

using { managed, cuid } from '@sap/cds/common';
using { com.sap.developers.ims.AuthoringStatus } from './homepage';

type ChannelOwnerType : String enum {
SAP_Official; SAP_Developer_Advocate; SAP_Executive;
Expand Down Expand Up @@ -41,3 +42,21 @@ entity Channels : cuid, managed {
linkStatusOverride : String(20);
lastChecked : Timestamp;
}

// --- P2: editorial clusters (LLM-drafted, human-reviewed) --------------------
entity ChannelCollections : cuid, managed {
slug : String(80) @mandatory;
title : String(140) @mandatory;
intro : String(1200);
sortOrder : Integer default 100;
isPublished : Boolean default false;
authoringStatus : AuthoringStatus default 'BLANK' @assert.range;
items : Composition of many ChannelCollectionItems on items.collection = $self;
}

entity ChannelCollectionItems : cuid {
collection : Association to ChannelCollections;
channel : Association to Channels;
sortOrder : Integer default 100;
blurb : String(280);
}
105 changes: 105 additions & 0 deletions db/last-dev/csn.json
Original file line number Diff line number Diff line change
Expand Up @@ -2241,6 +2241,111 @@
},
"@cds.persistence.name": "COM_SAP_DEVELOPERS_IMS_CHANNELS"
},
"com.sap.developers.ims.ChannelCollections": {
"kind": "entity",
"@cds.persistence.journal": true,
"elements": {
"ID": {
"key": true,
"type": "cds.String",
"length": 36,
"@cds.persistence.name": "ID"
},
"createdAt": {
"type": "cds.Timestamp",
"@cds.persistence.name": "CREATEDAT"
},
"createdBy": {
"type": "cds.String",
"length": 255,
"@cds.persistence.name": "CREATEDBY"
},
"modifiedAt": {
"type": "cds.Timestamp",
"@cds.persistence.name": "MODIFIEDAT"
},
"modifiedBy": {
"type": "cds.String",
"length": 255,
"@cds.persistence.name": "MODIFIEDBY"
},
"slug": {
"type": "cds.String",
"length": 80,
"@cds.persistence.name": "SLUG"
},
"title": {
"type": "cds.String",
"length": 140,
"@cds.persistence.name": "TITLE"
},
"intro": {
"type": "cds.String",
"length": 1200,
"@cds.persistence.name": "INTRO"
},
"sortOrder": {
"type": "cds.Integer",
"default": {
"val": 100
},
"@cds.persistence.name": "SORTORDER"
},
"isPublished": {
"type": "cds.Boolean",
"default": {
"val": false
},
"@cds.persistence.name": "ISPUBLISHED"
},
"authoringStatus": {
"type": "cds.String",
"default": {
"val": "BLANK"
},
"length": 5000,
"@cds.persistence.name": "AUTHORINGSTATUS"
}
},
"@cds.persistence.name": "COM_SAP_DEVELOPERS_IMS_CHANNELCOLLECTIONS"
},
"com.sap.developers.ims.ChannelCollectionItems": {
"kind": "entity",
"@cds.persistence.journal": true,
"elements": {
"ID": {
"key": true,
"type": "cds.String",
"length": 36,
"@cds.persistence.name": "ID"
},
"collection_ID": {
"type": "cds.String",
"length": 36,
"@odata.foreignKey4": "collection",
"@cds.persistence.name": "COLLECTION_ID"
},
"channel_ID": {
"type": "cds.String",
"length": 36,
"@odata.foreignKey4": "channel",
"@cds.persistence.name": "CHANNEL_ID"
},
"sortOrder": {
"type": "cds.Integer",
"default": {
"val": 100
},
"@cds.persistence.name": "SORTORDER"
},
"blurb": {
"type": "cds.String",
"length": 280,
"@cds.persistence.name": "BLURB"
}
},
"@cds.persistence.name": "COM_SAP_DEVELOPERS_IMS_CHANNELCOLLECTIONITEMS"
},
"com.sap.developers.ims.FailedEmails": {
"kind": "entity",
"@cds.persistence.journal": true,
Expand Down
2 changes: 2 additions & 0 deletions db/persistence.cds
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,5 @@ annotate ims.MetricSnapshots with @cds.persistence.journal;
annotate ims.PublishTimings with @cds.persistence.journal;
annotate ims.TutorialValidationRules with @cds.persistence.journal;
annotate ims.Channels with @cds.persistence.journal;
annotate ims.ChannelCollections with @cds.persistence.journal;
annotate ims.ChannelCollectionItems with @cds.persistence.journal;
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
== version=1
COLUMN TABLE com_sap_developers_ims_ChannelCollectionItems (
ID NVARCHAR(36) NOT NULL,
collection_ID NVARCHAR(36),
channel_ID NVARCHAR(36),
sortOrder INTEGER DEFAULT 100,
blurb NVARCHAR(280),
PRIMARY KEY(ID)
)
15 changes: 15 additions & 0 deletions db/src/com.sap.developers.ims.ChannelCollections.hdbmigrationtable
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
== version=1
COLUMN TABLE com_sap_developers_ims_ChannelCollections (
ID NVARCHAR(36) NOT NULL,
createdAt TIMESTAMP,
createdBy NVARCHAR(255),
modifiedAt TIMESTAMP,
modifiedBy NVARCHAR(255),
slug NVARCHAR(80),
title NVARCHAR(140),
intro NVARCHAR(1200),
sortOrder INTEGER DEFAULT 100,
isPublished BOOLEAN DEFAULT FALSE,
authoringStatus NVARCHAR(5000) DEFAULT 'BLANK',
PRIMARY KEY(ID)
)
Loading
Loading