helper function added
This commit is contained in:
@@ -95,6 +95,8 @@ class ProcessStructureJob implements ShouldQueue
|
||||
*/
|
||||
public function handle()
|
||||
{
|
||||
$sHelper = new StructureHelper;
|
||||
|
||||
//Get the page of structures
|
||||
$structures = $this->GetListOfStructures();
|
||||
|
||||
@@ -113,9 +115,9 @@ class ProcessStructureJob implements ShouldQueue
|
||||
//Find if the structure exists
|
||||
$found = Structure::where(['structure_id' => $structure->structure_id])->get();
|
||||
if(!$found) {
|
||||
$this->StoreNewStructure($structure, $info, $solarName);
|
||||
$sHelper->StoreNewStructure($structure, $info, $solarName);
|
||||
} else {
|
||||
$this->UpdateExistingStructure($structure, $info, $solarName);
|
||||
$sHelper->UpdateExistingStructure($structure, $info, $solarName);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
* GNU Public License
|
||||
*/
|
||||
|
||||
namespace App\Library\Structures\Helper;
|
||||
namespace App\Library\Structures;
|
||||
|
||||
//Internal Library
|
||||
use Log;
|
||||
@@ -17,7 +17,6 @@ use App\Models\Structure\Structure;
|
||||
use App\Models\Structure\Service;
|
||||
|
||||
|
||||
|
||||
class StructureStockHelper {
|
||||
|
||||
public function StoreNewStructure($structure, $info, $solarName) {
|
||||
|
||||
Reference in New Issue
Block a user