跳至內容
選單
此問題已被標幟
1 回覆
3487 瀏覽次數

My Xml:

<div class="TextAlignSt">

 <span onclick="register_popup(user_data.name,'1');" id="login_name">

  <t t-esc="user_data.name"></t>

 </span>

 <i>

  <t t-foreach="group_data" t-as="i">

  <t t-if="i=='Lab Manager'">

   <t t-esc="i"></t>

  </t>

  <t t-if="i=='Client'">

   <t t-esc="i"></t>

  </t>

  <t t-if="i=='Lab Clerk'">

   <t t-esc="i"></t>

  </t>

  </t>

 </i>

</div>


How to pass username from above function

Thanks in advance..

頭像
捨棄
最佳答案

Hi,

I dont clearly understand this question, you asked how to get user access rights in your heading and in explanation you are asking how to pass user name

to get user name you can try this

<span t-esc="user.name"/>

And to get user groups

<span t-esc="user.groups_id"/>


頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
0
4月 24
1264
1
12月 22
44874
0
4月 21
3216
2
9月 17
5534
0
3月 15
5585