Fix backend↔database mismatches found verifying against Fuchs_Database
Verified every [dbo].[...] object the backend calls against the SSDT project. Two real mismatches fixed (both would fail at runtime): - Banking search (bam/btl mode=s) called a non-existent [dbo].[fds__getBankingtransactions_list2] and dropped @tgtdate. The actual proc (and the legacy call) is [dbo].[fds__getBankingtransfers_list2] (@tgtdate,@mode,@search,@authuser) — corrected name + parameters. - Widget generic branch called a phantom [dbo].[fds__getWidget] that never existed (legacy only had my/one; the dashboard only requests wdg/my, wdg/one). The default branch now returns 404 instead of hitting a missing proc. (The 'fuchs__admin_logdebug' reference is only in a commented-out line.) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -81,11 +81,13 @@ public partial class IntranetController
|
||||
string mode = Form("mode").ToLower();
|
||||
if (mode == "s" && Form("tgt").Contains(':'))
|
||||
{
|
||||
// Search mode: @tgtdate is unused by the proc but required by its signature.
|
||||
var pl = StdParamlist(
|
||||
SQL_VarChar("@mode", Form("mode")),
|
||||
SQL_VarChar("@search", Form("tgt")));
|
||||
SQL_Date("@tgtdate", DBNull.Value),
|
||||
SQL_VarChar("@mode", Form("mode").ne("m")),
|
||||
SQL_VarChar("@search", Form("tgt")));
|
||||
var dset = await getSQLDataSet_async(
|
||||
"EXECUTE [dbo].[fds__getBankingtransactions_list2] @mode, @search, @authuser;",
|
||||
"EXECUTE [dbo].[fds__getBankingtransfers_list2] @tgtdate, @mode, @search, @authuser;",
|
||||
_intranet.Intranet__SQLConnectionString, pl,
|
||||
tablenames: new[] { "admin", "bank" },
|
||||
Security: DbSec, options: SqlOpt(fn, id, code));
|
||||
|
||||
Reference in New Issue
Block a user