SugarCRM 自定义字段在DetailView.php显示问题

原因:自动生成仅将DetailView.html模板页写好,可DetailView.php页并没有为自定义字段赋值.
解决方案:
      modules\bw_Msg_MT3101s\DetailView.php

      $xtpl->assign('DESCRIPTION',            nl2br(url2html($focus->description)));
      在此代码后写入下面的代码,用于给自定义字段赋值
      $xtpl->assign('MESSAGE_ID',                   $focus->message_id);
      $xtpl->assign('SENDER_ID',                   $focus->sender_id);
      $xtpl->assign('MESSAGE_TYPE',                   $focus->message_type);
      $xtpl->assign('RECEIVER_ID',                   $focus->receiver_id);
      $xtpl->assign('VERSION',                   $focus->version);

    //BUILDER: included fields

posted @ 2011-02-13 17:43  海乐学习  阅读(387)  评论(0编辑  收藏  举报