gpt4 book ai didi

reporting-services - angularjs nginclude 到 ReportServer url

转载 作者:行者123 更新时间:2023-12-04 08:00:25 28 4
gpt4 key购买 nike

我是开发使用 AngularJS 和 SSRS 报告的自定义 SharePoint 应用程序的团队的一员。基本上,该应用程序允许用户选择一个报告,选择一组参数,然后在站点/应用程序中查看报告。

在我们打开报表工具栏之前一切正常。那时,报表停止呈现。只有工具栏可见。

这是我们正在做的:

显示报告的应用程序部分的 html:

<section class="left-panel report-view-panel ssrsReport show">
<h1>{{CurrentReport.Title}}</h1>
<button class="btn-report-close" ng-click="closeReport()" type="button">Close</button>
<div class="scroll-list">
<figure class="report">
<div class="sample-report">
<div ng-include='CurrentReportURL'></div>
</div>
</figure>
</div>
</section>

在 Controller javascript 中,我们将报告服务器 url (CurrentReportURL) 构建为如下内容:

http://ourreportserver.com/_vti_bin/ReportServer?http://ourreportserver.com/Our%20Reports/Report1.rdl&rs:Command=Render&rc:Toolbar=false&rc:Parameters=false&Param1=41001&Param2=08&Param3=0

我们告诉它呈现报告,隐藏工具栏并隐藏参数选择。这很好用。报告按预期呈现。

但是,将 url 更改为:

http://ourreportserver.com/_vti_bin/ReportServer?http://ourreportserver.com/Our%20Reports/Report1.rdl&rs:Command=Render&rc:Toolbar=true&rc:Parameters=false&Param1=41001&Param2=08&Param3=0

仅导致工具栏呈现。没有报告。如果我复制相同的 url 并在浏览器窗口中打开它,报告将按预期呈现。

我更深入地挖掘并使用 Chrome 和 Chrome 的开发者工具网络选项卡查看了这两种情况。在 ng-include 中的 url 和浏览器窗口中的 url 之间进行的调用存在一些差异。然而,最引人注目的是一个 POST 到 RSViewerPage.aspx,其中所有报表查看器和报表参数都转换为适当的 ReportViewer 参数。 (我会发布那个实际链接,但 SO 告诉我我需要 10 的声誉才能做到这一点)。

我在 Chrome 和 IE10 中得到了相同的结果。

我正在寻找一些关于为什么 ng-include 版本没有进行 POST 的指导?我相信此 POST 与仅在工具栏打开时跟踪的 SSRS session 有关,但我真的不确定。

任何指导将不胜感激!

最佳答案

我正准备开始将 SSRS 集成到 angularjs 应用程序中,我正在考虑使用 iframe 并将 iframe 的 src 属性更改为所选报告的 url。

我什至没有考虑尝试使用 ng-include,认为 ssrs 返回的 html 将被设计为与 asp.net postback/viewstate 模型一起工作。通过使用 iframe,此回发/ View 状态模型将被隔离在页面上的“孤岛”中,并且不会影响父容器。

基督徒

关于reporting-services - angularjs nginclude 到 ReportServer url,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18213714/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com