Skip to content

Commit

Permalink
## Added new features / Bug fixed
Browse files Browse the repository at this point in the history
・スクリプト、サーバースクリプトにサイト名からサイトIDを取得する関数を追加。
・ユーザのパスワードを生成する機能を追加。
・サイト画像をキャッシュする機能を追加。
・コンテナの公開ポートを80から8080へ修正。
・サーバースクリプトのAddChoiceHashで「検索機能」を使用した場合に別カラムにも検索条件が適応される問題を解消。
・グループのゴミ箱画面に「新規作成」ボタンが表示される問題を解消。
・「API設定」画面でAPIキー削除後のメッセージが適切でない問題を解消。
・ダッシュボード表示時のメニューに「ごみ箱」が表示される問題を解消。
・「作業量」と「進捗率」の詳細設定画面において、利用できない「Null許容」チェックボックスが表示される問題を解消。
・「テーブルの管理」の「ガイド」タブにおいて、ガイドの内容を削除しても削除した内容がプレビュー画面に残る問題を解消。
・項目のアクセス制御において、無効化された組織・グループにもアクセス権が付与される問題を解消。
・ダッシュボードパーツの「タイムライン」で、タイトル、内容欄に設定した項目名がユーザの言語を変更すると機能しない問題を解消。
・プロセスの条件で組織のドロップダウンリストに「自分」を選択した際に正しく判定されない問題を解消。
・サーバスクリプトのgroup.ContainsUserの実行結果が従来と異なる問題を解消。
・新UIでサイトパッケージのエクスポートのダイアログ操作により表示崩れが発生する問題を解消。
・新UIでダッシュボードのタイムラインに表示する内容のフォントサイズがCSSで変更できない問題を解消。
・新UIの画面表示に関連する軽微な問題を解消。
  • Loading branch information
pierre3 committed Jun 11, 2024
1 parent e39bd99 commit 3f7ec04
Show file tree
Hide file tree
Showing 61 changed files with 967 additions and 154 deletions.
6 changes: 3 additions & 3 deletions Implem.CodeDefiner/Implem.CodeDefiner.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
<TargetFramework>net8.0</TargetFramework>
<Copyright>Copyright © Implem Inc 2014 - 2024</Copyright>
<Description>This program does the automatic code creation and merging of existing code based on the definition. Also it will make the configuration change of sql server database.</Description>
<AssemblyVersion>1.4.4.0</AssemblyVersion>
<FileVersion>1.4.4.0</FileVersion>
<Version>1.4.4.0</Version>
<AssemblyVersion>1.4.5.0</AssemblyVersion>
<FileVersion>1.4.5.0</FileVersion>
<Version>1.4.5.0</Version>
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
</PropertyGroup>

Expand Down
6 changes: 3 additions & 3 deletions Implem.DefinitionAccessor/Implem.DefinitionAccessor.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Copyright>Copyright © Implem Inc 2014 - 2024</Copyright>
<AssemblyVersion>1.4.4.0</AssemblyVersion>
<FileVersion>1.4.4.0</FileVersion>
<Version>1.4.4.0</Version>
<AssemblyVersion>1.4.5.0</AssemblyVersion>
<FileVersion>1.4.5.0</FileVersion>
<Version>1.4.5.0</Version>
<Nullable>disable</Nullable>
</PropertyGroup>

Expand Down
1 change: 1 addition & 0 deletions Implem.DefinitionAccessor/Initializer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ public static void SetParameters()
Parameters.Validation = Read<Validation>();
Parameters.Dashboard = Read<Dashboard>();
Parameters.GroupChildren = Read<GroupChildren>();
Parameters.OutputCache = Read<OutputCache>();
Parameters.Rds.SaConnectionString = Strings.CoalesceEmpty(
Parameters.Rds.SaConnectionString,
Environment.GetEnvironmentVariable($"{Parameters.Service.EnvironmentName}_Rds_SaConnectionString"),
Expand Down
6 changes: 3 additions & 3 deletions Implem.DisplayAccessor/Implem.DisplayAccessor.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Copyright>Copyright © Implem Inc 2014 - 2024</Copyright>
<AssemblyVersion>1.4.4.0</AssemblyVersion>
<FileVersion>1.4.4.0</FileVersion>
<Version>1.4.4.0</Version>
<AssemblyVersion>1.4.5.0</AssemblyVersion>
<FileVersion>1.4.5.0</FileVersion>
<Version>1.4.5.0</Version>
<Nullable>disable</Nullable>
</PropertyGroup>

Expand Down
6 changes: 3 additions & 3 deletions Implem.Factory/Implem.Factory.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Copyright>Copyright © Implem Inc 2014 - 2024</Copyright>
<AssemblyVersion>1.4.4.0</AssemblyVersion>
<FileVersion>1.4.4.0</FileVersion>
<Version>1.4.4.0</Version>
<AssemblyVersion>1.4.5.0</AssemblyVersion>
<FileVersion>1.4.5.0</FileVersion>
<Version>1.4.5.0</Version>
<Nullable>disable</Nullable>
</PropertyGroup>

Expand Down
8 changes: 4 additions & 4 deletions Implem.Libraries/Implem.Libraries.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Copyright>Copyright © Implem Inc 2014 - 2024</Copyright>
<AssemblyVersion>1.4.4.0</AssemblyVersion>
<FileVersion>1.4.4.0</FileVersion>
<Version>1.4.4.0</Version>
<AssemblyVersion>1.4.5.0</AssemblyVersion>
<FileVersion>1.4.5.0</FileVersion>
<Version>1.4.5.0</Version>
<Nullable>disable</Nullable>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="CsvHelper" Version="31.0.3" />
<PackageReference Include="CsvHelper" Version="32.0.3" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
<PackageReference Include="SixLabors.ImageSharp" Version="3.1.4" />
<PackageReference Include="System.IO.FileSystem.Primitives" Version="4.3.0" />
Expand Down
6 changes: 3 additions & 3 deletions Implem.ParameterAccessor/Implem.ParameterAccessor.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Copyright>Copyright © Implem Inc 2014 - 2024</Copyright>
<AssemblyVersion>1.4.4.0</AssemblyVersion>
<FileVersion>1.4.4.0</FileVersion>
<Version>1.4.4.0</Version>
<AssemblyVersion>1.4.5.0</AssemblyVersion>
<FileVersion>1.4.5.0</FileVersion>
<Version>1.4.5.0</Version>
<Nullable>disable</Nullable>
</PropertyGroup>

Expand Down
1 change: 1 addition & 0 deletions Implem.ParameterAccessor/Parameters.cs
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ public static class Parameters
public static Validation Validation;
public static Dashboard Dashboard;
public static GroupChildren GroupChildren;
public static OutputCache OutputCache;

public static bool CommercialLicense()
{
Expand Down
8 changes: 8 additions & 0 deletions Implem.ParameterAccessor/Parts/OutputCache.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
using System.Collections.Generic;
namespace Implem.ParameterAccessor.Parts
{
public class OutputCache
{
public OutputCacheControl OutputCacheControl;
}
}
8 changes: 8 additions & 0 deletions Implem.ParameterAccessor/Parts/OutputCacheControl.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
namespace Implem.ParameterAccessor.Parts
{
public class OutputCacheControl
{
public bool NoOutputCache;
public int OutputCacheDuration;
}
}
2 changes: 1 addition & 1 deletion Implem.ParameterAccessor/Parts/SecureCacheControl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ public class SecureCacheControl
public bool NoStore;
public bool Private;
public bool MustRevalidate;
public bool PragmaNoCache;
public bool PragmaNoCache;
}
}
1 change: 1 addition & 0 deletions Implem.ParameterAccessor/Parts/Security.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ public class Security
public bool DisableCheckPasswordPolicyIfApi;
public List<PasswordPolicy> PasswordPolicies;
public SecondaryAuthentication SecondaryAuthentication;
public bool PasswordGenerator;
public AspNetCoreDataProtection AspNetCoreDataProtection;
public HttpStrictTransportSecurity HttpStrictTransportSecurity;
public SecureCacheControl SecureCacheControl;
Expand Down
18 changes: 0 additions & 18 deletions Implem.Pleasanter.sln
Original file line number Diff line number Diff line change
Expand Up @@ -42,16 +42,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Implem.TestAutomation", "Im
{C082A0D7-13C6-4D8A-9735-3C302E81B280} = {C082A0D7-13C6-4D8A-9735-3C302E81B280}
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "CICD", "CICD", "{EDD4BA11-3C06-4DE2-82CA-D0B945EE21E6}"
ProjectSection(SolutionItems) = preProject
.github\workflows\stale.yml = .github\workflows\stale.yml
.github\workflows\build-docker-images.yaml = .github\workflows\build-docker-images.yml
EndProjectSection
EndProject
Project("{E53339B2-1760-4266-BCC7-CA923CBCF16C}") = "docker-compose", "docker-compose.dcproj", "{10984740-E12C-427F-A980-0100734AE1B9}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Implem.PleasanterTest", "Implem.PleasanterTest\Implem.PleasanterTest.csproj", "{2563902C-E1D2-4ED7-9B1B-B836C485267A}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Implem.Plugins", "Implem.Plugins\Implem.Plugins.csproj", "{DB7A8513-48C4-4226-92F9-60FD4DB90DD8}"
EndProject
Global
Expand Down Expand Up @@ -181,16 +173,6 @@ Global
{10984740-E12C-427F-A980-0100734AE1B9}.Release|Any CPU.ActiveCfg = Release|Any CPU
{10984740-E12C-427F-A980-0100734AE1B9}.SingleImage|Any CPU.ActiveCfg = Release|Any CPU
{10984740-E12C-427F-A980-0100734AE1B9}.SingleImage|Any CPU.Build.0 = Release|Any CPU
{2563902C-E1D2-4ED7-9B1B-B836C485267A}.CD_ROM|Any CPU.ActiveCfg = Debug|Any CPU
{2563902C-E1D2-4ED7-9B1B-B836C485267A}.CD_ROM|Any CPU.Build.0 = Debug|Any CPU
{2563902C-E1D2-4ED7-9B1B-B836C485267A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{2563902C-E1D2-4ED7-9B1B-B836C485267A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2563902C-E1D2-4ED7-9B1B-B836C485267A}.DVD-5|Any CPU.ActiveCfg = Debug|Any CPU
{2563902C-E1D2-4ED7-9B1B-B836C485267A}.DVD-5|Any CPU.Build.0 = Debug|Any CPU
{2563902C-E1D2-4ED7-9B1B-B836C485267A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2563902C-E1D2-4ED7-9B1B-B836C485267A}.Release|Any CPU.Build.0 = Release|Any CPU
{2563902C-E1D2-4ED7-9B1B-B836C485267A}.SingleImage|Any CPU.ActiveCfg = Debug|Any CPU
{2563902C-E1D2-4ED7-9B1B-B836C485267A}.SingleImage|Any CPU.Build.0 = Debug|Any CPU
{DB7A8513-48C4-4226-92F9-60FD4DB90DD8}.CD_ROM|Any CPU.ActiveCfg = Debug|Any CPU
{DB7A8513-48C4-4226-92F9-60FD4DB90DD8}.CD_ROM|Any CPU.Build.0 = Debug|Any CPU
{DB7A8513-48C4-4226-92F9-60FD4DB90DD8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@

<!--Model_OnCreatingExtendedSqls-->
<!--Model_OnCreatingGroupMembers-->
<!--Model_WriteAttachmentsExecute_Create-->
<!--Model_OnCreatingGroupChildren-->

statements.AddRange(CreateStatements(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
"NumB",
"NumC",
"NumD",
"DateA",
"StartTime",
"CompletionTime",
"Status",
Expand All @@ -34,7 +33,6 @@
"NumB",
"NumC",
"NumD",
"DateA",
"StartTime",
"CompletionTime",
"Status",
Expand Down Expand Up @@ -131,15 +129,11 @@
{
"ColumnName": "ClassC",
"LabelText": "商品区分",
"ChoicesText": "商品区分1\n商品区分2\n商品区分3\n商品区分4\n商品区分5"
"ChoicesText": "システム開発\nソフトウェア販売\nコンサルティング"
},
{
"ColumnName": "StartTime",
"LabelText": "商談開始日"
},
{
"ColumnName": "DateA",
"DateFilterSetMode": 2
}
],
"Aggregations": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,14 @@
"GridColumns": [
"ResultId",
"ClassF",
"TitleBody",
"Comments",
"Title",
"ClassH",
"DateA",
"DateB",
"ClassA",
"ClassB",
"ClassD",
"DateC",
"NumA",
"NumB",
"Updator",
"UpdatedTime"
],
Expand Down
34 changes: 34 additions & 0 deletions Implem.Pleasanter/App_Data/Displays/PasswordAutoGenerate.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"Id": "PasswordAutoGenerate",
"Type": "110",
"ClientScript": true,
"Languages": [
{
"Body": "Password Auto Generate"
},
{
"Language": "zh",
"Body": "密码自动生成"
},
{
"Language": "ja",
"Body": "パスワード自動生成"
},
{
"Language": "de",
"Body": "Kennwort automatisch generieren"
},
{
"Language": "ko",
"Body": "비밀번호 자동 생성"
},
{
"Language": "es",
"Body": "Generación automática de contraseñas"
},
{
"Language": "vn",
"Body": "Tự động tạo mật khẩu"
}
]
}
6 changes: 6 additions & 0 deletions Implem.Pleasanter/App_Data/Parameters/OutputCache.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"OutputCacheControl": {
"NoOutputCache": false,
"OutputCacheDuration": 86400
}
}
1 change: 1 addition & 0 deletions Implem.Pleasanter/App_Data/Parameters/Security.json
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@
]
}
],
"PasswordGenerator": true,
"SecondaryAuthentication": {
"Mode": "None",
"NotificationType": "Mail",
Expand Down
1 change: 1 addition & 0 deletions Implem.Pleasanter/App_Start/BundleConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ public static IEnumerable<string> Generals()
"~/scripts/formula.js",
"~/scripts/gantt.js",
"~/scripts/ganttevents.js",
"~/scripts/generatepassword.js",
"~/scripts/grid.js",
"~/scripts/gridevents.js",
"~/scripts/group.js",
Expand Down
21 changes: 21 additions & 0 deletions Implem.Pleasanter/Controllers/Api/ItemsController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -314,5 +314,26 @@ public ContentResult UpdateSiteSettings(long id)
log.Finish(context: context, responseSize: result.Content.Length);
return result.ToHttpResponse(request: Request);
}

[HttpPost("{id}/GetClosestSiteId")]
public ContentResult GetClosestSiteId(long id)
{
var body = default(string);
using (var reader = new StreamReader(Request.Body)) body = reader.ReadToEnd();
var context = new Context(
sessionStatus: User?.Identity?.IsAuthenticated == true,
sessionData: User?.Identity?.IsAuthenticated == true,
apiRequestBody: body,
contentType: Request.ContentType,
api: true);
var log = new SysLogModel(context: context);
var result = context.Authenticated
? SiteUtilities.GetClosestSiteIdByApi(
context: context,
id: id)
: ApiResults.Unauthorized(context: context);
log.Finish(context: context, responseSize: result.Content.Length);
return result.ToHttpResponse(request: Request);
}
}
}
2 changes: 2 additions & 0 deletions Implem.Pleasanter/Controllers/BinariesController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.OutputCaching;
using System.Collections.Generic;
using System.Linq;
namespace Implem.Pleasanter.Controllers
Expand All @@ -15,6 +16,7 @@ public class BinariesController : Controller
{
[HttpGet]
[ResponseCache(Duration = int.MaxValue)]
[OutputCache(PolicyName = "imageCache")]
public ActionResult SiteImageThumbnail(string reference, long id)
{
var context = new Context();
Expand Down
15 changes: 15 additions & 0 deletions Implem.Pleasanter/Controllers/UsersController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -724,5 +724,20 @@ public string PhysicalDelete(long id)
log.Finish(context: context, responseSize: json.Length);
return json;
}

/// <summary>
/// Fixed:
/// </summary>
[HttpPost]
public string GeneratePassword(string passwordObject, string passwordValidateObject)
{
var context = new Context();
var log = new SysLogModel(context: context);
var json = UserUtilities.GeneratePassword(
passwordObject,
passwordValidateObject);
log.Finish(context: context, responseSize: json.Length);
return json;
}
}
}
23 changes: 20 additions & 3 deletions Implem.Pleasanter/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
#See https://aka.ms/containerfastmode to understand how Visual Studio uses this Dockerfile to build your images for faster debugging.

FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base
RUN apt-get update && apt-get install -y libgdiplus
RUN apt-get update && apt-get install -y \
libgdiplus \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

WORKDIR /app
EXPOSE 80
EXPOSE 8080

FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
WORKDIR /src
Expand All @@ -24,12 +27,26 @@ WORKDIR "/src/Implem.Pleasanter"
RUN dotnet build "Implem.Pleasanter.csproj" -c Release -o /app/build

FROM build AS publish
RUN apt-get update && apt-get install -y jq
RUN apt-get update && apt-get install -y \
jq \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

RUN dotnet publish "Implem.Pleasanter.csproj" -c Release -o /app/publish
RUN cat App_Data/Parameters/Rds.json \
| jq '.Dbms|="PostgreSQL" | .SaConnectionString|=null | .OwnerConnectionString|=null | .UserConnectionString|=null' \
> /app/publish/App_Data/Parameters/Rds.json

FROM publish AS settings
RUN cat App_Data/Parameters/Service.json \
| jq '.WithoutChangeDefaultPassword|=true | .ShowStartGuide|=false | .Demo|=false' \
> /app/publish/App_Data/Parameters/Service.json

FROM base AS testing
WORKDIR /app
COPY --from=settings /app/publish .
ENTRYPOINT ["dotnet", "Implem.Pleasanter.dll"]

FROM base AS final
WORKDIR /app
COPY --from=publish /app/publish .
Expand Down
Loading

0 comments on commit 3f7ec04

Please sign in to comment.