Author Topic: Validations  (Read 421 times)

mikep

  • Pro Ultimate
  • Full Member
  • *
  • Posts: 163
    • View Profile
Validations
« on: November 08, 2022, 08:25:41 pm »
I'm getting the attached error when using validations. The error only occurs when cell is invalid. Do I need to add another reference to the page? Below are what I'm using.

    <script src="scripts/jquery-2.2.4.min.js"></script>
    <script src="scripts/jquery-ui.min.js"></script>
    <script src="Scripts/bootstrap.min.js"></script>
    <script src="Scripts/bootstrap-multiselect.js"></script>
    <script src="Scripts/bootstrap-datepicker.js"></script>
    <script src="Scripts/notifications.js"></script>

    <link rel="stylesheet" href="scripts/themes/smoothness/jquery-ui.css" />
    <link rel="stylesheet" href="https://code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css" />
    <link href="Content/bootstrap.css" rel="stylesheet" />
    <link href="Content/sp-layout.css" rel="stylesheet" />
    <link href="Content/RPM.css" rel="stylesheet" />
    <link href="Content/bootstrap-datepicker.css" rel="stylesheet" />
    <link href="Content/bootstrap-multiselect.css" rel="stylesheet" />
    <link href="Scripts/notifications.css" rel="stylesheet" />

    <script src="PQ/pqgrid.min.js"></script>
    <script src="PQ/pq-localize-en.js"></script>
    <script src="PQ/FileSaver.js"></script>
    <script src="PQ/jszip.min.js"></script>
    <link href="PQ/pqgrid.min.css" rel="stylesheet" />
    <link href="PQ/pqgrid.ui.min.css" rel="stylesheet" />
    <link href="PQ/themes/<%:theme%>/pqgrid.css" rel="stylesheet"  id="lnkTheme" />

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Re: Validations
« Reply #1 on: November 09, 2022, 06:25:42 am »
it looks like a bootstrap & jQueryUI conflict w.r.t same name of components.

Please follow this to resolve it: https://paramquery.com/pro/tutorial#topic-bootstrap

mikep

  • Pro Ultimate
  • Full Member
  • *
  • Posts: 163
    • View Profile
Re: Validations
« Reply #2 on: November 10, 2022, 12:39:08 am »
That's it. Thank you!

mikep

  • Pro Ultimate
  • Full Member
  • *
  • Posts: 163
    • View Profile
Re: Validations
« Reply #3 on: November 16, 2022, 06:23:34 pm »
The below validation works, but I also need to allow the user to delete the value. How would this change to allow deletes?

{ type: 'gt', value: '.099', msg: "value must be at least .1" }

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Re: Validations
« Reply #4 on: November 17, 2022, 06:52:07 am »
That would require a callback function. usage of validation callback functions is demonstrated in this example:

https://paramquery.com/pro/demos/editing_custom

Please let me know if you need further assistance.