从控制器MVC打开弹出条件并检索答案

时间:2017-04-20 06:00:16

标签: asp.net-mvc controller modal-dialog

我想从我的控制器打开一个包含数据并向用户提出问题的poup-up。根据他的回答,我继续或停止治疗。

Function Traitement(model As TraitementViewModel, confirm_value As String) As ActionResult
    Try
        If (ModelState.IsValid) Then
            Dim exception As Exception = Nothing
            Dim mois As Integer = Mid(model.dateTraitement, 4, 2)
            Dim annee As Integer = Right(model.dateTraitement, 4)
            Session("mois") = mois
            Session("annee") = annee
            Dim extract As Extraction = New Extraction()

            Dim result As Integer = extract.Recherche(mois, annee).Rows.Count()
            If (result <> 0) Then
                OPEN POPUP

                   Artciles    Montant
                        1       100
                        2       200

                   Do you want continue

                         YES  NO



                  IF(confirm_value = "yes") Then
                   continue...
                  Else
                   Exit Function
            Else
                continue...
            End If


        End If

End Function

0 个答案:

没有答案