Castle 单轨列车数据绑定实际操作
我们遇到一个问题,我们的网站(运行 Castle Monorail)上有一个下载链接,可以将一些数据下载为 CSV。 Action 方法如下:
public void TransactionReportSearch([DataBind("searchParameters", Validate = true)]TransactionSearchParameters searchParameters, int page,
bool showStatistics)
奇怪的是,数据绑定在我们的测试环境中有效,但在我们的实际环境中不起作用。我们发现 DataBindAttribute 在执行 HTTP POST 时可以工作,但在 HTTP GET 上似乎不起作用。这当然可能是一个转移注意力的事情,因为它正在测试环境中运行。
我怀疑这可能是配置问题。我应该在测试环境和实际环境之间检查什么,以确保操作中的 Castle Monorail 数据绑定配置正确?
We have an issue whereby we have a download link on our website (running Castle Monorail) that downloads some data as a CSV. The Action method is as follows:
public void TransactionReportSearch([DataBind("searchParameters", Validate = true)]TransactionSearchParameters searchParameters, int page,
bool showStatistics)
Strangely enough, the databinding is working on our test environment but does not work on our live environment. We have discovered that the DataBindAttribute is working when we are doing a HTTP POST but it doesn't seem to be working on a HTTP GET. This of course could be a red herring as it is working on the test environment.
I suspect this could be a configuration issue. What should I check between the test and live environment to ensure that Castle Monorail databinding in the Action is configured correctly?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我没有测试,但你可以尝试 Databind 的 From=ParamStore.Params 选项吗?它说“来自查询字符串、表单和环境变量。”。
I didn't test but can you try Databind's From=ParamStore.Params option. It says "From QueryString, Form and Environment variables.".