Skip to content

Commit

Permalink
Merge pull request #29 from DNNCommunity/release/1.1.0
Browse files Browse the repository at this point in the history
Merge `release/1.1.0` into `main` for `1.1.0` release
  • Loading branch information
david-poindexter authored Jul 9, 2023
2 parents 415e998 + 0723126 commit 58eac3d
Show file tree
Hide file tree
Showing 23 changed files with 790 additions and 326 deletions.
56 changes: 56 additions & 0 deletions .github/workflows/Build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# ------------------------------------------------------------------------------
# <auto-generated>
#
# This code was generated.
#
# - To turn off auto-generation set:
#
# [GitHubActions (AutoGenerate = false)]
#
# - To trigger manual generation invoke:
#
# nuke --generate-configuration GitHubActions_Build --host GitHubActions
#
# </auto-generated>
# ------------------------------------------------------------------------------

name: Build

on:
push:
branches:
- main
- master
- develop
- 'release/*'
pull_request:
branches:
- develop
- main
- master
- 'release/*'

jobs:
ubuntu-latest:
name: ubuntu-latest
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: 'Cache: .nuke/temp, ~/.nuget/packages'
uses: actions/cache@v3
with:
path: |
.nuke/temp
~/.nuget/packages
key: ${{ runner.os }}-${{ hashFiles('**/global.json', '**/*.csproj', '**/Directory.Packages.props') }}
- name: 'Run: CI'
run: ./build.cmd CI
env:
GitHubToken: ${{ secrets.GITHUB_TOKEN }}
- name: 'Publish: artifacts'
uses: actions/upload-artifact@v3
with:
name: artifacts
path: artifacts
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ bld/
[Bb]in/
[Oo]bj/
[Ll]og/
.nuke/temp/

# Visual Studio 2015/2017 cache/options directory
.vs/
Expand Down
118 changes: 118 additions & 0 deletions .nuke/build.schema.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,118 @@
{
"$schema": "http://json-schema.org/draft-04/schema#",
"$ref": "#/definitions/build",
"title": "Build Schema",
"definitions": {
"build": {
"type": "object",
"properties": {
"Configuration": {
"type": "string",
"description": "Configuration to build - Default is 'Debug' (local) or 'Release' (server)",
"enum": [
"Debug",
"Release"
]
},
"Continue": {
"type": "boolean",
"description": "Indicates to continue a previously failed build attempt"
},
"Help": {
"type": "boolean",
"description": "Shows the help text for this build assembly"
},
"Host": {
"type": "string",
"description": "Host for execution. Default is 'automatic'",
"enum": [
"AppVeyor",
"AzurePipelines",
"Bamboo",
"Bitbucket",
"Bitrise",
"GitHubActions",
"GitLab",
"Jenkins",
"Rider",
"SpaceAutomation",
"TeamCity",
"Terminal",
"TravisCI",
"VisualStudio",
"VSCode"
]
},
"NoLogo": {
"type": "boolean",
"description": "Disables displaying the NUKE logo"
},
"Partition": {
"type": "string",
"description": "Partition to use on CI"
},
"Plan": {
"type": "boolean",
"description": "Shows the execution plan (HTML)"
},
"Profile": {
"type": "array",
"description": "Defines the profiles to load",
"items": {
"type": "string"
}
},
"Root": {
"type": "string",
"description": "Root directory during build execution"
},
"Skip": {
"type": "array",
"description": "List of targets to be skipped. Empty list skips all dependencies",
"items": {
"type": "string",
"enum": [
"CI",
"Clean",
"Compile",
"Deploy",
"Package",
"Restore",
"SetManifestVersions"
]
}
},
"Solution": {
"type": "string",
"description": "Path to a solution file that is automatically loaded"
},
"Target": {
"type": "array",
"description": "List of targets to be invoked. Default is '{default_target}'",
"items": {
"type": "string",
"enum": [
"CI",
"Clean",
"Compile",
"Deploy",
"Package",
"Restore",
"SetManifestVersions"
]
}
},
"Verbosity": {
"type": "string",
"description": "Logging verbosity during build execution. Default is 'Normal'",
"enum": [
"Minimal",
"Normal",
"Quiet",
"Verbose"
]
}
}
}
}
}
4 changes: 4 additions & 0 deletions .nuke/parameters.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"$schema": "./build.schema.json",
"Solution": "Dnn.CommunityMetrics.sln"
}
23 changes: 0 additions & 23 deletions Controllers/UserActivityController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -396,28 +396,5 @@ private Nullable<int> GetHistoricalCount(int activity_id, int user_id, DateTime
var count = user_activities.Sum(i => i.count);
return count;
}

[NonAction]
public void SaveUserActivity(UserActivityDTO dto)
{
// prevents saving of duplicate activity
CommunityMetrics_UserActivity user_activity = dc.CommunityMetrics_UserActivities.Where(i => i.activity_id == dto.activity_id && i.user_id == dto.user_id && i.date == dto.date).SingleOrDefault();
if (user_activity == null)
{
user_activity = new CommunityMetrics_UserActivity()
{
activity_id = dto.activity_id,
user_id = dto.user_id
};
dc.CommunityMetrics_UserActivities.InsertOnSubmit(user_activity);
}

user_activity.count = dto.count;
user_activity.notes = dto.notes;
user_activity.date = dto.date;
user_activity.created_on_date = DateTime.Now;

dc.SubmitChanges();
}
}
}
86 changes: 22 additions & 64 deletions Dnn.CommunityMetrics.csproj
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Project ToolsVersion="Current" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{20304B35-C633-42D4-B745-34B617FA38F4}</ProjectGuid>
<ProjectTypeGuids>{349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc}</ProjectTypeGuids>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Dnn.CommunityMetrics</RootNamespace>
Expand All @@ -14,63 +13,29 @@
<FileAlignment>512</FileAlignment>
<FileUpgradeFlags>
</FileUpgradeFlags>
<OldToolsVersion>14.0</OldToolsVersion>
<UpgradeBackupLocation />
<UseIISExpress>false</UseIISExpress>
<IISExpressSSLPort />
<IISExpressAnonymousAuthentication />
<IISExpressWindowsAuthentication />
<IISExpressUseClassicPipelineMode />
<UseGlobalApplicationHostFile />
<NuGetPackageImportStamp>
</NuGetPackageImportStamp>
<Use64BitIISExpress />
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>..\..\bin\</OutputPath>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>..\..\..\bin\</OutputPath>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="DotNetNuke">
<HintPath>..\..\bin\DotNetNuke.dll</HintPath>
<Private>False</Private>
</Reference>
<Reference Include="DotNetNuke.Web, Version=9.3.2.0, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\bin\DotNetNuke.Web.dll</HintPath>
</Reference>
<Reference Include="DotNetNuke.Web.Client, Version=9.3.2.0, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\bin\DotNetNuke.Web.Client.dll</HintPath>
</Reference>
<Reference Include="Hammock.ClientProfile">
<HintPath>..\..\bin\Hammock.ClientProfile.dll</HintPath>
<Private>False</Private>
</Reference>
<Reference Include="Microsoft.CSharp" />
<Reference Include="Newtonsoft.Json, Version=7.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\bin\Newtonsoft.Json.dll</HintPath>
<Private>False</Private>
</Reference>
<Reference Include="Octokit">
<HintPath>..\..\bin\Octokit.dll</HintPath>
<Private>False</Private>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />
<Reference Include="System.Data" />
Expand All @@ -84,10 +49,6 @@
<Reference Include="System.Web.DynamicData" />
<Reference Include="System.Web.Entity" />
<Reference Include="System.Web.Extensions" />
<Reference Include="System.Web.Http, Version=5.2.3.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\bin\System.Web.Http.dll</HintPath>
</Reference>
<Reference Include="System.Xml.Linq" />
</ItemGroup>
<ItemGroup>
Expand Down Expand Up @@ -139,6 +100,8 @@
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<Content Include=".gitattributes" />
<Content Include=".gitignore" />
<Content Include="Admin.ascx" />
<Content Include="app\app.js" />
<Content Include="app\controllers\activity-setting\activity-setting-edit.js" />
Expand Down Expand Up @@ -190,33 +153,28 @@
<None Include="DAL\CommunityMetrics.dbml.layout">
<DependentUpon>CommunityMetrics.dbml</DependentUpon>
</None>
<None Include="Dnn.CommunityMetrics.dnn" />
<None Include="LICENSE" />
<None Include="README.md" />
</ItemGroup>
<ItemGroup>
<Service Include="{3259AA49-8AA1-44D3-9025-A0B520596A8C}" />
</ItemGroup>
<ItemGroup />
<ItemGroup>
<PackageReference Include="DotNetNuke.Abstractions">
<Version>9.11.1</Version>
</PackageReference>
<PackageReference Include="DotNetNuke.Web">
<Version>9.11.1</Version>
</PackageReference>
<PackageReference Include="DotNetNuke.Web.Client">
<Version>9.11.1</Version>
</PackageReference>
<PackageReference Include="Octokit">
<Version>0.32.0</Version>
</PackageReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v14.0\WebApplications\Microsoft.WebApplication.targets" />
<ProjectExtensions>
<VisualStudio>
<FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
<WebProjectProperties>
<UseIIS>True</UseIIS>
<AutoAssignPort>True</AutoAssignPort>
<DevelopmentServerPort>9595</DevelopmentServerPort>
<DevelopmentServerVPath>/</DevelopmentServerVPath>
<IISUrl>http://dnn9.localtest.me/DesktopModules/Dnn.CommunityMetrics</IISUrl>
<OverrideIISAppRootUrl>True</OverrideIISAppRootUrl>
<IISAppRootUrl>http://localhost</IISAppRootUrl>
<NTLMAuthentication>False</NTLMAuthentication>
<UseCustomServer>False</UseCustomServer>
<CustomServerUrl>
</CustomServerUrl>
<SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
</WebProjectProperties>
</FlavorProperties>
</VisualStudio>
</ProjectExtensions>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
Expand Down
Loading

0 comments on commit 58eac3d

Please sign in to comment.