Code Coverage |
||||||||||
Classes and Traits |
Functions and Methods |
Lines |
||||||||
| Total | |
0.00% |
0 / 1 |
|
0.00% |
0 / 2 |
CRAP | |
0.00% |
0 / 20 |
| CurriculumPaperService | |
0.00% |
0 / 1 |
|
0.00% |
0 / 2 |
20.00 | |
0.00% |
0 / 20 |
| getHourSplitupDetails | |
0.00% |
0 / 1 |
6.00 | |
0.00% |
0 / 12 |
|||
| getHourSplitupDetailsInCurriculum | |
0.00% |
0 / 1 |
6.00 | |
0.00% |
0 / 8 |
|||
| <?php | |
| namespace com\linways\core\ams\professional\service\academic; | |
| use com\linways\base\util\MakeSingletonTrait; | |
| use com\linways\core\ams\professional\service\BaseService; | |
| use com\linways\core\ams\professional\exception\ProfessionalException; | |
| use stdClass; | |
| class CurriculumPaperService extends BaseService | |
| { | |
| use MakeSingletonTrait; | |
| /** | |
| * Get Hour splitup details | |
| * @return Array $properties | |
| */ | |
| public function getHourSplitupDetails() | |
| { | |
| try { | |
| $properties = []; | |
| $properties = $this->getHourSplitupDetailsInCurriculum(); | |
| $responseData = [ | |
| 'hourDetails' => $properties | |
| ]; | |
| return $responseData; | |
| } catch (\Exception $e) { | |
| throw new ProfessionalException($e->getCode(), $e->getMessage()); | |
| } | |
| } | |
| /** | |
| * Get Hour splitup details in curriculum | |
| * @return Array | |
| */ | |
| public function getHourSplitupDetailsInCurriculum() | |
| { | |
| $sql = "SELECT chsd.name,chsd.short_code AS shortCode ,chsd.properties->>'$.key' AS `key` FROM cm_hour_splitup_details chsd"; | |
| try { | |
| return $this->executeQueryForList($sql); | |
| } catch (\Exception $e) { | |
| throw new ProfessionalException($e->getCode(), $e->getMessage()); | |
| } | |
| } | |
| } | |