Giter Site home page Giter Site logo

r3-team / r3 Goto Github PK

View Code? Open in Web Editor NEW
251.0 11.0 37.0 52.01 MB

REI3 - Free and open low code

Home Page: https://rei3.de

License: MIT License

Go 40.24% CSS 5.20% JavaScript 48.00% HTML 6.56%
low-code free-software golang selfhosted internal-tools business-managment business-software lowcode business-solutions no-code

r3's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

r3's Issues

preset record selector from dependant application

There is a preset record selector in Forms builder -> Form settings -> States -> Conditions. But the selector offers only preset records from the current Application, not from the Build-on Applications. (bug or feature?)

It would be great if such preset record selector will be available also in Frontend/Backend functions. (feature request)

ReferenceError: RELATION_NAME is not defined

I have two Relations with the 1:1 relation and a Form with Fields from both Relations. The Form has a frontend Function assigned and inside the Function calls app.get_field_value() to read the values from both Relations.

It works well if both Relations are inside one Application. However, if the two Relations are in different dependent Applications, an error "ReferenceError: THE_OTHER_RELATION is not defined" occured.

Italian translation

Hi,
I found your project very interesting. So I've translated it in Italian language (see attached file).
I've created it_it file as copy of en_us in var/texts directory and translate it. Stop service and restart it (windows portable version 2.4.3), but language it_it not in Settings-Display-Language drop list.

If I translate some core company application in Italian, I can select it_it in drop-list, but platform label are still in English also after service restart.

How can I add Italian translation to platform?

Thanks,
Fabio.

it_it.zip

question regarding Rest API

Hi @r3-gabriel , nice work, congrats.
My question is simple: once I have created my application may I upload data with a batch script?
Are Rest API available for REI3?
Thanks for clarifying that.
Regards.

Adding a new password entry with a group at creation time corrupts the database

Hi,

When I add a new password entry and add a group at creation time, a key entry is not created in instance_e2ee."keys_7a1e594c-f785-4716-be89-c4024d0adb84". This results in a broken DB which triggers in data.Get_tx:

		if len(encKeys) != len(recordIds) {
			return results, 0, handler.CreateErrCode("SEC",
				handler.ErrCodeSecDataKeysNotAvailable)
		}

if the password entry which has been created in this state is in the set of entries to be retrieved. This results in this case in no entry being displayed at all; instead a popup error message appears that says: "The system failed to retrieve decryption keys for the selected records."
Note: in this situation a knowledgeable user, especially one with direct access to the DB, can manage to access their correctly saved passwords by creating a filter that excludes the broken ID entries: (AND (ID unequal x))

I've investigated a bit why a correct entry is not created, but not up to the root cause. I've only seen that in:

func SetKeys_tx(ctx context.Context, tx pgx.Tx, relationId uuid.UUID,
	recordId int64, keys []types.DataSetEncKeys) error {

	if len(keys) == 0 {
		return nil
	}

	if _, err := tx.Prepare(ctx, "store_keys", fmt.Sprintf(`
...

when I attempt to create a new password entry with a group, keys is empty so nil is silently returned and no key is inserted.

In contrast with when I create a new password entry without adding a group, keys is not empty (it contains one element) so a key is inserted, and the database is not corrupted.

For information I'm a member of the group I attempted to add to a new entry. I did not try with groups I'm not a member of.

Modal subform

Hi,
in the team form, if I want to add a new member not in the list, when I click on the plus icon in the field the applicatin switch to a new form and all inputs are lost. In this case I expected a modal form in witch I can add a new member and then I can continue without any lost of datas.

How can I do it?

Thanks,
Fabio.

Typo

under Admin > System Configuration > Logins

Passwort settings:

Docker compose errors

When attempting to install via docker compose I am getting the follow error.
root@ssdnodes-6582dbb1769a2:~/docker/r3# docker-compose up
Building r3
[+] Building 2.5s (8/8) FINISHED docker:default
=> CACHED [internal] load git source https://github.com/r3-team/r3_docker.git#main 0.3s
=> [internal] load metadata for docker.io/library/debian:stable-slim 1.0s
=> [1/5] FROM docker.io/library/debian:stable-slim@sha256:4255c9f8a4d6e66488adc0c2084c99df44bda22849b21b3afc0e9746e9a0be18 0.0s
=> https://rei3.de/downloads/REI3_3.6_x64_linux.tar.gz 0.4s
=> CACHED [2/5] RUN bash -c 'mkdir -p /opt/r3/data/{certificates,files,temp,transfer}' && apt-get update && apt-get install imagemagick ghostscript postgresql-client ca-certificat 0.0s
=> CACHED [3/5] WORKDIR /opt/r3 0.0s
=> CACHED [4/5] ADD https://rei3.de/downloads/REI3_3.6_x64_linux.tar.gz . 0.0s
=> ERROR [5/5] RUN tar -xvf REI3_3.6_x64_linux.tar.gz r3 config_template.json && sed -i "s/localhost/r3_db/g" config_template.json && sed -i "s/443/80/g" config_template.json && 0.7s

[5/5] RUN tar -xvf REI3_3.6_x64_linux.tar.gz r3 config_template.json && sed -i "s/localhost/r3_db/g" config_template.json && sed -i "s/443/80/g" config_template.json && chmod 755 r3 && chmod 644 config_template.json && rm REI3_3.6_x64_linux.tar.gz:
0.572
0.572 gzip: stdin: not in gzip format
0.576 tar: Child returned status 1
0.576 tar: Error is not recoverable: exiting now


Dockerfile:28

27 | ADD https://rei3.de/downloads/REI3_${r3_version}_${r3_os_arch}_linux.tar.gz .
28 | >>> RUN tar -xvf REI3_${r3_version}${r3_os_arch}linux.tar.gz r3 config_template.json
29 | >>> && sed -i "s/localhost/${r3_db_host}/g" config_template.json
30 | >>> && sed -i "s/443/80/g" config_template.json
31 | >>> && chmod 755 r3 && chmod 644 config_template.json
32 | >>> && rm REI3
${r3_version}
${r3_os_arch}_linux.tar.gz
33 |

ERROR: failed to solve: process "/bin/sh -c tar -xvf REI3_${r3_version}${r3_os_arch}linux.tar.gz r3 config_template.json \t&& sed -i "s/localhost/${r3_db_host}/g" config_template.json \t&& sed -i "s/443/80/g" config_template.json \t&& chmod 755 r3 && chmod 644 config_template.json \t&& rm REI3${r3_version}${r3_os_arch}_linux.tar.gz" did not complete successfully: exit code: 2
ERROR: Service 'r3' failed to build : Build failed
root@ssdnodes-6582dbb1769a2:~/docker/r3#
I have attached an example for the yml file
docker-compose.yml.txt

Docker image missing directories

Description

I keep getting errors when trying to install "A Core Company" or any other app.
The app does not seem to create the required temp and transfer directories in the r3 container's /opt/r3/data bind mount directory.

The app only works after stopping the containers, clearing all bind mounts, and creating the temp + transfer directories.

Here is my docker-compose config

version: '3.3'

services:
    r3_db:
        image: postgres:latest
        container_name: r${R3_VERSION:-3.4.2}_db
        restart: always
        environment:
            POSTGRES_PASSWORD: app
            POSTGRES_USER: app
        volumes:
            - ./data:/var/lib/postgresql/data
    r3:
        build:
            context: https://github.com/r3-team/r3_docker.git#main
            args:
                r3_db_host: r3_db
                r3_os_arch: x64
                r3_version: ${R3_VERSION:-3.4.2}
                im_policy: /etc/ImageMagick-6/policy.xml
        container_name: r${R3_VERSION:-3.4.2}_app
        image: "r3/${R3_VERSION:-3.4.2}"
        depends_on:
            - r3_db
        ports:
            - "14000:80"
        restart: always
        volumes:
            - ./data_app:/opt/r3/data
            

Steps to Reproduce Issue

  • Create an empty folder somewhere.
  • Create the docker-compose.yml file.
  • Inside your terminal / command-line run docker compose up

Screenshots

No temp directory.
image

...after creating the temp directory, refreshing localhost in the browser, and retrying the Core Company installation...
image

Additional Info

Operating System: Windows 11 Pro x64 Version 22H2 Build 22621.1992
Container Engine: Docker version 24.0.2, build cb74dfc

Button on edit/create form

Hi,
when I click on new button (i.e. in Country list form in Location application) new form are displayed. In this form there is a "delete" button, but it is greyed. It become red only after saved the new record. I expected that it was an abort button, so if I don't want insert the record I can abort and return on the previous form (in this case the country list form).
So also the "new" button is not useful in case I add a new record. In fact in this case if I insert a new record and press "new" I discard any inserted values.
I think that this buttons must better managed to simplify the user workflow.
For example the form button may be:
"new": in case there are any new values inserted by user a confirmation message must be showed so user may cancel operation
"save": as now, but if I modify a record a confirmation message must be displayed (this may be a configuration parameter)
"Save + new": as now and as suggested for the "save" button
"Delete: as now, but after confirmation must be shown next/previews or last record
"Exit": in this case, after a user confirmation in case of modified values on the form, application return to a predefined form (i.e. list)

In this manner the workflow is more clear. What do you think about?

Bye,
Fabio.

Missing message "bad identifier ..."

Hi,
when create a new application, if name contains uppercase letter appear a this pop up
J5Xr7qmwvH

Message are not translated in Italian language, but I can't find it in "it_it" file. Such message isn't into en_en file also. I think it is hard coded in the application.

May you add in message files?
Thanks,
Fabio.

How to conditional input based on field value

Hi,
I've a this case:

  • table_A: field_A (n:1 -> table_B, not null), field_B (text, null), field_C (text, not null)
  • table_B: field_A (text, not null)

Table_B is a list of values: ["value_A", "value_B", "value_C", "value_D"]

Now, depending to table_A.field_A value I need:

  • if value is "value_A" then table_A.field_B is not enabled and tables_A.field_C is enabled
  • if value is "value_B" then table_A.field_B and tables_A.field_C are enabled
  • if value is "value_C" or "value_D" then table_A.field_B is enabled and tables_A.field_C is not enabled and table_A.field_C take table_A.field_B value.

How can I do it?

Thanks,
Fabio.

Build REI3 ./r3 -run LINUX:failed to start embedded database, embedded database is only supported on Windows

  1. Install the latest version of Golang.
  2. Go into the source code directory (where r3.go is located) and execute: go build -ldflags "-X main.appVersion={YOUR_APP_VERSION}".
    • Replace {YOUR_APP_VERSION} with the version of the extracted source code. Example: go build -ldflags "-X main.appVersion=2.5.1.2980"
    • You can change the build version anytime. If you want to upgrade the major/minor version numbers however, you need to deal with upgrading the REI3 database (see db/upgrade/upgrade.go).
    • By setting the environment parameter GOOS, you can cross-compile for other systems (GOOS=windows, GOOS=linux, ...).

I built it as described above and ran it under linux, prompting the following error?
Does anyone know how to solve this problem?

./r3 -run
failed to start embedded database, embedded database is only supported on Windows
图片

Filter criteria and column name do not match when setting a column name for the table

As you see e.g. in the ticket app, the column name is "Erzeugt von", but the filter criteria is "Anzeigename", "Durchgeführte Operationen" is "Anmerkung Änderungsgrund", which is confusing for the user.

Is your app builds on another app, e.g. the organization app, you also don't have control over over the attribute name to change it at the source.

grafik

No accès to web interface

Hi Gents,
I am working on your piece of software to look if it could fit our needs (kind of tag generator shared).

I tried to install it on a fresh Debian with Postgresql in local. (Debian 11 fresh install , no firewall, no specific installation as far as I could tell)

Connection to the database seems to the okay (no error) on both the ./r3 -run nor on the log of the database, however I can not connect to the web interface.

I track down the problem to :

failed to register listener for HTTP server, listen tcp 0.0.0.0:8080: bind: address already in use

I try the port 80, 443 and 8080 (none of them is used) :

ei01:~# netstat -antu
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address           Foreign Address         State      
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN     
tcp        0      0 127.0.0.1:5432          0.0.0.0:*               LISTEN     
tcp        0      0 127.0.0.1:25            0.0.0.0:*               LISTEN     
tcp        0      0 127.0.0.1:57452         127.0.0.1:5432          ESTABLISHED
tcp        0      0 127.0.0.1:57806         127.0.0.1:5432          ESTABLISHED
tcp        0      0 127.0.0.1:5432          127.0.0.1:57806         ESTABLISHED
tcp        0      0 10.0.0.137:53304        199.232.178.132:80      TIME_WAIT  
tcp        0      0 127.0.0.1:57832         127.0.0.1:5432          ESTABLISHED
tcp        0      0 127.0.0.1:5432          127.0.0.1:57474         ESTABLISHED
tcp        0      0 127.0.0.1:5432          127.0.0.1:57832         ESTABLISHED
tcp        0      0 127.0.0.1:5432          127.0.0.1:57452         ESTABLISHED
tcp        0      0 127.0.0.1:57474         127.0.0.1:5432          ESTABLISHED
tcp        0      0 127.0.0.1:57830         127.0.0.1:5432          ESTABLISHED
tcp        0      0 127.0.0.1:5432          127.0.0.1:57830         ESTABLISHED
tcp6       0      0 :::8080                 :::*                    LISTEN     
tcp6       0      0 :::22                   :::*                    LISTEN     
tcp6       0      0 ::1:5432                :::*                    LISTEN     
tcp6       0      0 ::1:25                  :::*                    LISTEN     
udp6       0      0 ::1:55495               ::1:55495               ESTABLISHED 

(r3 is on 8080)

While I am writing this email, I just notice the IPV6 ...

I disable fully the IPV6 stack and I got the
failed to register listener for HTTP server, listen tcp 0.0.0.0:8080: bind: address already in use

I changed to 8088 (rebooted as well)

At start, the service is not working :

  • r3.service - Provides the REI3 platform components
    Loaded: loaded (/etc/systemd/system/r3.service; enabled; vendor preset: enabled)
    Active: inactive (dead) since Sat 2021-10-23 20:10:26 UTC; 8s ago
    Process: 83 ExecStart=/root/r3 (code=exited, status=0/SUCCESS)
    Main PID: 83 (code=exited, status=0/SUCCESS)

Oct 23 20:08:23 proxcluster-BMS-ei01 systemd[1]: Started Provides the REI3 platform components.
Oct 23 20:08:23 proxcluster-BMS-ei01 rei3[83]: Starting service
Oct 23 20:08:24 proxcluster-BMS-ei01 rei3[83]: failed to register listener for HTTP server, liste>
Oct 23 20:10:26 proxcluster-BMS-ei01 systemd[1]: Stopping Provides the REI3 platform components...
Oct 23 20:10:26 proxcluster-BMS-ei01 systemd[1]: r3.service: Succeeded.
Oct 23 20:10:26 proxcluster-BMS-ei01 systemd[1]: Stopped Provides the REI3 platform components.

A restart bring :

systemctl status r3.service

  • r3.service - Provides the REI3 platform components
    Loaded: loaded (/etc/systemd/system/r3.service; enabled; vendor preset: enabled)
    Active: active (running) since Sat 2021-10-23 20:10:51 UTC; 21s ago
    Main PID: 363 (r3)
    Tasks: 7 (limit: 9360)
    Memory: 2.4M
    CGroup: /system.slice/r3.service
    `-363 /root/r3

Oct 23 20:10:51 proxcluster-BMS-ei01 systemd[1]: Started Provides the REI3 platform components.
Oct 23 20:10:51 proxcluster-BMS-ei01 rei3[363]: Starting service

Again IPV6 :

netstat -antu
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address Foreign Address State
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:5432 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:5432 127.0.0.1:59694 ESTABLISHED
tcp 0 0 127.0.0.1:5432 127.0.0.1:59490 TIME_WAIT
tcp 0 0 127.0.0.1:59716 127.0.0.1:5432 ESTABLISHED
tcp 0 0 127.0.0.1:59694 127.0.0.1:5432 ESTABLISHED
tcp 0 0 127.0.0.1:5432 127.0.0.1:59472 TIME_WAIT
tcp 0 0 127.0.0.1:5432 127.0.0.1:59716 ESTABLISHED
tcp6 0 0 :::22 :::* LISTEN
tcp6 0 0 :::8088 :::* LISTEN
udp 0 0 127.0.0.1:40567 127.0.0.1:40567 ESTABLISHED

// UPDATE //

I set the ip address in the config.json and it starts working !!

Sorry for the noice. I leave it in case it can be helpful for anybody.

feature request: custom validate function

Hello,
I need an custom form filead validation JavaScript function.

It could be, for example, done by

  1. adding an "Validate with function" item in the Form Filed Settings. The function would return true/false.
    or
  2. in a "Function on value change", adding a new option "write error message" in Function -> Placeholdes Settings -> Form data fields.

I vote for (2), because it can also set the error message (Althought, the case (1) can also set the error message e.g. throwing an error).

It would also be great if the Form State Condition had an "fileds is invalid" option. So, for example, an button would be disabled if a field is invalid.

broken form builder filed data query in v3.2

When add an "[1:n]" filed in form builder, then in column selector is a wrong relation.

How to reproduce:
Open "Assets IT" in builder -> Forms -> "smartphone" -> remove F24 ("[1:n] simcard.installed_in_smartphone") -> add the "[1:n] simcard.installed_in_smartphone" filed back inside the F23 container -> try to add an column, expected columns from "simcard" relation, but there are only columns from "smartphone" relations.

It works in REI3v3.1.3.

Postgres with Secure Connection

Hi,

I find Rei3 very good so far, however I would like to connect to a PostgresSQL via SSL connection. Currently, however, it seems that sslmode=disabled is hard coded. See code snippet from db/db.go:
conString := fmt.Sprintf("postgres://%s:%s@%s:%d/%s?sslmode=disable&connect_timeout=5", config.User, url.QueryEscape(config.Pass), config.Host, config.Port, config.Name)

It would be great if you could enable SSL mode and specify a corresponding tls config in config.json if necessary.

All the best
Martin

Builder: New attribute form bug

Hi,
there is an error in the New attribute form: when the value type is changed from Text to Number, Max. characters value stays set and saves even when Number (whole or decimal) Value type has in its form no option to set Max. characters value.

Steps to replicate this bug (REI3 3.4.1 and 3.4):

  1. Create a new Relation.
  2. Add a new attribute to Relation.
  3. Set Max. characters value to some number, for example, 111.
  4. Change Value type from Text (default) to Number.
  5. Add an attribute name and save it.
  6. This new number attribute has Max. length/Size set to 111 and this value cannot be changed.

Maybe there are some other situations where this bug occurs, so far I have tested only this case.

Regards,
Patrik L.

Versione 2.5.1 don't start

Hi,
I downloaded version 2.5.1 on Windows and launched start_portable.cmd but I get this error:
c8Mi8R3P4n

Thanks,
Fabio.

Some CRUD form generator

HI,
I find REI3 a very interesting project, very flexible open-source low-code platform. I think to accelerate application production some sort of CRUD base forms generator (list, record edit) is useful to create a first step of application prototype. After, developer may create any more sophisticated form from that.

What do you think?

Warm regards,
Fabio.

missing filed(s) in frontend function / Placeholders Form data fields selector

I have two (or more) Relations with an attribute type "N:1" related to another Relation. These attributes have the same name. I have also a Form related to this another Relation. The form contains all "1:N" fields. The form has assigned a Frontend function. I can see only one "N:1" filed in the function placeholders form data fileds selector . If I rename the "N:1" attributes in Relations to different names, then all fileds will be in the fileds selector.

Tested in v3.1.3, v3.2.5 and v3.3.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.