Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - TenarisDev

Pages: [1]
1
Hello Support Team,

We are encountering an issue with date filters in ParamQuery Grid when the date column is formatted using a custom format function. Here are the steps to reproduce the problem:

1. Go to the ParamQuery demo: https://paramquery.com/pro/demos/filter_date#
2. Modify the singleFilter option to false in the configuration and rerun the demo:
menuUI: {
    singleFilter: false
}
3. Try to filter the "Order Date" column using both "Greater Than" and "Less Than" options (see attachment):
Select the first date from the date picker.
Select the second date from the date picker.

4. Observed Behavior:

The filter does not apply correctly.
The second date textbox is left empty.
An error appears in the console:
jquery-ui.min.js:9 Uncaught TypeError: t.charAt is not a function
    at s.formatDate (jquery-ui.min.js:9:8028)
    at s._formatDate (jquery-ui.min.js:9:20968)
    at s._selectDay (jquery-ui.min.js:9:4109)
    at HTMLTableCellElement.selectDay (jquery-ui.min.js:9:11648)
    at HTMLTableCellElement.dispatch (jquery-2.2.4.min.js:3:7537)
    at r.handle (jquery-2.2.4.min.js:3:5620)
We would appreciate your assistance in resolving this issue.

Thank you in advance for your support.
Best regards.

2
Help for ParamQuery Pro / Re: cell with conditional display text
« on: July 06, 2023, 12:41:20 am »
Thanks, this is great!

3
Help for ParamQuery Pro / cell with conditional display text
« on: July 05, 2023, 09:02:06 pm »
Hi,

I'm trying to make it so that when a cell in the grid has a value "TRUE" it shows "validated" and in the case that it is different from "TRUE" , it shows "not verified"
var dataMock2 = [{"VALID_EMAIL":"TRUE"}];
 

var obj3 = {
      width: "100%",
      height: 800,
      resizable: true,
      title: "",
      showBottom: false,
      scrollModel: { autoFit: true },
      dataModel: { data: dataMock2 },
      colModel: [
        { title: "VERIFIED MAIL", dataType: "STRING", dataIndx: "VALID_EMAIL",formula: function (ui) {                       
          var rd =  ui.rowData=="TRUE"?"VALIDATED":"No VALIDATED";
          return rd;
      } }
      ]
    }

    $("#grid_json").pqGrid(obj3);


Thank you very much for the help

4
Good afternoon ,
Do you have please an example for angular with version  "@angular/cli": "~16.0.3" and paramquery 9.0.0 with a basic grid ?
thanks

5

added webpack.config.js
module.exports = {

    module: {
        loaders: [
            { test: /\.js$/, loader: 'babel', exclude: /node_modules/, query: { presets: ['es2015'] } }, ,
            { test: /\.css$/, loader: 'style!css', exclude: /node_modules/ }
        ]
    }
    ,
    rules: [
        {
            test: /\.css$/,
            loader: ['style-loader', 'css-loader']
        },
        {
            test: /\.css$/,
            exclude: helpers.root('src', 'app'),
            loader: ExtractTextPlugin.extract({ fallbackLoader: 'style-loader', loader: 'css-loader?sourceMap' })
        },
        {
            test: /\.css$/,
            include: helpers.root('src', 'app'),
            loader: 'raw-loader'
        }
    ]
}
==================
package.json
{
  "name": "web-portal",
  "version": "0.0.0",
  "scripts": {
    "ng": "ng",
    "start": "ng serve",
    "build": "ng build",
    "watch": "ng build --watch --configuration development",
    "test": "ng test",
    "builddev": "webpack --mode development"
  },
  "private": true,
  "dependencies": {
    "@angular/common": "15.0.3",
    "@angular/compiler": "15.0.3",
    "@angular/core": "15.0.3",
    "@angular/forms": "15.0.3",
    "@angular/platform-browser": "15.0.3",
    "@angular/platform-browser-dynamic": "15.0.3",
    "@angular/router": "15.0.3",
    "@types/jquery": "3.3.29",
    "@types/jqueryui": "1.12.7",
    "core-js": "2.6.5",
 
    "jquery": "1.12.2",
    "jquery-ui-pack": "",
    "jszip": "2.5.0",
    "pqgrid": "^9.0.0",
    "rxjs": "6.5.3",
    "zone.js": "~0.13.1"
  },
  "devDependencies": {
    "@angular-devkit/build-angular": "^15.0.3",
    "@angular/cli": "^15.0.3",
    "@angular/compiler-cli": "^15.0.3",
    "@types/jasmine": "~4.3.0",
    "jasmine-core": "~4.6.0",
    "karma": "~6.4.0",
    "karma-chrome-launcher": "~3.2.0",
    "karma-coverage": "~2.2.0",
    "karma-jasmine": "~5.1.0",
    "karma-jasmine-html-reporter": "~2.0.0",
    "typescript": ">=4.8.2 and <4.9.0"
  }
}
===


./node_modules/jquery-ui-pack/jquery-ui.css:7:0 - Error: Module parse failed: Unexpected token (7:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| * Copyright jQuery Foundation and other contributors; Licensed MIT */
|
> .ui-draggable-handle {
|       -ms-touch-action: none;
|       touch-action: none;

./node_modules/jquery-ui-pack/jquery-ui.structure.css:11:0 - Error: Module parse failed: Unexpected token (11:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
|  * http://api.jqueryui.com/category/theming/
|  */
> .ui-draggable-handle {
|       -ms-touch-action: none;
|       touch-action: none;

./node_modules/jquery-ui-pack/jquery-ui.theme.css:17:0 - Error: Module parse failed: Unexpected token (17:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| /* Component containers
| ----------------------------------*/
> .ui-widget {
|       font-family: Arial,Helvetica,sans-serif;
|       font-size: 1em;


PS C:\Users\web-portal> webpack --mode development
[webpack-cli] Failed to load 'C:\web-portal\webpack.config.js' config
[webpack-cli] ReferenceError: helpers is not defined
    at Object.<anonymous> (C:\web-portal\webpack.config.js:17:22)
thank you so much


6
I have a way to fix it without using webpack

7
good afternoon, I need to make a basic grid with pqrid, and it doesn't show me data
app.component.ts
import { Component, OnInit } from '@angular/core';

import pq from 'pqgrid';


@Component({
  selector: 'app-root',
  templateUrl: './app.component.html',
  styleUrls: ['./app.component.css'],


})
export class AppComponent implements OnInit {

  ngOnInit(): void {

    //or array of objects
    var dataSales = [
      { rank: 1, company: 'Exxon Mobil', revenues: '339,938.0', profits: '36,130.0' },
      { rank: 2, company: 'Wal-Mart Stores', revenues: '315,654.0', profits: '11,231.0' },
      { rank: 3, company: 'Royal Dutch Shell', revenues: '306,731.0', profits: '25,311.0' },
      { rank: 4, company: 'BP', revenues: '267,600.0', profits: '22,341.0' },
      { rank: 5, company: 'General Motors', revenues: '192,604.0', profits: '-10,567.0' }];
    //Initialize pqGrid with data.
    pq.grid('app-root', { dataModel: { data: dataSales } });

  }

  title = 'web-portal';


}
--------------
app.component.html

<app-root></app-root>
------------------------
angular.json
{
  "$schema": "./node_modules/@angular/cli/lib/config/schema.json",
  "version": 1,
  "newProjectRoot": "projects",
  "projects": {
    "web-portal": {
      "projectType": "application",
      "schematics": {},
      "root": "",
      "sourceRoot": "src",
      "prefix": "app",
      "architect": {
        "build": {
          "builder": "@angular-devkit/build-angular:browser",
          "options": {
            "outputPath": "dist/web-portal",
            "index": "src/index.html",
            "main": "src/main.ts",
            "polyfills": [
              "zone.js"
            ],
            "tsConfig": "tsconfig.app.json",
            "assets": [
              "src/favicon.ico",
              "src/assets"
            ],
            "styles": [
              "src/styles.css",
              "./node_modules/jquery-ui-pack/jquery-ui.css"
             
            ],
            "scripts": [
              "./node_modules/jquery/dist/jquery.min.js"
            ]
          },
          "configurations": {
            "production": {
              "budgets": [
                {
                  "type": "initial",
                  "maximumWarning": "2mb",
                  "maximumError": "5mb"
                },
                {
                  "type": "anyComponentStyle",
                  "maximumWarning": "62kb",
                  "maximumError": "4kb"
                }
              ],
              "outputHashing": "all"
            },
            "development": {
              "buildOptimizer": false,
              "optimization": false,
              "vendorChunk": true,
              "extractLicenses": false,
              "sourceMap": true,
              "namedChunks": true,
              "aot": false
            }
          },
          "defaultConfiguration": "production"
        },
        "serve": {
          "builder": "@angular-devkit/build-angular:dev-server",
          "configurations": {
            "production": {
              "browserTarget": "web-portal:build:production"
            },
            "development": {
              "browserTarget": "web-portal:build:development"
            }
          },
          "defaultConfiguration": "development"
        },
        "extract-i18n": {
          "builder": "@angular-devkit/build-angular:extract-i18n",
          "options": {
            "browserTarget": "web-portal:build"
          }
        },
        "test": {
          "builder": "@angular-devkit/build-angular:karma",
          "options": {
            "polyfills": [
              "zone.js",
              "zone.js/testing"
            ],
            "tsConfig": "tsconfig.spec.json",
            "assets": [
              "src/favicon.ico",
              "src/assets"
            ],
            "styles": [
              "src/styles.css"
            ],
            "scripts": []
          }
        }
      }
    }
  },
  "cli": {
    "analytics": false
  }
}
=====
package.json
{
  "name": "web-portal",
  "version": "0.0.0",
  "scripts": {
    "ng": "ng",
    "start": "ng serve",
    "build": "ng build",
    "watch": "ng build --watch --configuration development",
    "test": "ng test"
  },
  "private": true,
  "dependencies": {
    "@angular/animations": "^16.0.0",
    "@angular/common": "^16.0.0",
    "@angular/compiler": "^16.0.0",
    "@angular/core": "^16.0.0",
    "@angular/forms": "^16.0.0",
    "@angular/platform-browser": "^16.0.0",
    "@angular/platform-browser-dynamic": "^16.0.0",
    "@angular/router": "^16.0.0",
    "jquery": "^3.7.0",
    "pqgrid": "^9.0.0",
    "rxjs": "~7.8.0",
    "tslib": "^2.3.0",
    "zone.js": "~0.13.0"
  },
  "devDependencies": {
    "@angular-devkit/build-angular": "^16.0.3",
    "@angular/cli": "~16.0.3",
    "@angular/compiler-cli": "^16.0.0",
    "@types/jasmine": "~4.3.0",
    "jasmine-core": "~4.6.0",
    "karma": "~6.4.0",
    "karma-chrome-launcher": "~3.2.0",
    "karma-coverage": "~2.2.0",
    "karma-jasmine": "~5.1.0",
    "karma-jasmine-html-reporter": "~2.0.0",
    "typescript": "~5.0.2"
  }
}
when making ng serve -o showed me


./node_modules/jquery-ui-pack/jquery-ui.css:9:0 - Error: Module parse failed: Unexpected token (9:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| /* Layout helpers
| ----------------------------------*/
> .ui-helper-hidden {
|       display: none;
| }

./node_modules/jquery-ui-pack/jquery-ui.structure.css:13:0 - Error: Module parse failed: Unexpected token (13:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| /* Layout helpers
| ----------------------------------*/
> .ui-helper-hidden {
|       display: none;
| }

./node_modules/jquery-ui-pack/jquery-ui.theme.css:17:0 - Error: Module parse failed: Unexpected token (17:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| /* Component containers
| ----------------------------------*/
> .ui-widget {
|       font-family: Arial,Helvetica,sans-serif;
|       font-size: 1em;



× Failed to compile.


I appreciate your help,thanks

Pages: [1]