smarty: <td>{$info.receive_group|modifier:identity_cate}</td>
php: gloabel.lib.php
/**
* 获取用户身份
* @param str $operate
* @return string
*/
function identity_cate($identity){
$identitys = array('all'=>'所有会员','institutions'=>'采购商','supplier'=>'供应商','distributor'=>'分销商','other'=>'其他');
$cats = "";
$categorys = explode(',', $identity);
foreach($categorys as $val){
if($val){
$cats .= $identitys[$val].",";
}
}
return $cats;
}