[TYPO3-english] Re: Re: Re: Re: Re: Re: Re: Re: Re: Re: Re: Re: Re: [TYPO3-engl

Miguel xadi10 at hotmail.com
Wed Nov 20 19:53:25 CET 2013


Well still no luck Bernd.

Both timed usergroups are still appearing in the frontend, the expired timed usergroup and the current timed usergroup.

Maybe you should check my code, i'm so sorry to bother you.

Here it is: 
10 = CONTENT
10.table = fe_groups
10.select.pidInList = 26
10.select.andWhere.data = TSFE:fe_user|user|usergroup
10.select.andWhere.wrap = uid=|
10.renderObj = TEXT
10.renderObj.field = title
10.renderObj.wrap = Status: |
10.stdWrap.if.isFalse.data = TSFE:fe_user|user|tx_itypoexpiringfegroups_groups
|
20 = TEXT
20.data = TSFE:fe_user|user|tx_itypoexpiringfegroups_groups
20.stdWrap.split {

token = |

cObjNum = 1 |*| 2 |*| 3
1 {
10 = CONTENT
10.table = fe_groups
10.select.pidInList = 26
10.select.andWhere.current = 1
10.select.andWhere.wrap = uid=|
10.renderObj = TEXT
10.renderObj.field = title
10.renderObj.wrap = Status:|
10.stdWrap.if.isGreaterThan.cObject = TEXT
10.stdWrap.if.isGreaterThan.cObject.data = date:U
10.stdWrap.if.data = register:usergroup_endtime
}

  
}
|

30 = TEXT
30.data = TSFE:fe_user|user|tx_itypoexpiringfegroups_groups
30.split {

token = *
cObjNum = 1 || 2   

  2 {
    10 = TEXT
    10.current = 1
    10.split {
      token = |
      cObjNum = 1 |*| 2 |*| 3 
  
1 {
10 = CONTENT
10.table = fe_groups
10.select.pidInList = 26
10.select.andWhere.current = 1
10.select.andWhere.wrap = uid=|
10.renderObj = TEXT
10.renderObj.field = title
10.renderObj.wrap = Status: |
}
2.current = 1
# format as date
2.strftime = %b-%d-%Y, %H:%M
2.noTrimWrap = Account Expiration:|
2.required = 1
  
    }  
}
  }

First, the "10" lines show the "normal" usergroup if no timed usergroup exists. 
If exists timed usergroups, "20" lines show the first timed usergroup.
Finally, because i do not want users "return" to the normal usergroup before the membership, will always exist a second timed usergroup that puts users in a usergroup called "expired" , so the "30" lines show the second usergroup. The problem is that the "20" lines should only be visible while the first membership is on, after that, when the first timed usergroup is expired, it should only be shown the "30" lines.



More information about the TYPO3-english mailing list