[Geomoose-users] Geomoose services language change

Dan Little theduckylittle at gmail.com
Tue Apr 28 22:44:11 PDT 2020


Translation has been a big missing feature in the 3.X series.

That said, I spent some time tonight to start tackling it. I would say by
the end of the weekend this pull request should be ready for review:
 - https://github.com/geomoose/gm3/pull/489

As noted in the pull request, the Spanish translation is very poor. Even
with my limited Spanish skills I can tell some things are really really bad
but it was a blind submission to Google Translate. For what it's worth, the
German translation was also hilariously bad.

On Tue, Apr 28, 2020 at 1:38 PM Christopher Hughes <chughes at co.lincoln.or.us>
wrote:

> I'm assuming you're trying to do this in GeoMoose 3.
>
> For search, my best guess would be in dist/services/search.js.
> You do have some ability to override the labels in your app.js file
> without having to modify the source files.
>
> For example, I've changed the default title of the search tool, as well as
> the results, when I declared my search service:
>
>         app.registerService('search-Taxlots-simple', SearchService, {
>             // The input fields are defined only using one field
>             title: 'Simple Taxlot Search',
>             resultsTitle: 'Taxlots Search Results',
>             fields: [
>                 {type: 'text', label: 'Simple Search', name: 'TERM'},
>             ],
>             prepareFields: function (fields) {
>                 // this pulls out the term from the search
>                 const searchTerm = fields[0].value;
>                 // this is the list of fields in the layer which will be searched.
>                 const searchFields = ['OwnName', 'SitusAll', 'ParcelID', 'PropertyId', 'Address1'];
>                 // this switched to matching any field
>                 var query = ['or'];
>                 for(var i = 0, ii = searchFields.length; i < ii; i++) {
>                     query.push({
>                         comparitor: 'ilike',
>                         name: searchFields[i],
>                         value: '%' + searchTerm + '%'
>                     });
>                 }
>                 return [query];
>             },
>             searchLayers: ['Taxlots_selection-wfs/Taxlots_selection'],
>             validateFieldValues: function (fields) {
>                 let nonEmpty = 0;
>                 const validateFieldValuesResult = {
>                     valid: true,
>                     message: null
>                 };
>
>                 if (fields['TERM'] !== undefined && fields['TERM'] !== '') {
>                         nonEmpty++;
>                 }
>
>                 if (nonEmpty === 0) {
>                     validateFieldValuesResult.valid = false;
>                     validateFieldValuesResult.message = 'Please complete at least one field.'
>                 }
>                 return validateFieldValuesResult;
>             }
>         });
>
>
>
>
> Hope this helps,
>
> Chris
>
>
>
>
>
>
>
>
> On Tue, Apr 28, 2020 at 10:37 AM <topografia at oliva.es> wrote:
>
>> I would like to change the language of the pop-up services. Specially
>> "print" and "search" services....I've allready changed the toolbar tabs
>> language...but I don't find the source files where change the label
>> language of the services. I've found the services print and serach under
>> the folders "idst" and "src" under the geomoose folder....which one do I
>> have to vhange? or none of those ones? Thanks.
>>
>> --
>> <http://oliva.es/es/>
>> *Cap del Departament de Cartografia i Topografia*
>> Lara Perez Bessone
>> Enginyera Tecnica Topografa Municipal
>> email: topografia at oliva.es Tel. mòvil: 647 835 086 ext. 521
>>
>>
>> *Ajuntament d'Oliva - València*
>> Plaça del Ajuntament 1, 46780 Oliva
>> Tel. 962850250 Fax 962855165 www.oliva.es
>> _______________________________________________
>> Geomoose-users mailing list
>> Geomoose-users at lists.osgeo.org
>> https://lists.osgeo.org/mailman/listinfo/geomoose-users
>
>
>
> --
> Chris Hughes
>
> GIS Analyst
> Lincoln County Surveyor Department
> 880 NE 7th St. l Newport, OR 97365
> Tel: (541) 574 1283
> _______________________________________________
> Geomoose-users mailing list
> Geomoose-users at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/geomoose-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geomoose-users/attachments/20200429/c67369a6/attachment.html>


More information about the Geomoose-users mailing list