プラグインMyExtPlugin
があり、レコードMyExtPlugin_Record_A
があり、このレコードにフィールドがあると仮定しますstatus
。
の DB フィールドMyExtPlugin_Record_A
はuid,name,status
.
TCA フォームのステータス:
'status'=>array(
'type' => 'user'
'userFunc' => 'EXT:userClass.specialFunction'
)
私の specialFunction は次のようにする必要があります。
current_uid_of_record= #get current uid of the record;
current_status= #get status for current_uid_of_record
if (current_status==0)
return 'Pending';
return 'Approved';
質問:追加または編集中のレコードの現在の Uid を取得するにはどうすればよいですか?