Esempio n. 1
0
 /**
  * @param int $metadataId
  * @param string $url
  *
  * @return BatchJob
  */
 public static function addImportMetadataJob($partnerId, $metadataId, $url)
 {
     $job = new BatchJob();
     $job->setPartnerId($partnerId);
     $job->setObjectType(kPluginableEnumsManager::apiToCore('BatchJobObjectType', MetadataBatchJobObjectType::METADATA));
     $job->setObjectId($metadataId);
     $data = new kImportMetadataJobData();
     $data->setMetadataId($metadataId);
     $data->setSrcFileUrl($url);
     return kJobsManager::addJob($job, $data, BatchJobType::METADATA_IMPORT);
 }
Esempio n. 2
0
 /**
  * @param int $metadataId
  * @param string $url
  * 
  * @return BatchJob
  */
 public static function addImportMetadataJob($partnerId, $metadataId, $url)
 {
     $job = new BatchJob();
     $job->setPartnerId($partnerId);
     $data = new kImportMetadataJobData();
     $data->setMetadataId($metadataId);
     $data->setSrcFileUrl($url);
     return kJobsManager::addJob($job, $data, BatchJobType::METADATA_IMPORT);
 }