You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

README.md 558 B

6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142
  1. # datatables
  2. Simple parser for Datatables.
  3. # Usage
  4. ```go
  5. import "github.com/saulortega/datatables"
  6. filter, err = datatables.Parse(r)
  7. if err != nil {
  8. //Handle error
  9. }
  10. ```
  11. # Struct
  12. ```go
  13. type Filter struct {
  14. Draw int
  15. Start int
  16. Length int
  17. Order []Order
  18. Columns []Column
  19. SearchValue string
  20. SearchRegex bool
  21. }
  22. type Column struct {
  23. Data string
  24. Name string
  25. Index int
  26. Orderable bool
  27. Searchable bool
  28. SearchValue string
  29. SearchRegex bool
  30. }
  31. type Order struct {
  32. Column Column
  33. Dir string
  34. }
  35. ```