From 0ebafd5a27186f6767f209b6cd8a0659730124ac Mon Sep 17 00:00:00 2001 From: Suresh Balasubramanian Date: Thu, 9 Oct 2025 21:24:11 +0530 Subject: [PATCH 01/14] .shop -> .xyz --- Constants/RoutingConstants.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Constants/RoutingConstants.cs b/Constants/RoutingConstants.cs index c47ffc9f..4bea5207 100644 --- a/Constants/RoutingConstants.cs +++ b/Constants/RoutingConstants.cs @@ -7,11 +7,11 @@ namespace ExpressBase.Common public static class RoutingConstants { public const string LIVEHOSTADDRESS = ".expressbase.com"; - public const string STAGEHOSTADDRESS = ".eb-test.shop"; + public const string STAGEHOSTADDRESS = ".eb-test.xyz"; public const string LOCALHOSTADDRESS = ".localhost"; public const string LOCALHOST = "localhost"; - public const string STAGEHOST = "eb-test.shop"; + public const string STAGEHOST = "eb-test.xyz"; public const string WWWDOT = "www."; //DashBoard Routes From b2a78e7890a9e2200f451e2481a302929f054840 Mon Sep 17 00:00:00 2001 From: Suresh Balasubramanian Date: Fri, 10 Oct 2025 00:29:27 +0530 Subject: [PATCH 02/14] npgsql upgrade 4.0.3->5.0.18 --- Data/PostgreSQL/PGSQLDatabase.cs | 2 +- ExpressBase.Common.csproj | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Data/PostgreSQL/PGSQLDatabase.cs b/Data/PostgreSQL/PGSQLDatabase.cs index a2a9f6b2..ca5fe4a7 100644 --- a/Data/PostgreSQL/PGSQLDatabase.cs +++ b/Data/PostgreSQL/PGSQLDatabase.cs @@ -102,7 +102,7 @@ public override IVendorDbTypes VendorDbTypes } private const string CONNECTION_STRING_BARE_WITHOUT_SSL = "Host={0}; Port={1}; Database={2}; Username={3}; Password={4}; Trust Server Certificate=true; Pooling=true; CommandTimeout={5};"; - private const string CONNECTION_STRING_BARE = "Host={0}; Port={1}; Database={2}; Username={3}; Password={4}; Trust Server Certificate=true; Pooling=true; CommandTimeout={5};SSL Mode=Require; Use SSL Stream=true; "; + private const string CONNECTION_STRING_BARE = "Host={0}; Port={1}; Database={2}; Username={3}; Password={4}; Trust Server Certificate=true; Pooling=true; CommandTimeout={5};SSL Mode=Require; "; //SSL Mode=Require; Use SSL Stream=true; private string _cstr; private EbDbConfig DbConfig { get; set; } diff --git a/ExpressBase.Common.csproj b/ExpressBase.Common.csproj index 126f4093..a64a6ead 100644 --- a/ExpressBase.Common.csproj +++ b/ExpressBase.Common.csproj @@ -66,7 +66,7 @@ - + From c780c1fa210d35af8510b8c56563afa71772d595 Mon Sep 17 00:00:00 2001 From: Suresh Balasubramanian Date: Sun, 12 Oct 2025 18:39:16 +0530 Subject: [PATCH 03/14] npgsql upgrade 4.0.3->5.0.18 revered --- Data/PostgreSQL/PGSQLDatabase.cs | 2 +- ExpressBase.Common.csproj | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Data/PostgreSQL/PGSQLDatabase.cs b/Data/PostgreSQL/PGSQLDatabase.cs index ca5fe4a7..a2a9f6b2 100644 --- a/Data/PostgreSQL/PGSQLDatabase.cs +++ b/Data/PostgreSQL/PGSQLDatabase.cs @@ -102,7 +102,7 @@ public override IVendorDbTypes VendorDbTypes } private const string CONNECTION_STRING_BARE_WITHOUT_SSL = "Host={0}; Port={1}; Database={2}; Username={3}; Password={4}; Trust Server Certificate=true; Pooling=true; CommandTimeout={5};"; - private const string CONNECTION_STRING_BARE = "Host={0}; Port={1}; Database={2}; Username={3}; Password={4}; Trust Server Certificate=true; Pooling=true; CommandTimeout={5};SSL Mode=Require; "; + private const string CONNECTION_STRING_BARE = "Host={0}; Port={1}; Database={2}; Username={3}; Password={4}; Trust Server Certificate=true; Pooling=true; CommandTimeout={5};SSL Mode=Require; Use SSL Stream=true; "; //SSL Mode=Require; Use SSL Stream=true; private string _cstr; private EbDbConfig DbConfig { get; set; } diff --git a/ExpressBase.Common.csproj b/ExpressBase.Common.csproj index a64a6ead..126f4093 100644 --- a/ExpressBase.Common.csproj +++ b/ExpressBase.Common.csproj @@ -66,7 +66,7 @@ - + From 37d9dfd74eb570c45448fc9aee4af26b4c201a62 Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Sat, 31 Jan 2026 21:10:25 +0400 Subject: [PATCH 04/14] Email configuartion - UserName added --- Connections/EbDatabaseConnection.cs | 2 ++ Data/EbEmail.cs | 6 +++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/Connections/EbDatabaseConnection.cs b/Connections/EbDatabaseConnection.cs index 2bb23332..4c073953 100644 --- a/Connections/EbDatabaseConnection.cs +++ b/Connections/EbDatabaseConnection.cs @@ -336,6 +336,8 @@ public class EbMongoConfig : EbIntegrationConf public class EbEmailConfig : EbIntegrationConf { public string EmailAddress { get; set; } + + public string UserName { get; set; } } public class EbSmtpConfig : EbEmailConfig diff --git a/Data/EbEmail.cs b/Data/EbEmail.cs index 9f5b8e48..01fdffd1 100644 --- a/Data/EbEmail.cs +++ b/Data/EbEmail.cs @@ -33,7 +33,11 @@ public EbSmtp(EbSmtpConfig config) Host = Config.Host, Port = Config.Port, UseDefaultCredentials = false, - Credentials = new NetworkCredential { UserName = Config.EmailAddress, Password = Config.Password }, + Credentials = new NetworkCredential + { + UserName = string.IsNullOrWhiteSpace(Config.UserName) ? Config.EmailAddress : Config.UserName, + Password = Config.Password + }, EnableSsl = Config.EnableSsl }; } From fa430bb9d51b66c911994c72dc4c01a26e13f69e Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Tue, 3 Feb 2026 15:47:19 +0400 Subject: [PATCH 05/14] Short url heplers, string extensions, c7 favicon --- Constants/EnvironmentConstants.cs | 2 + Constants/RedisKeyPrefixConstants.cs | 4 + Extensions/StringExtensions.cs | 10 +++ Helpers/ShortUrlHelper.cs | 108 +++++++++++++++++++++++++++ Helpers/UrlHelper.cs | 9 +++ 5 files changed, 133 insertions(+) create mode 100644 Helpers/ShortUrlHelper.cs diff --git a/Constants/EnvironmentConstants.cs b/Constants/EnvironmentConstants.cs index ebdf2669..5d85455f 100644 --- a/Constants/EnvironmentConstants.cs +++ b/Constants/EnvironmentConstants.cs @@ -116,5 +116,7 @@ public static class EnvironmentConstants public const string MOVEON_AZURE_PNS_CON = "MOVEON_AZURE_PNS_CON"; public const string MOVEON_AZURE_PNS_HUBNAME = "MOVEON_AZURE_PNS_HUBNAME"; public const string EB_API_SECRET = "EB_API_SECRET"; + + public const string EB_URL_HASH_SALT = "EB_URL_HASH_SALT"; } } diff --git a/Constants/RedisKeyPrefixConstants.cs b/Constants/RedisKeyPrefixConstants.cs index 8828059f..f8cf9f78 100644 --- a/Constants/RedisKeyPrefixConstants.cs +++ b/Constants/RedisKeyPrefixConstants.cs @@ -10,5 +10,9 @@ public static class RedisKeyPrefixConstants public const string EbWebformObject = "EbWebformObject_{0}_{1}"; public const string EbWebformMd5 = "EbWebformMd5_{0}_{1}"; + + public const string EbShortUrlCounter = "EbShortUrlCounter"; + + public const string EbShortUrlItem = "EbShortUrlItem_{0}";// {0} -> shortUrlId } } diff --git a/Extensions/StringExtensions.cs b/Extensions/StringExtensions.cs index 613f3fee..933fc6a5 100644 --- a/Extensions/StringExtensions.cs +++ b/Extensions/StringExtensions.cs @@ -70,6 +70,16 @@ public static EbObjectType GetEbObjectType(this string RefId) return EbObjectTypes.Get(Convert.ToInt32(RefId.Split("-")[2])); } + public static int GetEbObjectId(this string RefId) + { + return Convert.ToInt32(RefId.Split("-")[3]); + } + + public static int GetEbObjectVerionId(this string RefId) + { + return Convert.ToInt32(RefId.Split("-")[4]); + } + #endregion public static TEnum ToEnum(this string value, bool ignoreCase = false) where TEnum : struct diff --git a/Helpers/ShortUrlHelper.cs b/Helpers/ShortUrlHelper.cs new file mode 100644 index 00000000..951d5466 --- /dev/null +++ b/Helpers/ShortUrlHelper.cs @@ -0,0 +1,108 @@ +using ExpressBase.Common.Constants; +using ServiceStack.Redis; +using System; +using System.Security.Cryptography; +using System.Text; + +namespace ExpressBase.Common.Helpers +{ + public static class ShortUrlHelper + { + private const string chars = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"; + + private static string Encode(long value) + { + if (value == 0) return chars[0].ToString(); + + var result = new StringBuilder(); + while (value > 0) + { + result.Insert(0, chars[(int)(value % 62)]); + value /= 62; + } + return result.ToString(); + } + + private static long Decode(string input) + { + long result = 0; + foreach (char c in input) + { + result = result * 62 + chars.IndexOf(c); + } + return result; + } + + public static string CreateShortUrl(string originalUrl, RedisClient Redis, TimeSpan expiry) + { + if (expiry == null) + { + expiry = new TimeSpan(1, 0, 0); + } + + long id = Redis.Get(RedisKeyPrefixConstants.EbShortUrlCounter); + if (id == 0) + { + id = 1; // Starting point for IDs + } + + string base62Id = Encode(id); + string secret = Environment.GetEnvironmentVariable(EnvironmentConstants.EB_URL_HASH_SALT) ?? + Environment.GetEnvironmentVariable(EnvironmentConstants.EB_EMAIL_PASSWORD); + + using (HMACSHA256 hmac = new HMACSHA256(Encoding.UTF8.GetBytes(secret))) + { + byte[] hash = hmac.ComputeHash(Encoding.UTF8.GetBytes(base62Id)); + string hashvalue = Convert.ToBase64String(hash).Replace("+", "").Replace("/", "").Substring(0, 8); + + Redis.Set(RedisKeyPrefixConstants.EbShortUrlCounter, id + 1); + Redis.Set(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, id), $"{originalUrl}&s={id}", expiry); + + return $"/tiny/{base62Id}.{hashvalue}"; + } + } + + public static string GetOriginalUrl(string shortUrlId, RedisClient Redis) + { + string[] parts = shortUrlId.Split('.'); + if (parts.Length != 2) + { + return "/StatusCode/404?m=invalid_format"; // Invalid format + } + string base62Id = parts[0]; + string providedHash = parts[1]; + long id = Decode(base62Id); + string secret = Environment.GetEnvironmentVariable(EnvironmentConstants.EB_URL_HASH_SALT) ?? + Environment.GetEnvironmentVariable(EnvironmentConstants.EB_EMAIL_PASSWORD); + using (HMACSHA256 hmac = new HMACSHA256(Encoding.UTF8.GetBytes(secret))) + { + byte[] hash = hmac.ComputeHash(Encoding.UTF8.GetBytes(base62Id)); + string expectedHash = Convert.ToBase64String(hash).Replace("+", "").Replace("/", "").Substring(0, 8); + if (expectedHash != providedHash) + { + return "/StatusCode/404?m=invalid_url"; // Hash mismatch, invalid URL + } + string originalUrl = Redis.Get(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, id)); + if (originalUrl == null) + originalUrl = "/StatusCode/404?m=not_found"; + return originalUrl; + } + } + + public static void MarkShortUrlProcessed(long shortUrlId, RedisClient Redis) + { + try + { + string originalUrl = Redis.Get(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, shortUrlId)); + if (originalUrl != null) + { + Redis.Set(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, shortUrlId), $"/StatusCode/703", new TimeSpan(1, 0, 0)); + } + } + catch (Exception ex) + { + + } + } + } +} diff --git a/Helpers/UrlHelper.cs b/Helpers/UrlHelper.cs index 3bec0c12..8d26a677 100644 --- a/Helpers/UrlHelper.cs +++ b/Helpers/UrlHelper.cs @@ -29,6 +29,8 @@ public static string GetIconUrl(string Host) { if (ContainsOloi(Host)) return "/images/favicon_kdisc.ico"; + if (ContainsC7(Host)) + return "/images/favicon_c7.ico"; return "/images/favicon.ico"; } @@ -36,6 +38,8 @@ public static string GetLoginPageDescription(string Host) { if (ContainsOloi(Host)) return "Kerala Development and Innovation Strategic Council (K-DISC)"; + if (ContainsC7(Host)) + return "Best Skin and Dental Clinic in Kochi - Clinic7"; return null; } @@ -69,5 +73,10 @@ public static bool ContainsOloi(string Host) { return Host?.ToLower()?.Contains("oloi") == true; } + + private static bool ContainsC7(string Host) + { + return Host?.ToLower()?.Contains("clinic7") == true; + } } } From ef4ed164a0eb72e8743786065821230eddfcb0bc Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Sat, 7 Feb 2026 00:58:19 +0400 Subject: [PATCH 06/14] Short url helper - id increment - thread safety --- Helpers/ShortUrlHelper.cs | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/Helpers/ShortUrlHelper.cs b/Helpers/ShortUrlHelper.cs index 951d5466..453cbb74 100644 --- a/Helpers/ShortUrlHelper.cs +++ b/Helpers/ShortUrlHelper.cs @@ -33,6 +33,9 @@ private static long Decode(string input) return result; } + // Add a static object for locking + private static readonly object idLock = new object(); + public static string CreateShortUrl(string originalUrl, RedisClient Redis, TimeSpan expiry) { if (expiry == null) @@ -40,7 +43,14 @@ public static string CreateShortUrl(string originalUrl, RedisClient Redis, TimeS expiry = new TimeSpan(1, 0, 0); } - long id = Redis.Get(RedisKeyPrefixConstants.EbShortUrlCounter); + long id = 0; + + lock (idLock) + { + id = Redis.Get(RedisKeyPrefixConstants.EbShortUrlCounter); + Redis.Set(RedisKeyPrefixConstants.EbShortUrlCounter, id + 1); + } + if (id == 0) { id = 1; // Starting point for IDs @@ -55,7 +65,6 @@ public static string CreateShortUrl(string originalUrl, RedisClient Redis, TimeS byte[] hash = hmac.ComputeHash(Encoding.UTF8.GetBytes(base62Id)); string hashvalue = Convert.ToBase64String(hash).Replace("+", "").Replace("/", "").Substring(0, 8); - Redis.Set(RedisKeyPrefixConstants.EbShortUrlCounter, id + 1); Redis.Set(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, id), $"{originalUrl}&s={id}", expiry); return $"/tiny/{base62Id}.{hashvalue}"; From 629c5ad4f2ab0b32bf4d375cbd51a1fc13a30b20 Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Sat, 7 Feb 2026 17:25:07 +0400 Subject: [PATCH 07/14] Url helper - default page description --- Helpers/UrlHelper.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Helpers/UrlHelper.cs b/Helpers/UrlHelper.cs index 8d26a677..1207761a 100644 --- a/Helpers/UrlHelper.cs +++ b/Helpers/UrlHelper.cs @@ -40,7 +40,7 @@ public static string GetLoginPageDescription(string Host) return "Kerala Development and Innovation Strategic Council (K-DISC)"; if (ContainsC7(Host)) return "Best Skin and Dental Clinic in Kochi - Clinic7"; - return null; + return "EXPRESSbase: Rapid Application Development & Delivery Platform for SMBs"; } public static string GetUserNameLabel(string Host) From 2f0d865e3bb472f33b47f3df0cec5916d0e7a479 Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Sat, 7 Feb 2026 21:58:40 +0400 Subject: [PATCH 08/14] Short url - Check edit permission for anonym user --- Helpers/ShortUrlHelper.cs | 40 +++++++++++++++++++++++++++++++++++++-- 1 file changed, 38 insertions(+), 2 deletions(-) diff --git a/Helpers/ShortUrlHelper.cs b/Helpers/ShortUrlHelper.cs index 453cbb74..b489cfb6 100644 --- a/Helpers/ShortUrlHelper.cs +++ b/Helpers/ShortUrlHelper.cs @@ -1,6 +1,12 @@ using ExpressBase.Common.Constants; +using ExpressBase.Common.Data; +using ExpressBase.Common.Extensions; +using Microsoft.AspNetCore.WebUtilities; +using Newtonsoft.Json; using ServiceStack.Redis; using System; +using System.Collections.Generic; +using System.Linq; using System.Security.Cryptography; using System.Text; @@ -36,7 +42,7 @@ private static long Decode(string input) // Add a static object for locking private static readonly object idLock = new object(); - public static string CreateShortUrl(string originalUrl, RedisClient Redis, TimeSpan expiry) + public static string CreateShortUrl(string RefId, string parameters, int mode, RedisClient Redis, TimeSpan expiry) { if (expiry == null) { @@ -65,7 +71,9 @@ public static string CreateShortUrl(string originalUrl, RedisClient Redis, TimeS byte[] hash = hmac.ComputeHash(Encoding.UTF8.GetBytes(base62Id)); string hashvalue = Convert.ToBase64String(hash).Replace("+", "").Replace("/", "").Substring(0, 8); - Redis.Set(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, id), $"{originalUrl}&s={id}", expiry); + string longUrl = $"/PublicForm?id={RefId}&p={parameters}&m={mode}&s={id}"; + + Redis.Set(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, id), longUrl, expiry); return $"/tiny/{base62Id}.{hashvalue}"; } @@ -113,5 +121,33 @@ public static void MarkShortUrlProcessed(long shortUrlId, RedisClient Redis) } } + + public static bool CheckEditPermissionForAnonymUser(int userId, string refId, int dataId, long shortUrlId, RedisClient Redis) + { + if (userId > 1 || dataId <= 0) return true; + if (shortUrlId == 0) return false; + + try + { + string originalUrl = Redis.Get(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, shortUrlId)); + if (string.IsNullOrEmpty(originalUrl) || !originalUrl.Contains($"/PublicForm?id={refId}&p=")) + return false; + + string query = originalUrl.Substring(originalUrl.IndexOf('?')); + Dictionary query_params = QueryHelpers.ParseQuery(query).ToDictionary(x => x.Key, x => x.Value.ToString()); + + if (query_params["s"] != shortUrlId.ToString()) + return false; + + List ob = JsonConvert.DeserializeObject>(query_params["p"].FromBase64()); + if (ob.Count == 1 && ob[0].Name == "id") + { + if (ob[0].Value == dataId.ToString()) + return true; + } + } + catch (Exception ex) { } + return false; + } } } From f05a6c975237d25cfccc07690067e533d52f7208 Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Sat, 7 Feb 2026 22:06:31 +0400 Subject: [PATCH 09/14] Minor change in ShortUrlHelper --- Helpers/ShortUrlHelper.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Helpers/ShortUrlHelper.cs b/Helpers/ShortUrlHelper.cs index b489cfb6..3ebcabac 100644 --- a/Helpers/ShortUrlHelper.cs +++ b/Helpers/ShortUrlHelper.cs @@ -63,8 +63,7 @@ public static string CreateShortUrl(string RefId, string parameters, int mode, R } string base62Id = Encode(id); - string secret = Environment.GetEnvironmentVariable(EnvironmentConstants.EB_URL_HASH_SALT) ?? - Environment.GetEnvironmentVariable(EnvironmentConstants.EB_EMAIL_PASSWORD); + string secret = Environment.GetEnvironmentVariable(EnvironmentConstants.EB_URL_HASH_SALT); using (HMACSHA256 hmac = new HMACSHA256(Encoding.UTF8.GetBytes(secret))) { @@ -89,8 +88,7 @@ public static string GetOriginalUrl(string shortUrlId, RedisClient Redis) string base62Id = parts[0]; string providedHash = parts[1]; long id = Decode(base62Id); - string secret = Environment.GetEnvironmentVariable(EnvironmentConstants.EB_URL_HASH_SALT) ?? - Environment.GetEnvironmentVariable(EnvironmentConstants.EB_EMAIL_PASSWORD); + string secret = Environment.GetEnvironmentVariable(EnvironmentConstants.EB_URL_HASH_SALT); using (HMACSHA256 hmac = new HMACSHA256(Encoding.UTF8.GetBytes(secret))) { byte[] hash = hmac.ComputeHash(Encoding.UTF8.GetBytes(base62Id)); From bbc8a628bf07ddcbc34461969fd5dd27e10d03ed Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Tue, 10 Feb 2026 16:57:14 +0400 Subject: [PATCH 10/14] Unwanted property removed from control container json - IgnoreDataConsistencyCheck --- Helpers/ShortUrlHelper.cs | 2 +- Objects/EbControlContainer.cs | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/Helpers/ShortUrlHelper.cs b/Helpers/ShortUrlHelper.cs index 3ebcabac..92247eb3 100644 --- a/Helpers/ShortUrlHelper.cs +++ b/Helpers/ShortUrlHelper.cs @@ -111,7 +111,7 @@ public static void MarkShortUrlProcessed(long shortUrlId, RedisClient Redis) string originalUrl = Redis.Get(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, shortUrlId)); if (originalUrl != null) { - Redis.Set(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, shortUrlId), $"/StatusCode/703", new TimeSpan(1, 0, 0)); + Redis.Set(string.Format(RedisKeyPrefixConstants.EbShortUrlItem, shortUrlId), $"/StatusCode/703", new TimeSpan(12, 0, 0)); } } catch (Exception ex) diff --git a/Objects/EbControlContainer.cs b/Objects/EbControlContainer.cs index 9db153fe..cb17680f 100644 --- a/Objects/EbControlContainer.cs +++ b/Objects/EbControlContainer.cs @@ -85,6 +85,8 @@ public EbControlContainer() [JsonIgnore] public override bool IsNonDataInputControl { get; set; } + public override bool IgnoreDataConsistencyCheck { get; set; } + [EnableInBuilder(BuilderType.WebForm, BuilderType.UserControl)] [HideInPropertyGrid] public virtual bool IsSpecialContainer { get; set; } From 75bf4429fd9223c48a4edf5b69a23ad99c215ff3 Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Sat, 28 Feb 2026 05:18:30 +0400 Subject: [PATCH 11/14] Review ctrl- Hide Reviewed by primary role- using prop --- Objects/TableColumnMeta.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Objects/TableColumnMeta.cs b/Objects/TableColumnMeta.cs index 8ab666fb..3c7355c8 100644 --- a/Objects/TableColumnMeta.cs +++ b/Objects/TableColumnMeta.cs @@ -310,6 +310,8 @@ public class TableSchema public bool DoNotPersist { get; set; }//DoNotPersist datagrid + public bool HideReviewedByRole { get; set; }//For review table + public TableSchema() { Columns = new List(); From 7d41557dca8f5c33960b544e42fdaab92b0a7c68 Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Wed, 4 Mar 2026 13:51:20 +0400 Subject: [PATCH 12/14] EbControl DoNotExport - new prop added --- Objects/EbControl.cs | 8 ++++---- Objects/EbControlContainer.cs | 2 ++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/Objects/EbControl.cs b/Objects/EbControl.cs index 1fe75981..5cd483ff 100644 --- a/Objects/EbControl.cs +++ b/Objects/EbControl.cs @@ -304,10 +304,10 @@ public virtual string ContextId [HelpText("Set true if you dont want to clone value of this field.")] public virtual bool DoNotClone { get; set; } - //[PropertyGroup(PGConstants.DATA)] - //[EnableInBuilder(BuilderType.WebForm)] - //[HelpText("Set true if you dont want to export value of this field.")] - //public virtual bool DoNotExport { get; set; }// This property should be required in future + [PropertyGroup(PGConstants.DATA)] + [EnableInBuilder(BuilderType.WebForm)] + [HelpText("Set true if you dont want to export value of this field.")] + public virtual bool DoNotExport { get; set; } [PropertyGroup(PGConstants.DATA)] [EnableInBuilder(BuilderType.WebForm)] diff --git a/Objects/EbControlContainer.cs b/Objects/EbControlContainer.cs index cb17680f..7a3798b2 100644 --- a/Objects/EbControlContainer.cs +++ b/Objects/EbControlContainer.cs @@ -76,6 +76,8 @@ public EbControlContainer() public override bool DoNotImport { get; set; } + public override bool DoNotExport { get; set; } + public override bool DoNotClone { get; set; } public override bool ExternalColumn { get; set; } From bae434ba21412bb186dfd9da667de19fbeff5df9 Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Tue, 31 Mar 2026 22:12:21 +0400 Subject: [PATCH 13/14] ExecuteScalar - Type Casting using Convert.ChangeType --- Data/PostgreSQL/PGSQLDatabase.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Data/PostgreSQL/PGSQLDatabase.cs b/Data/PostgreSQL/PGSQLDatabase.cs index a2a9f6b2..dd6812c9 100644 --- a/Data/PostgreSQL/PGSQLDatabase.cs +++ b/Data/PostgreSQL/PGSQLDatabase.cs @@ -675,7 +675,7 @@ public override T ExecuteScalar(string query, params DbParameter[] parameters cmd.Parameters.AddRange(parameters); object o = cmd.ExecuteScalar(); if (o != null) - obj = (T)o; + obj = (T)Convert.ChangeType(o, typeof(T)); } } From 6ee7aab2ef6030340d0c8b512595246fc2a56d6c Mon Sep 17 00:00:00 2001 From: Febin Carlos Date: Tue, 31 Mar 2026 23:59:12 +0400 Subject: [PATCH 14/14] SimpleSelect ctrl - justSetValue fn updated --- Helpers/HtmlConstants.cs | 26 ++++++++++---------------- 1 file changed, 10 insertions(+), 16 deletions(-) diff --git a/Helpers/HtmlConstants.cs b/Helpers/HtmlConstants.cs index 46b4a544..a0914da7 100644 --- a/Helpers/HtmlConstants.cs +++ b/Helpers/HtmlConstants.cs @@ -151,23 +151,17 @@ public static class JSFnsConstants public const string EbSimpleSelect_JustSetValueJSfn = @" { - if(p1 === null) - p1 = -1; - isContained = false; -if(this.MultiSelect){ - if(p1 === -1) - p1 = p1.toString(); - p1 = p1.split(','); -} - $('#' + this.EbSid_CtxId + ' option').each(function (i, opt) { - if ($(opt).attr('value') == p1 || (this.MultiSelect && p1.contains($(opt).attr('value')))) { - isContained = true; - return false; + if (!p1 || p1==-1) { + $('#' + this.EbSid_CtxId).val('').selectpicker('refresh'); + } + else { + if (this.MultiSelect) { + $('#' + this.EbSid_CtxId).val((p1+'').split(',')).selectpicker('refresh'); } - }.bind(this)); - if(!isContained) - return; - $('#' + this.EbSid_CtxId).selectpicker('val', p1) + else { + $('#' + this.EbSid_CtxId).val(p1).selectpicker('refresh'); + } + } }"; public const string CB_JustSetValueJSfn = @"$('#' + this.EbSid_CtxId).prop('checked', p1 === true);";