所以昨天这个代码运行得很好,今天我们去运行网站时遇到了这个配置错误.我已经查看了所提出的其他问题,虽然它们很有用,但我无法确定我在重复某个部分的位置.
这是我的错误:http:
//img.photobucket.com/albums/v506/Himaro/Programming/ConfigurationError.jpg
和我的web.config中的代码:
<configuration>
<configSections>
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
<section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
</configSections>
<appSettings>
<add key="webpages:Version" value="2.0.0.0" />
<add key="webpages:Enabled" value="false" />
<add key="PreserveLoginUrl" value="true" />
<add key="ClientValidationEnabled" value="true" />
<add key="UnobtrusiveJavaScriptEnabled" value="true" />
</appSettings>
<connectionStrings>
<add name="DashboardSiteConnectionString" connectionString="Data Source=ZGAWS152;Initial Catalog=DashboardSite;Integrated Security=True" providerName="System.Data.SqlClient" />
<add name="CHASE_NJBConnectionString" connectionString="Data Source=ZGAWS152;Initial Catalog=CHASE-NJB;Integrated Security=True" providerName="System.Data.SqlClient" />
<add name="DefaultConnection" providerName="System.Data.SqlClient" connectionString="Data Source=(LocalDb)\v11.0;Initial Catalog=aspnet-4SDashboard.DashboardSite-20131227074234;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|\aspnet-4SDashboard.DashboardSite-20131227074234.mdf" />
</connectionStrings>
<system.web>
<compilation debug="true" …Run Code Online (Sandbox Code Playgroud) 我需要调用此存储过程,但是当我将其放入 .dbml 时,它会被转换为 ISingleResult 的结果。我不确定如何使用所有参数正确调用它。这是我当前的代码,但是当我“返回结果”时出现错误,提示“无效的表达式术语“返回””任何帮助将不胜感激。谢谢。
public static int CreateNewTransferee(CreateTransferee model)
{
using (var db = new NJB.NJBDataContext())
{
var result = db.SP_AddTransferee(
model.TransferEffectiveDate,
model.TransfereeName,
model.TransfereeNoticeAddressLine1,
model.TransfereeNoticeAddressLine2,
model.TransfereeNoticeCity,
model.TransfereeNoticeState,
model.TransfereeNoticeZip,
model.TransfereeNoticePhone,
model.TransfereePaymentAddressLine1,
model.TransfereePaymentAddressLine2,
model.TransfereePaymentCity,
model.TransfereePaymentState,
model.TransfereePaymentZip,
model.TransfereePaymentPhone,
return (int) result.ReturnValue;
}
}
Run Code Online (Sandbox Code Playgroud)
更新:这是SP:
ALTER PROCEDURE [dbo].[SP_AddTransferee]
-- Add the parameters for the stored procedure here
@TransferEffectiveDate datetime,
@TransfereeName varchar(50),
@TransfereeNoticeAddressLine1 varchar(50),
@TransfereeNoticeAddressLine2 varchar(50),
@TransfereeNoticeCity varchar(50),
@TransfereeNoticeState varchar(2),
@TransfereeNoticeZip varchar(12),
@TransfereeNoticePhone varchar(50),
@TransfereePaymentAddressLine1 varchar(50),
@TransfereePaymentAddressLine2 varchar(50),
@TransfereePaymentCity varchar(50),
@TransfereePaymentState varchar(50),
@TransfereePaymentZip varchar(50), …Run Code Online (Sandbox Code Playgroud) 我目前正在开发一个应用程序,用户在其中获取一组列表,其中包含详细信息,每个div中还有隐藏的详细信息,可由用户切换.问题是,当您单击一个框的"详细信息"时,它会切换所有框上的类,而不是仅在单击的框中切换.我一直在寻找这个问题的答案,并试图自动增加ID/Class,以便创建的每个框都有一个唯一的标识符.我需要这样做才能使"额外细节"仅在卡片"细节"被点击时打开.预先感谢您的任何帮助.
我的守则
$(".card-details").on("click", function (e) {
e.preventDefault();
$(".extra-details").toggleClass("hidden");
});Run Code Online (Sandbox Code Playgroud)
h4 {
padding:10px 0 0 5px;
font-size:18px;
font-weight:bold;
}
.card {
border:none;
box-shadow:2px 2px 5px rgba(201,201,201, .5);
padding:5px;
margin:5px;
max-width:350px;
background:transparent;
border:1px solid #efefef;
font-size:12px;
}
hr {
border:1px solid #efefef;
width:100%;
margin-top:0;
}
.card-head {
color:#005ABB;
}
.card-container{
margin-top:20px;
margin-left:5px;
}
.card-info {
margin-left:20px;
background:transparent !important;
}
.card-details {
color:#005ABB;
margin-left:85%;
}
.card-details:hover {
text-decoration:underline;
color:#F9A51B;
cursor:pointer;
}
.hidden{
display:none !important;
}Run Code Online (Sandbox Code Playgroud)
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-alpha.6/css/bootstrap.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> …Run Code Online (Sandbox Code Playgroud)