Addition to Module Request: Numerical Data Types or Data Type RDF

May I please request an addition to either the Numeric Data Types or Data Types RDF module? Having an easy way to make a list of items and amounts seems like it would definitely be related to either module. Much like the Timestamp can put together a date and/or time, what about putting together a number and some text?

Ideal Examples:
12 catsNumber Field + Text Field
5.4 feather toysNumber (Decimal) Field + Text Field
1 dozen cat condosNumber Field + Unit of Measure option + Text Field
total cost $ 999.999Text field + Symbol option + Number Field (Decimal)

Set up in the Resource Template:
Options/Order (for last line: total cost = $ 999.99)
:blue_square: :blue_square: :three: :blue_square: Number :white_check_mark: Allow decimal up to :arrow_up_down: 2 places :blue_square: Don’t Constrain
:blue_square: :two: :blue_square: :blue_square: Symbol :white_check_mark: Defined: $ . :blue_square: Don’t Constrain
:blue_square: :blue_square: :blue_square: :blue_square: Unit of Measure :blue_square: Defined: _____ :blue_square: Don’t Constrain
:one: :blue_square: :blue_square: :blue_square: Text Field

Followup TODO: Can this be connected to Data Visualization?

Thanks for the feature requests. I can see how such things can be useful.

Though I’m not sure NumericDataTypes is the appropriate module for what you’re asking; and resource templates have limited control over how data types are configured per property. So the changes you’re requesting would represent quite a departure from the current state of things.

It was just a thought of how it could work. But since I’m not inherently a coder, I know very little of how modules work, so I leave that to the experts. :woman_shrugging:
Is there a way to something similar to my suggestion, but that would work like the rest of the module?

While I am not inherently a coder, I have been wanting to play with modules. So I thought this one may be a good one to play with. While it’s not simple, I’m hoping that since what I want to do is similar to something it already does, it would be a good template of sorts.

If I wanted to try and write an extension of the NumericDataTypes module to try and make this new data type, which files/folders would need to be added to? Looking through the file structure, I noted where I THINK I need to add or modify a file. Am I far off?

NumericDataTypes-Plus  /*good name?*/
→ asset
     → css  /*?*/
          []numeric-data-types.css
     → Js
          []numeric-data-types.js
          → Faceted browse  /*eventually*/
               → Facet-data-form
                    []New Document
               → Facet-render
                    []New Document
→ Config
     []Module.config.php
     []module.ini
→ Data
     → Doctrine-proxies  /*?*/
          []New Document
→ Src
     → Controller
          → SiteAdmin
               → FacetedBrowse  /*eventually*/
                    []IndexController.php
     → DataType
          []New Document
     → Datavis  /*eventually*/
          → Data Set Type
               []New Document
          → Diagram Type
               []New Document
     → Entity
          []New Document
     → Faceted Browse  /*eventually*/
          → Facet Type
               []New Document
     → Form
          → Element
               []New Document
     → Service
          → Delegator
               []FormElementDelegatorFactory.php
          → Faceted Browse  /*eventually*/
               → Facet Type
                    []New Document
          → Form
               → Element
                    []NumericPropertySelectFactory.php
          → ViewHelper
               []NumericPropertySelectFactory.php
     → View
          → Helper
               []New Document
→ View
     → Common
          []New Document
          → Faceted Browse  /*eventually*/
               → Facet-data
                    []New Document
               → facet-render
                    []New Document

The ones marked /*eventually*/ (Faceted Browse or Datavis) should be able to wait until the rest of the new data types are working elsewhere.

I figured it would be a good idea to look at how the Timestamp is set up, since it sets up multiple values to be put together as one. So that’s what I looked for in the file structure.

Instead of the radio buttons that I originally illustrated, I am looking at other ways to try and specify the order of data types. But I figured I’d start with one and work from there.

This topic was automatically closed 360 days after the last reply. New replies are no longer allowed.