Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/257.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/86.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 在表上调用datatable时遇到datatable单元格索引错误_C#_Jquery_.net - Fatal编程技术网

C# 在表上调用datatable时遇到datatable单元格索引错误

C# 在表上调用datatable时遇到datatable单元格索引错误,c#,jquery,.net,C#,Jquery,.net,调用下表中的datatable方法时,我遇到datatable单元格索引错误。我找不到我的代码有什么问题,有人能帮我吗 <div class="table-responsive top-space reportActionTable mt-0" id="reportTable"> <table class="table" id="repo

调用下表中的datatable方法时,我遇到datatable单元格索引错误。我找不到我的代码有什么问题,有人能帮我吗

<div class="table-responsive top-space reportActionTable mt-0" id="reportTable">
                                    <table class="table" id="reportTable1">
                                        <thead>
                                            <tr>
                                                <th>View Detail</th>
                                                <th>Professional</th>
                                                <th>Patient</th>
                                                <th>Date & time</th>
                                                <th>Checked In</th>
                                                <th>Checked Out</th>
                                                <th>Status</th>
                                                <th>Slot Type</th>
                                            </tr>
                                        </thead>
                                        <tbody>
                                            @if (Model != null && Model.appointmentModels.Count > 0)
                                            {
                                                foreach (var item in Model.appointmentModels)
                                                {
                                                    <tr>
                                                        @if (item.StatusText == EPS.BAL.Model.AppointmentStatus.Confirmed)
                                                        {
                                                            <td><i class="fa fa-plus-circle fa-2x tableToggleBtn"></i></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.Unconfirmed)
                                                        {
                                                            <td><i class="fa fa-plus-circle fa-2x tableToggleBtn"></i></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.PracticeRescheduled)
                                                        {
                                                            <td><i class="fa fa-plus-circle fa-2x tableToggleBtn"></i></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.PracticeCancelled)
                                                        {
                                                            <td><i class="fa fa-plus-circle fa-2x tableToggleBtn"></i></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.PatientNoshows)
                                                        {
                                                            <td><i class="fa fa-plus-circle fa-2x tableToggleBtn"></i></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.PatientCancellations)
                                                        {
                                                            <td><i class="fa fa-plus-circle fa-2x tableToggleBtn"></i></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.Unconfirmed)
                                                        {
                                                            <td><i class="fa fa-plus-circle fa-2x tableToggleBtn"></i></td>
                                                        }
                                                        else
                                                        {
                                                            <td><i class="fa fa-plus-circle fa-2x tableToggleBtn"></i></td>
                                                        }
                                                        <td>@item.DoctorName</td>
                                                        <td>
                                                            <b>
                                                                Name :
                                                            </b>
                                                            <span></span>@item.PatientName

                                                            @if (!string.IsNullOrEmpty(item.Mobile))
                                                            {

                                                                <b>Phone :</b> <a href="tel:@item.Mobile"><span></span>@item.Mobile</a>

                                                            }
                                                        </td>
                                                        @if (item.Date != null && item.Time != null)
                                                        {

                                                            <td>@string.Format("{0:MMMM dd yyyy}", item.Date) - @item.AppointmentTime</td>
                                                        }
                                                        else
                                                        {
                                                            <td> No Date time chosen</td>
                                                        }
                                                        <td>
                                                            @item.strCheckIn
                                                            @if (item.CkeckIn == true && item.CheckOut != true)
                                                            {
                                                                if (item.ReportStatusText == null)
                                                                {
                                                                    @:&nbsp;&nbsp;&nbsp; <a href="@Url.Action("UndoCheckedin", "Diagnostic", new { key = @item.ID, ParentPatientID = @item.ParentPatientID })">Undo</a>
                                                                }
                                                            }
                                                            @if (item.CheckInTime != null && item.CkeckIn == true)
                                                            {

                                                                @:(@string.Format("{0:MMMM dd yyyy hh:mm tt}", item.CheckInTime))
                                                            }
                                                        </td>
                                                        <td>
                                                            @item.strCheckOut
                                                            @if (item.CheckOutTime != null)
                                                            {

                                                                @:(@string.Format("{0:MMMM dd yyyy hh:mm tt}", item.CheckOutTime))
                                                            }
                                                        </td>
                                                        @if (item.StatusText == EPS.BAL.Model.AppointmentStatus.Confirmed)
                                                        {
                                                            <td><div class="icon iconConfirmedAppointments"></div></td>
                                                        }

                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.Unconfirmed)
                                                        {
                                                            <td><i class="fa fa-clock-o fa-2x"></i></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.PracticeRescheduled)
                                                        {
                                                            <td><div class="icon iconPracticeRescheduled"></div></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.PracticeCancelled)
                                                        {
                                                            <td><i class="fa fa-minus-circle text-danger fa-2x"></i></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.PatientNoshows)
                                                        {
                                                            <td><div class="icon iconPatientNoShows"></div></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.PatientCancellations)
                                                        {
                                                            <td><div class="icon iconPatientCancellations iconLeft"></div></td>
                                                        }
                                                        else if (item.StatusText == EPS.BAL.Model.AppointmentStatus.Unconfirmed)
                                                        {
                                                            <td><i class="fa fa-ban text-danger fa-2x"></i></td>
                                                        }
                                                        else
                                                        {
                                                            <td></td>
                                                        }
                                                        @if (item.WithoutSlot == true)
                                                        {
                                                            <td><div class="icon iconPatientWithoutSlot"></div></td>
                                                        }
                                                        else if (item.WithoutSlot == false)
                                                        {
                                                            <td><div class="icon iconPatientWithSlot"></div></td>
                                                        }
                                                    </tr>
                                                    <tr>
                                                        <td colspan="9" class="p-0">
                                                            @* code *@
                                                            <div class="tableToggleUl">
                                                                <div class="row d-flex m-0 customlist">
                                                                    <div class="col-md-4 customlistCol">
                                                                        <label>Visit Status</label>
                                                                        @if (!string.IsNullOrEmpty(item.ReportStatusText))
                                                                        {
                                                                            <span>@item.ReportStatusText</span>

                                                                        }
                                                                        else
                                                                        {

                                                                            <span></span>
                                                                        }
                                                                    </div>
                                                                    <div class="col-md-4 customlistCol">
                                                                        <label>Record Uploaded</label>
                                                                        @if (item.RerecordUploadedYN == true)
                                                                        {
                                                                            <span>Yes</span>
                                                                        }
                                                                        else
                                                                        {
                                                                            <span>No</span>
                                                                        }
                                                                    </div>
                                                                    <div class="col-md-4 customlistCol">
                                                                        <label>Order Received</label>
                                                                        @if (item.OrderReceivedYN == true)
                                                                        {
                                                                            <span>Yes</span>
                                                                        }
                                                                        else
                                                                        {
                                                                            <span>No</span>
                                                                        }
                                                                    </div>
                                                                </div>
                                                                <div class="row d-flex m-0 customlist">
                                                                    <div class="col-md-4 customlistCol">
                                                                        <label>Authorization</label>
                                                                        @if (item.AuthorizationYN == true)
                                                                        {
                                                                            <span>Yes</span>
                                                                        }
                                                                        else
                                                                        {
                                                                            <span>No</span>
                                                                        }
                                                                    </div>
                                                                    <div class="col-md-4 customlistCol">
                                                                        <label>Care Plan Uploaded</label>
                                                                        @if (item.IsCarePlanuploaded == true)
                                                                        {
                                                                            <span>Yes</span>
                                                                        }
                                                                        else
                                                                        {
                                                                            <span>No</span>
                                                                        }
                                                                    </div>
                                                                    <div class="col-md-4 customlistCol">
                                                                        <label style="white-space:nowrap;">Guardian Name</label>
                                                                        @if (item.ParentPatientID != null)
                                                                        {
                                                                            <span>@item.GuardianName </span>

                                                                        }
                                                                        else
                                                                        {
                                                                            <span></span>}
                                                                    </div>
                                                                </div>
                                                                <div class="row d-flex m-0 customlist">
                                                                    <div class="col-md-4 customlistCol">
                                                                        <label>Referred By</label>
                                                                        @if (item.ReferralProviderTypeID == Convert.ToInt32(Session["UserType"]) && item.ReferralProviderID == Convert.ToInt32(Session["DoctorID"]))
                                                                        {
                                                                            <span>Own Appointment</span>
                                                                        }
                                                                        else if (item.ReferralProviderTypeText != null)
                                                                        {
                                                                            <span>@item.ReferralProviderName (@item.ReferralProviderTypeText)</span>

                                                                        }
                                                                        else
                                                                        {
                                                                            <span>@item.ReferralProviderName</span>
                                                                        }
                                                                    </div>
                                                                    <div class="col-md-4 customlistCol">
                                                                        <label>Created By</label>
                                                                        <span>@item.CreatedByInitials</span>
                                                                    </div>
                                                                    <div class="col-md-4 customlistCol">
                                                                        <label>Insurance</label>
                                                                        @if (item.InsuranceText != null)
                                                                        {

                                                                            <span>@item.InsuranceText</span>
                                                                        }
                                                                        else
                                                                        {
                                                                            <span></span>
                                                                        }
                                                                    </div>
                                                                </div>
                                                                <div class="row d-flex m-0 customlist">
                                                                    <div class="col-md-6 customlistCol">
                                                                        <label>Visit Reason</label>
                                                                        @if (!string.IsNullOrEmpty(item.Reason))
                                                                        {
                                                                            if (!string.IsNullOrEmpty(item.ReasonOfVisitOthers))
                                                                            {
                                                                                <span>@item.Reason , @item.ReasonOfVisitOthers</span>
                                                                            }
                                                                            else
                                                                            {
                                                                                <span>@item.Reason</span>
                                                                            }
                                                                        }
                                                                        else
                                                                        {
                                                                            <span>@item.ReasonOfVisitOthers</span>
                                                                        }
                                                                    </div>
                                                                    <div class="col-md-6 customlistCol">
                                                                        <label>How Did Hear</label>
                                                                        <span>@item.AppointmentSourceText</span>
                                                                    </div>
                                                                </div>
                                                                <div class="row d-flex m-0 customlist">
                                                                    <div class="col-md-6 customlistCol">
                                                                        <label>Location</label>
                                                                        <span>@item.LocationText</span>
                                                                    </div>
                                                                    <div class="col-md-6 customlistCol">
                                                                        <label>Special Instructions</label>
                                                                        <span>@item.SpecialInstructions</span>
                                                                    </div>

                                                                </div>
                                                            </div>
                                                            @* code end *@
                                                        </td>
                                                    </tr>
                                                }
                                            }
                                        </tbody>
                                    </table>
                                </div>

查看详细信息
专业的
病人
日期和时间
登记入住
退房
地位
槽型
@if(Model!=null&&Model.appointmentModels.Count>0)
{
foreach(模型中的var项。任命模型)
{
@if(item.StatusText==EPS.BAL.Model.AppointmentStatus.confirm)
{
}
else if(item.StatusText==EPS.BAL.Model.AppointmentStatus.unconfirm)
{
}
else if(item.StatusText==EPS.BAL.Model.AppointmentStatus.PracticeRespeduled)
{
}
else if(item.StatusText==EPS.BAL.Model.AppointmentStatus.PracticeCancelled)
{
}
else if(item.StatusText==EPS.BAL.Model.AppointmentStatus.PatientNoshows)
{
}
else if(item.StatusText==EPS.BAL.Model.AppointStatus.PatientCancellations)
{
}
else if(item.StatusText==EPS.BAL.Model.AppointmentStatus.unconfirm)
{
}
其他的
{
}
@item.DoctorName
姓名:
@item.PatientName
@如果(!string.IsNullOrEmpty(item.Mobile))
{
电话:
}
@if(item.Date!=null&&item.Time!=null)
{
@string.Format(“{0:MMMM-dd-yyyy}”,item.Date)->@item.AppointmentTime
}
其他的
{
没有选择日期和时间
}
@item.strCheckIn
@if(item.CkeckIn==true&&item.CheckOut!=true)
{
如果(item.ReportStatusText==null)
{
@:    
}
}
@if(item.CheckInTime!=null&&item.CkeckIn==true)
{
@:(@string.Forma)