Showing 635 of 1,693 total issues
Function initializeDatePicker
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private initializeDatePicker() {
this.datePickerInstance = new DatePicker(
this.injector,
this.id,
this.value || '',
Function buildDefaultTabs
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private buildDefaultTabs():WpTabDefinition[] {
return [
{
component: WorkPackageOverviewTabComponent,
name: this.I18n.t('js.work_packages.tabs.overview'),
Function constructor
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
constructor(readonly I18n:I18nService,
readonly querySpace:IsolatedQuerySpace,
readonly wpTableFilters:WorkPackageViewFiltersService) {
super();
Function lazyInit
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private lazyInit(renderer:TimelineCellRenderer, renderInfo:RenderInfo):Promise<void> {
const body = this.workPackageTimeline.timelineBody[0];
const cell = this.cellElement;
if (!cell.length) {
Function extractPayloadFromSchema
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
static extractPayloadFromSchema<T extends HalResource = HalResource>(resource:T, schema:SchemaResource) {
const payload:any = {
_links: {},
};
Function ngOnInit
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
ngOnInit():void {
if (this.modelCount === 0) {
return;
}
Method controller_work_package_new_after_save
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def controller_work_package_new_after_save(context = {})
params = context[:params]
work_package = context[:work_package]
return unless work_package.backlogs_enabled?
Function Impediment
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
RB.Impediment = (function ($) {
return RB.Object.create(RB.Task, {
initialize: function (el) {
var j; // This ensures that we use a local 'j' variable, not a global one.
Method included
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def self.included(base)
base.class_eval do
include VersionSettingsHelper
helper :version_settings
Method update
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def update
# TODO: copied over from edit
# remove code where appropriate
if @project
# Hourly Rate
Function drop
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
async drop(el:Element, target:Element, _source:Element|null, _sibling:Element|null) {
const dropUrl = el.getAttribute('data-drop-url');
let targetPosition = Array.from(target.children).indexOf(el);
if (target.children.length > 0 && target.children[0].getAttribute('data-empty-list-item') === 'true') {
Function getFieldTypeConfig
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private getFieldTypeConfig(field:IOPFieldSchemaWithKey):IOPFormlyFieldSettings|null {
const fieldType = field.type.replace('[]', '') as OPFieldType;
const inputType = this.inputsCatalogue.find((inputType) => inputType.useForFields.includes(fieldType))!;
if (!inputType) {
Function ngOnInit
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
ngOnInit() {
this.workPackagePath = this.PathHelper.workPackagePath(this.workPackage.id!);
this.canModifyHierarchy = !!this.workPackage.changeParent;
this.canAddRelation = !!this.workPackage.addRelation;
Function loadPrincipalData
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private loadPrincipalData(searchTerm:string) {
const nonMemberFilter = new ApiV3FilterBuilder();
if (searchTerm) {
nonMemberFilter.add('any_name_attribute', '~', [searchTerm]);
}
Function calendarMeetingsFunction
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public calendarMeetingsFunction(
fetchInfo:{ start:Date, end:Date, timeZone:string },
successCallback:(events:EventInput[]) => void,
):void {
if (!this.showMeetings) {
Function mockRequest
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const mockRequest = () => {
httpMock
.match((req) => req.url.includes('/api/v3/capabilities'))
.forEach((req) => {
expect(req.request.method).toBe('GET');
Function newViewer
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public newViewer(elements:XeokitElements, projects:IfcProjectDefinition[]):void {
const server = new XeokitServer(this.pathHelper);
// eslint-disable-next-line @typescript-eslint/no-unsafe-call
const viewerUI = new BIMViewer(server, elements) as XeokitBimViewer;
Function initialize
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
initialize: function (el) {
this.$ = $(el);
this.el = el;
// Associate this object with the element for later retrieval
Method fix_other_work_package_positions
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def fix_other_work_package_positions
if changes.slice("project_id", "type_id", "version_id").present?
if changes.slice("project_id", "version_id").blank? and
Story.types.include?(type_id.to_i) and
Story.types.include?(type_id_was.to_i)
Method render
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def render
write(content_tag(:div, id: "#{filter_class.underscore_name}_arg_1", class: "advanced-filters--filter-value") do
select_options = { "data-remote-url": url_for(action: "available_values"),
"data-initially-selected": JSON::dump(Array(filter.values).flatten),
style: "vertical-align: top;", # FIXME: Do CSS