Plugin Directory


Ignore:
Timestamp:
10/15/2026 07:29:29 PM (4 days ago)
Author:
roxyapi
Message:

Update to version 1.21.0 from GitHub

File:
1 edited

Legend:

Unmodified
Added
Removed
  • roxyapi/trunk/src/Generated/Forms/CalculatePlotAnalysisForm.php

    r3747703 r3749195  
    1919
    2020        public static function spec(): array {
     21                $labels = \RoxyAPI\Generated\FormLabels::for_language( \RoxyAPI\Support\Language::from_locale( determine_locale() ) );
    2122                return array(
    2223                        'operation_id' => 'calculatePlotAnalysis',
    2324                        'title'        => __( 'Plot', 'roxyapi' ),
    2425                        'submit_label' => __( 'Get reading', 'roxyapi' ),
    25                         'fold_optional' => true,
     26                        'locations'    => array(  ),
    2627                        'sections'     => array(
    2728                                array(
    2829                                        'name'   => 'plot',
    29                                         'label'  => __( 'Plot', 'roxyapi' ),
     30                                        'label'  => $labels['groups']['plot'] ?? 'Plot',
     31                                        'fold'   => false,
    3032                                        'fields' => array(
    3133                                        array(
    3234                                                'name' => 'width',
    33                                                 'label' => __( 'Width', 'roxyapi' ),
     35                                                'label' => $labels['fields']['width'] ?? 'Width, east to west',
    3436                                                'required' => false,
    35                                                 'help' => __( 'East-west extent of a rectangular plot, in the unit given', 'roxyapi' ),
    3637                                                'type' => 'number',
     38                                                'min' => 0,
    3739                                                'step' => 'any',
     40                                                'fold' => false,
    3841                                        ),
    3942                                        array(
    4043                                                'name' => 'depth',
    41                                                 'label' => __( 'Depth', 'roxyapi' ),
     44                                                'label' => $labels['fields']['depth'] ?? 'Depth, north to south',
    4245                                                'required' => false,
    43                                                 'help' => __( 'North-south extent of a rectangular plot, in the unit given', 'roxyapi' ),
    4446                                                'type' => 'number',
     47                                                'min' => 0,
    4548                                                'step' => 'any',
     49                                                'fold' => false,
    4650                                        ),
    4751                                        array(
    4852                                                'name' => 'unit',
    49                                                 'label' => __( 'Unit', 'roxyapi' ),
     53                                                'label' => $labels['fields']['unit'] ?? 'Unit',
    5054                                                'required' => false,
    51                                                 'help' => __( 'Unit the plot dimensions are given in', 'roxyapi' ),
    5255                                                'type' => 'enum',
    5356                                                'enum' => array( 'feet', 'metres' ),
     57                                                'default' => 'feet',
     58                                                'enum_labels' => array( $labels['enums']['unit.feet'] ?? 'Feet', $labels['enums']['unit.metres'] ?? 'Metres' ),
     59                                                'fold' => false,
    5460                                        ),
    5561                                        ),
    … …  
    5965                                array(
    6066                                        'name' => 'facing',
    61                                         'label' => __( 'Facing', 'roxyapi' ),
     67                                        'label' => $labels['fields']['facing'] ?? 'Facing direction',
    6268                                        'required' => false,
    63                                         'help' => __( 'Direction the front of the house looks out toward, one of the eight compass sectors', 'roxyapi' ),
    6469                                        'type' => 'enum',
    6570                                        'enum' => array( 'North', 'Northeast', 'East', 'Southeast', 'South', 'Southwest', 'West', 'Northwest' ),
     71                                        'enum_labels' => array( $labels['enums']['facing.North'] ?? 'North', $labels['enums']['facing.Northeast'] ?? 'Northeast', $labels['enums']['facing.East'] ?? 'East', $labels['enums']['facing.Southeast'] ?? 'Southeast', $labels['enums']['facing.South'] ?? 'South', $labels['enums']['facing.Southwest'] ?? 'Southwest', $labels['enums']['facing.West'] ?? 'West', $labels['enums']['facing.Northwest'] ?? 'Northwest' ),
     72                                        'fold' => false,
    6673                                ),
    6774                                array(
    6875                                        'name' => 'facingDegrees',
    69                                         'label' => __( 'Facing degrees', 'roxyapi' ),
     76                                        'label' => $labels['fields']['facingDegrees'] ?? 'Facing degrees',
    7077                                        'required' => false,
    71                                         'help' => __( 'Direction the front of the house looks out toward, as a compass bearing in degrees clockwise from true north, measured looking OUT from the building', 'roxyapi' ),
    7278                                        'type' => 'number',
    7379                                        'min' => 0,
    7480                                        'max' => 360,
    7581                                        'step' => 'any',
     82                                        'fold' => false,
    7683                                ),
    7784                                array(
    7885                                        'name' => 'slopeLowDirection',
    79                                         'label' => __( 'Slope low direction', 'roxyapi' ),
     86                                        'label' => $labels['fields']['slopeLowDirection'] ?? 'Direction the ground falls toward',
    8087                                        'required' => false,
    81                                         'help' => __( 'Which quarter of the plot the ground falls toward, that is where the LOW point is', 'roxyapi' ),
    8288                                        'type' => 'enum',
    8389                                        'enum' => array( 'North', 'Northeast', 'East', 'Southeast', 'South', 'Southwest', 'West', 'Northwest' ),
     90                                        'enum_labels' => array( $labels['enums']['slopeLowDirection.North'] ?? 'North', $labels['enums']['slopeLowDirection.Northeast'] ?? 'Northeast', $labels['enums']['slopeLowDirection.East'] ?? 'East', $labels['enums']['slopeLowDirection.Southeast'] ?? 'Southeast', $labels['enums']['slopeLowDirection.South'] ?? 'South', $labels['enums']['slopeLowDirection.Southwest'] ?? 'Southwest', $labels['enums']['slopeLowDirection.West'] ?? 'West', $labels['enums']['slopeLowDirection.Northwest'] ?? 'Northwest' ),
     91                                        'fold' => false,
    8492                                ),
    8593                                array(
    8694                                        'name' => 'road',
    87                                         'label' => __( 'Road', 'roxyapi' ),
     95                                        'label' => $labels['fields']['road'] ?? 'Road side',
    8896                                        'required' => false,
    89                                         'help' => __( 'Which side a road runs along', 'roxyapi' ),
    9097                                        'type' => 'enum',
    9198                                        'enum' => array( 'North', 'Northeast', 'East', 'Southeast', 'South', 'Southwest', 'West', 'Northwest' ),
     99                                        'enum_labels' => array( $labels['enums']['road.North'] ?? 'North', $labels['enums']['road.Northeast'] ?? 'Northeast', $labels['enums']['road.East'] ?? 'East', $labels['enums']['road.Southeast'] ?? 'Southeast', $labels['enums']['road.South'] ?? 'South', $labels['enums']['road.Southwest'] ?? 'Southwest', $labels['enums']['road.West'] ?? 'West', $labels['enums']['road.Northwest'] ?? 'Northwest' ),
     100                                        'fold' => false,
    92101                                ),
    93102                                array(
    94103                                        'name' => 'water',
    95                                         'label' => __( 'Water', 'roxyapi' ),
     104                                        'label' => $labels['fields']['water'] ?? 'Standing water direction',
    96105                                        'required' => false,
    97                                         'help' => __( 'Which quarter holds standing water, a well, a tank or a sump', 'roxyapi' ),
    98106                                        'type' => 'enum',
    99107                                        'enum' => array( 'North', 'Northeast', 'East', 'Southeast', 'South', 'Southwest', 'West', 'Northwest' ),
     108                                        'enum_labels' => array( $labels['enums']['water.North'] ?? 'North', $labels['enums']['water.Northeast'] ?? 'Northeast', $labels['enums']['water.East'] ?? 'East', $labels['enums']['water.Southeast'] ?? 'Southeast', $labels['enums']['water.South'] ?? 'South', $labels['enums']['water.Southwest'] ?? 'Southwest', $labels['enums']['water.West'] ?? 'West', $labels['enums']['water.Northwest'] ?? 'Northwest' ),
     109                                        'fold' => false,
    100110                                ),
    101111                                array(
    102112                                        'name' => 'slopeSchool',
    103                                         'label' => __( 'Slope school', 'roxyapi' ),
     113                                        'label' => $labels['fields']['slopeSchool'] ?? 'Ground level school',
    104114                                        'required' => false,
    105                                         'help' => __( 'Which reading of the ground level to lead with', 'roxyapi' ),
    106115                                        'type' => 'enum',
    107116                                        'enum' => array( 'brihat-samhita', 'modern' ),
     117                                        'default' => 'brihat-samhita',
     118                                        'enum_labels' => array( $labels['enums']['slopeSchool.brihat-samhita'] ?? 'Brihat samhita', $labels['enums']['slopeSchool.modern'] ?? 'Modern' ),
     119                                        'fold' => true,
    108120                                ),
    109121                        ),
Note: See TracChangeset for help on using the changeset viewer.