| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081 |
- <?php
- namespace App\Http\Controllers;
- use App\Http\Controllers\ResponseController;
- use App\Http\Controllers\EncryptionController;
- use App\Http\Controllers\ResourcesController;
- use Illuminate\Http\Request;
- use Illuminate\Support\Carbon;
- use Illuminate\Support\Facades\DB;
- use Illuminate\Support\Facades\Validator;
- class DelayAnalysisController extends Controller
- {
- private $responseController;
- private $encController;
- private $resourcesController;
- public function __construct(){
- $this->responseController = new ResponseController();
- $this->encController = new EncryptionController();
- $this->resourcesController = new ResourcesController();
- }
- public function registerDelayAnalysis() {
- }
- public function getDelayAnalysis($line) {
- try {
- $getDelayAnalysis = DB::table('S002V01TANRE')
- ->where('ANRE_NULI', '=', $line)
- ->join('S002V01TORCO', 'ORCO_NUOR', '=', 'ANRE_NUOR')
- ->join('S002V01TPROV', 'PROV_NUPR', '=', 'ORCO_NUPR')
- ->get([
- 'ANRE_IDAR',
- 'ANRE_NUOR',
- 'ANRE_DESC',
- 'ANRE_TIPO',
- 'ANRE_FEEN',
- 'ANRE_ESTA',
- 'ANRE_USRE',
- 'ANRE_FERE',
- 'ANRE_USMO',
- 'ANRE_FEMO',
- 'ORCO_NUOR',
- 'ORCO_NUPR',
- 'ORCO_NUDE',
- 'ORCO_IDLI',
- 'ORCO_MONE',
- 'ORCO_COST',
- 'ORCO_PROP',
- 'ORCO_ACTI',
- 'ORCO_PROY',
- 'PROV_NUPR',
- 'PROV_NOCO',
- 'PROV_NOMB',
- 'PROV_APPA',
- 'PROV_APMA',
- 'PROV_CORR',
- 'PROV_LAD1',
- 'PROV_TEL1',
- 'PROV_LAD2',
- 'PROV_TEL2',
- 'PROV_XRFC',
- 'PROV_XTAX',
- 'PROV_GIRO',
- 'PROV_TIPO',
- 'PROV_SIWE',
- 'PROV_MEPA',
- ]);
- } catch (\Throwable $th) {
- return $this->responseController->makeResponse(true, "ERR_DELAY_ANALYSIS_GET000: Ocurrió un error al momento de obtener los registros", $th->getMessage(), 500);
- }
- return $this->responseController->makeResponse(false, "ÉXITO: Consulta Exitosa", $getDelayAnalysis);
- }
- }
|