Open StefanMaron opened 1 year ago
@StefanMaron, will it be possible to add a code? Can you try to use this example https://github.com/vody/CustomerRewardsFFExample with your flag identifier?
with this code, if I just do what I described above, am seeing the fields being cleared but not removed. Eventually, after a few relogs, I can see the field being gone completely.
I also tried die Condition provider. And I did not see those issues (yet) with this one.
pageextension 50100 CustomerList extends "Customer Card"
{
layout
{
addlast(General)
{
field(Testfield1; 'MYCOOLTESTFEATURE')
{
ApplicationArea = MYCOOLTESTFEATURE;
}
field(Testfield2; 'DEMOFEATURE')
{
ApplicationArea = DEMOFEATURE;
}
}
}
trigger OnOpenPage()
var
FeatureMgt: Codeunit FeatureMgt_FF_TSL;
begin
if FeatureMgt.IsEnabled('MYCOOLTESTFEATURE') then
Message('Yayyyay!');
end;
}
codeunit 50100 "TestInstall"
{
Subtype = Install;
trigger OnInstallAppPerCompany();
begin
AddCustomFeature();
end;
local procedure AddCustomFeature();
var
PostHogProvider: Codeunit "PostHogProvider_FF_TSL";
SecretProvider: Codeunit MySecretProvider;
ISecretProvider: Interface "Secret Provider";
PersonalAPIKey, ProjectID : Text;
begin
// App PostHog provider. It will load all available features automatically.
ISecretProvider := SecretProvider;
ISecretProvider.GetSecret('PostHogPersonalAPIKey', PersonalAPIKey);
ISecretProvider.GetSecret('PostHogProjectID', ProjectID);
if not PostHogProvider.AddProvider('SMC_POSTHOG', PersonalAPIKey, ProjectID) then
Error(GetLastErrorText());
end;
}
@StefanMaron, thank you for your feedback and that you are trying it out :). I will check and comment on the state.
Describe the bug When a feature is disabled, and the application are is used on a field, the field does not get hidden. Just the value is not displayed anymore
To Reproduce Steps to reproduce the behavior:
Expected behavior The field gets hidden completely
Screenshots If applicable, add screenshots to help explain your problem.
Additional context This is again maybe more a question of what I am doing wrong, or to understand how the application areas work exactly. I know you are already using this app in production so I guess you might have some more insight. I did test this with the posthog provider. Everything else seems to be working quite well.