YetiForceCompany/YetiForceCRM

View on GitHub

Showing 4,652 of 306,333 total issues

Method getCoordinates has 35 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function getCoordinates(array $addressInfo)
    {
        $product = \App\YetiForce\Register::getProduct('YetiForceMap');
        if (empty($addressInfo) || !\App\RequestUtil::isNetConnection() || ((empty($product['params']['login']) || empty($product['params']['pass'])) && empty($product['params']['token']))) {
            return false;
Severity: Minor
Found in app/Map/Coordinates/YetiForce.php - About 1 hr to fix

    Method explode has 35 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        public static function explode($date, $format = false)
        {
            if (empty($format)) {
                $format = 'yyyy-mm-dd';
            }
    Severity: Minor
    Found in app/Fields/Date.php - About 1 hr to fix

      Method create has 35 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          public function create()
          {
              if (\array_diff_key($this->getData(), $this->template)) {
                  throw new Exceptions\IllegalValue('ERR_NOT_ALLOWED_VALUE', 406);
              }
      Severity: Minor
      Found in app/ConfigFile.php - About 1 hr to fix

        Method addRoleToPicklist has 35 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            public static function addRoleToPicklist($fields): void
            {
                \App\Log::trace('Entering ' . __METHOD__);
                $db = \App\Db::getInstance();
                $schema = $db->getSchema();
        Severity: Minor
        Found in app/Db/Updater.php - About 1 hr to fix

          Method confirm has 35 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              public function confirm(App\Request $request): void
              {
                  $result = false;
                  $responseType = 'error';
                  $message = \App\Language::translate('LBL_INVALID_VERIFICATION_CODE', $request->getModule(false));
          Severity: Minor
          Found in modules/Settings/Companies/actions/VerifyEmail.php - About 1 hr to fix

            Method save has 35 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                public function save(App\Request $request)
                {
                    $response = new Vtiger_Response();
                    $moduleName = $request->getModule(false);
                    $result = true;
            Severity: Minor
            Found in modules/Settings/PublicHoliday/actions/Holiday.php - About 1 hr to fix

              Method getFields has 35 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  public static function getFields(): array
                  {
                      $config = \App\Config::component('Mail', null, []);
                      $fields = [
                          'rcListCheckRbl' => [
              Severity: Minor
              Found in modules/Settings/MailRbl/models/ConfigModal.php - About 1 hr to fix

                Method getRenewalValue has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    public function getRenewalValue()
                    {
                        if ($this->isEmpty('serviceid') || !\App\Record::isExists($this->get('serviceid'), 'Services')) {
                            return 'PLL_NOT_APPLICABLE_VERIFICATION';
                        }
                Severity: Minor
                Found in modules/OSSSoldServices/models/Record.php - About 1 hr to fix

                  Method process has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      public function process(App\Request $request)
                      {
                          $moduleName = $request->getModule();
                          $sourceRecord = $request->getInteger('sourceRecord');
                          $sourceModule = $request->getByType('sourceModule', 2);
                  Severity: Minor
                  Found in modules/OSSMail/actions/GetMail.php - About 1 hr to fix

                    Method updateMailBoxCounter has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        public static function updateMailBoxCounter(array $users): array
                        {
                            if (empty($users)) {
                                return [];
                            }
                    Severity: Minor
                    Found in modules/OSSMail/models/Record.php - About 1 hr to fix

                      Method saveAttachments has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          public function saveAttachments()
                          {
                              $userId = $this->getAccountOwner();
                              $useTime = $this->get('date');
                              $files = $this->get('files');
                      Severity: Minor
                      Found in modules/OSSMail/models/Mail.php - About 1 hr to fix

                        Method process has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            public function process(App\Request $request)
                            {
                                $currentUser = \App\User::getCurrentUserModel();
                                $moduleName = $request->getModule();
                                $linkId = $request->getInteger('linkid');
                        Severity: Minor
                        Found in modules/Accounts/dashboards/NeglectedAccounts.php - About 1 hr to fix

                          Method process has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                              public function process(App\Request $request)
                              {
                                  $currentUserId = \App\User::getCurrentUserId();
                                  $viewer = $this->getViewer($request);
                                  $moduleName = $request->getModule();
                          Severity: Minor
                          Found in modules/OSSTimeControl/dashboards/TimeControl.php - About 1 hr to fix

                            Method getUnreviewed has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                public static function getUnreviewed($recordsId, $userId = false, $sort = false)
                                {
                                    if (false === $userId) {
                                        $userId = \App\User::getCurrentUserId();
                                    }
                            Severity: Minor
                            Found in modules/ModTracker/models/Record.php - About 1 hr to fix

                              Method getSettingLinks has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  public function getSettingLinks(): array
                                  {
                                      Vtiger_Loader::includeOnce('~~modules/com_vtiger_workflow/VTWorkflowUtils.php');
                                      $settingsLinks = [];
                                      if (\App\Security\AdminAccess::isPermitted('Workflows') && VTWorkflowUtils::checkModuleWorkflow($this->getName())) {
                              Severity: Minor
                              Found in modules/Documents/models/Module.php - About 1 hr to fix

                                Method validate has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                    public function validate($value, $isUserFormat = false)
                                    {
                                        if (empty($value) || isset($this->validate[$value])) {
                                            return;
                                        }
                                Severity: Minor
                                Found in modules/Vtiger/uitypes/Recurrence.php - About 1 hr to fix

                                  Method getDisplayValue has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      public function getDisplayValue($value, $record = false, $recordModel = false, $rawText = false, $length = false)
                                      {
                                          if (empty($value)) {
                                              return null;
                                          }
                                  Severity: Minor
                                  Found in modules/Vtiger/uitypes/Multipicklist.php - About 1 hr to fix

                                    Method getInstance has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                        public static function getInstance($parentModuleModel, $relatedModuleModel, $relationId = false)
                                        {
                                            $relKey = $parentModuleModel->getId() . '_' . $relatedModuleModel->getId() . '_' . $relationId;
                                            if (isset(self::$cachedInstances[$relKey])) {
                                                return self::$cachedInstances[$relKey] ? clone self::$cachedInstances[$relKey] : self::$cachedInstances[$relKey];
                                    Severity: Minor
                                    Found in modules/Vtiger/models/Relation.php - About 1 hr to fix

                                      Method getSummaryInfo has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                          public function getSummaryInfo()
                                          {
                                              $moduleName = $this->getModuleName();
                                              $path = "modules/$moduleName/summary_blocks";
                                              if (!is_dir($path)) {
                                      Severity: Minor
                                      Found in modules/Vtiger/models/Record.php - About 1 hr to fix

                                        Method process has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                            public function process(App\Request $request)
                                            {
                                                $record = $request->getInteger('record');
                                                $recordModel = Vtiger_Record_Model::getInstanceById($record, $request->getModule());
                                                if (!$recordModel->isViewable()) {
                                        Severity: Minor
                                        Found in modules/Vtiger/actions/GetData.php - About 1 hr to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language