Showing 4,652 of 306,333 total issues
Function triggerMassQuickCreate
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
triggerMassQuickCreate: function (moduleName, data) {
const self = this.relatedListInstance;
if (self.checkListRecordSelected() !== true) {
let listParams = self.getSelectedParams();
let progress = $.progressIndicator({ blockInfo: { enabled: true } });
Function registerActivityState
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
registerActivityState() {
const self = this;
$('.js-activity-buttons button:not(.close)').on('click', function (e) {
let currentTarget = $(e.currentTarget),
viewName = app.getViewName();
Function getParams
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
getParams() {
let data = {};
let paramsForm = this.form.serializeFormData();
this.form.find('.saveParam').each(function (_, element) {
if (typeof paramsForm[element.name] !== 'undefined') {
Function preQuickCreateSave
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
let preQuickCreateSave = function (data) {
let index, queryParam, queryParamComponents;
let queryParameters = [];
if (typeof fullFormUrl !== 'undefined' && fullFormUrl.indexOf('?') !== -1) {
Function saveDiscountsParameters
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
saveDiscountsParameters: function (parentRow, modal) {
const typeName = 'aggregationType',
panels = modal.find('[name="' + typeName + '"]:checked');
let info = {};
info[typeName] = [];
Function formatTooltipTitles
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
formatTooltipTitles: function formatTooltipTitles(data) {
data.datasets.forEach((dataset) => {
if (typeof dataset.titlesFormatted === 'undefined') {
dataset.titlesFormatted = [];
dataset.data.forEach((dataItem, index) => {
Function preQuickCreateSave
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
let preQuickCreateSave = function (data) {
let index, queryParam, queryParamComponents;
let queryParameters = [];
if (typeof fullFormUrl !== 'undefined' && fullFormUrl.indexOf('?') !== -1) {
Function loadProject
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
loadProject(projectData) {
this.projectData = projectData;
if (typeof this.projectData.tasks === 'undefined' || this.projectData.tasks.length === 0) {
$('.js-hide-filter').addClass('d-none');
$('.js-show-add-record').removeClass('d-none');
Function readAndValidate
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
readAndValidate: function (file, editor) {
const aDeferred = jQuery.Deferred(),
fieldInfo = $(editor.element.$).data('fieldinfo');
let length = editor.getData().length,
selectedImg = editor.getSelection();
Function registerAfterLoginEvents
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
registerAfterLoginEvents: function () {
if (this.processEvents === false) {
let processEvents = $('#processEvents');
if (processEvents.length === 0) {
return;
Method testRecordModel
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function testRecordModel()
{
$recordModel = \Settings_Currency_Record_Model::getInstance(self::$id);
$this->assertNotNull($recordModel, 'Expected recordModel is not empty');
$this->assertNotEmpty($recordModel->getName(), 'Expected name is not empty');
Method testAddInventoryRecord
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function testAddInventoryRecord(): void
{
$request = $this->httpClient->post('FInvoiceProforma/Record/', \App\Utils::merge(['json' => [
'subject' => 'Api YetiForce FInvoiceProforma',
'paymentdate' => date('Y-m-d'),
Method emit
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function emit()
{
$contentTypeSent = false;
foreach ($this->headers as $header) {
if (!$contentTypeSent && 0 === stripos($header, 'content-type')) {
Method __construct
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function __construct($media = '')
{
parent::__construct();
$this->debugging = App\Config::debug('DISPLAY_DEBUG_VIEWER');
Method view
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function view($templateName, $moduleName = '', $fetch = false)
{
$templatePath = $this->getTemplatePath($templateName, $moduleName);
if (\App\Cache::has('ViewerTemplateExists', $templatePath)) {
$templateFound = \App\Cache::get('ViewerTemplateExists', $templatePath);
Method unzip
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function unzip($toDir, bool $close = true)
{
if (\is_string($toDir)) {
$toDir = [$toDir];
}
Method getBasicLibraries
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public static function getBasicLibraries(): array
{
return [
'YetiForce' => [
'name' => 'YetiForce',
Method sendReport
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public static function sendReport(array $data): array
{
if (!\App\RequestUtil::isNetConnection()) {
return ['status' => false, 'message' => \App\Language::translate('ERR_NO_INTERNET_CONNECTION', 'Other:Exceptions')];
}
Method updateLabelOnSave
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public static function updateLabelOnSave(\Vtiger_Record_Model $recordModel): void
{
$label = '';
$metaInfo = \App\Module::getEntityInfo($recordModel->getModuleName());
$dbCommand = Db::getInstance()->createCommand();
Method getQueryRoom
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function getQueryRoom(): Db\Query
{
switch ($this->roomType) {
case 'crm':
return (new Db\Query())