简体   繁体   English

在剃须刀中获取标签的价值

[英]Getting the value of tag in razor

I need help : i need to know the value of for example reception0 : 我需要帮助:我需要知道例如reception0的值:

  <td >
    <label name="tag@(i)">@Model[1][i]._tag</label>
  </td>
  <td>
    <input type="text" value="@Model[1][i]._client" name="client@(i)"/>
  </td>
  <td>
    <input type="text" value="@Model[1][i]._reception"  class="datepicker" name="reception@(i)"/>
  </td>
  <td>
    <input type="text" value="@Model[1][i]._cloture"  class="datepicker" name="cloture@(i)"/>
  </td>
  <td>
    @Html.ActionLink("enregistrer","Index", new {identificateur = Model[1][i].Id, Pages = "1", _reception ="reception"+""+i.ToString(), _cloture ="cloture"+""+i.ToString(), _client ="client"+""+i.ToString(), tag = "tag"+""+i.ToString()  })
  </td>  

My problem is that i get _reception = reception0 but i need the value of reception0 not its name. 我的问题是,我得到_reception = reception0 ,但我需要的价值reception0不是它的名称。

How can i fix my snippet? 如何修复我的代码段?

使用您在链接帮助器中用于输入的值

@Html.ActionLink( ... , _reception = Model[1][i]._reception, ... )

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM