private function save_custom_fields($level_id, $data) { $custom_obj = BMembershipLevelCustom::get_instance_by_id($level_id); foreach ($data as $item) { $custom_obj->set($item); } }
public static function get_value_by_context($level_id, $context) { return BMembershipLevelCustom::get_instance_by_id($level_id)->get_by_context($context); }