Update Convert record

 $currentmodule=$options['module'];
 if($currentmodule=="prospects"){
          ['id' => $targetId] = $options;
        

        $Target = \BeanFactory::getBean('Prospects', $targetId);
        $Target->status_c='converted';
        $Target->save();
       
}

i tried adding this code to ConvertRecordAction.php file but i keep recieving this errror
[FATAL] Bean file does not exist in path: modules/Prospects/Prospect.php

Use Prospect, not Prospects in getBean()

[WARN] Cannot find bean file for module: Prospect
i got this warning

do i need this->init() and this->close() ?

can i edit convert target view as i edit convert lead from view.convertlead.php

Hey @hserour

The error means SuiteCRM can’t find the bean file for Prospects. Make sure there’s a Prospect.php inside modules/Prospects, and that it’s properly set up in the module’s vardefs and modules.php.

Also, yes — using $this->init() and $this->close() is a good idea if you’re inside the controller flow.

About converting Targets like Leads — it’s not built-in like Lead conversion. You’ll need to custom-create a similar view and logic for Targets if you want that same experience.