Jump to content

Structure large project


Recommended Posts

Hello,

I'm looking for some advice.

I have a pretty large project (ERP-application) and several custom solutions made for customers all written in Unigui

All these applications use Firebird as a database.

Now I'm having more and more demand for custom solutions but that would use a large portion of the features that are already present in the ERP-application.

As we are working with Unigui, these are all separate projects.

So I'm trying to find a solution where I could easily reuse parts of the ERP-application in custom projects but also making that if improvements are made on the ERP-side they are also automatically implemented in the custom solutions.

Any ideas concerning structure, ... are more than welcome.

Thank you,

Dominique

Link to post
Share on other sites
30 minutes ago, d.bernaert said:

Hello,

I'm looking for some advice.

I have a pretty large project (ERP-application) and several custom solutions made for customers all written in Unigui

All these applications use Firebird as a database.

Now I'm having more and more demand for custom solutions but that would use a large portion of the features that are already present in the ERP-application.

As we are working with Unigui, these are all separate projects.

So I'm trying to find a solution where I could easily reuse parts of the ERP-application in custom projects but also making that if improvements are made on the ERP-side they are also automatically implemented in the custom solutions.

Any ideas concerning structure, ... are more than welcome.

Thank you,

Dominique

Hello Dominique,

I have one desktop app, one desktop POS app, one unigui server and one Android app.

In all of them I use a lot of dll, my kernel is dll, when I make some changes or new functionality in the desktop application, I transfer all to dll and use them (dll) on desktop POS, unigui server and Android application.

This is done with different designs and functionalities and it all works well.

When a new client comes up with some specifications in her business, I do design and functionality with my own designer and this applies to POS, Android and Web (unigui) without coding only with a designer (global dll features and one design)

I do it this way and it works well.

Many functions are transferred from ERP (Desktop app) to DLL files.

Link to post
Share on other sites

Hi,

Thank you for your reply.

If i understand you correct, you put all the logic in the dll and have different user interfaces for the different platforms that use the kernell.dll?

And with dll, you mean a real dll or rather a package?

Thx,

Dominique

Link to post
Share on other sites
10 hours ago, d.bernaert said:

Hi,

Thank you for your reply.

If i understand you correct, you put all the logic in the dll and have different user interfaces for the different platforms that use the kernell.dll?

And with dll, you mean a real dll or rather a package?

Thx,

Dominique

" .. different user interfaces for the different platforms ..." not only, I also have various user interfaces for desktop POS for example:
1. Design for work in a restaurant
2. Design for work in a car service
3. Design for work in which the program works as the user wants, not as in ERP.

All of designs can be for one platform or for all of them.

Yes, in my case only dll because I want to use them for my other applications.

Could a package be better.

Link to post
Share on other sites
37 minutes ago, irigsoft said:

" .. different user interfaces for the different platforms ..." not only, I also have various user interfaces for desktop POS for example:
1. Design for work in a restaurant
2. Design for work in a car service
3. Design for work in which the program works as the user wants, not as in ERP.

All of that can be for one platform or for all of them.

Yes, in my case only dll because I want to use them for my other applications.

Could a package be better.

 

@irigSoft,

interesting !

So, you are doing like Microsoft Windows concept (build with thousands dll). That's right ?

in this case how can you deal with Unigui dll (isapi) ?

I mean it's not simple to combine multiple unigui dll on one Mainform. Can you explain more...

if you can do it, then the idea is awesome !!!

(we can build big Unigui Project on demand)

Thx.

Link to post
Share on other sites
4 hours ago, Abaksoft said:

 

@irigSoft,

interesting !

So, you are doing like Microsoft Windows concept (build with thousands dll). That's right ?

in this case how can you deal with Unigui dll (isapi) ?

I mean it's not simple to combine multiple unigui dll on one Mainform. Can you explain more...

if you can do it, then the idea is awesome !!!

(we can build big Unigui Project on demand)

Thx.

at this moment only as StandAloneApplication is distributed, no on  iis.

In may case use only 10 dll made be me and some integrated windows dlls

 

i have created one global function on Mainmodule that execute selected function from selected dll, and when some design execute that function other can execute other functions by this dll, that is it

 

as an example:

1. web interface for various queries for the manager

2. a design for services and tasks

3. a design for sales

all this with one unigui application, dll, directory, they do different things but also the same as executing query management request and sales query simultaneously

Link to post
Share on other sites

you have to handle the decoupling of routines well, you can easily share functions in .pas files between several unigui projects, just be careful with references to objects from other forms, pass everything by parameter, including the connection object. the idea of working with dll can even be valid, the problem is that for each dll a new connection to the database will be made.

Link to post
Share on other sites
18 hours ago, picyka said:

If you work with object orientation, where the rules are separate from the forms, you can easily reuse everything.

Yes. At this time, OOP is the Best way.

• Simply dedicate a Main Development Folder where are all your historical Classes (writed a long time ago) well documented (properties /  method).

• For each new Project, PickUp on demand, these Classes, by adding them in your Project.

Example :

A New Project, will contain 

- a loginForm

- a Connection DB

- a Backup/Restore 

With OOP, you will never rewrite all redundant logic. Just declare an object and work...

This will save you hundreds hours !!!

Link to post
Share on other sites
11 minutes ago, Abaksoft said:

Yes. At this time, OOP is the Best way.

• Simply dedicate a Main Development Folder where are all your historical Classes (writed a long time ago) well documented (properties /  method).

• For each new Project, PickUp on demand, these Classes, by adding them in your Project.

Example :

A New Project, will contain 

- a loginForm

- a Connection DB

- a Backup/Restore 

With OOP, you will never rewrite all redundant logic. Just declare an object and work...

This will save you hundreds hours !!!

I have a remark::

I used this method and my first problem was the difference between the components between VCL and unigui.

If I do a runtime column creation function and it is in a pas file (or package), I have to send uniDBGrid not DBGrid as TObject, but creating columns for uniDBGird and creating columns for DBGrid has some differences, so when planning on a pas file with properties and methods we must first know what the differences are between the components for VCL and unigui.

Link to post
Share on other sites
13 minutes ago, irigsoft said:

I used this method and my first problem was the difference between the components between VCL and unigui.

There is a solution for that :  Use Polymorphing technic :  Declare your Methode as Overload :

  public
    function fct_index_Vide(cbo:TUniComboBox):boolean; overload;
    function fct_index_Vide(cbo:TUnimDBLookUpComboBox):boolean; overload;
    function fct_index_Vide(MyDataSet:TIBCQuery):boolean; overload;

    procedure Remplir_cbo_ID_Tr(Champs, MaTable, Classement:string; cbo,cboID:TUniCombobox;
       Contrainte:string; AvecClear:boolean; C:TIBCConnection); overload;
    procedure Remplir_cbo_ID_Tr(Champs, MaTable, Classement:string; cbo,cboID:TUnimCombobox;
       Contrainte:string; AvecClear:boolean; C:TIBCConnection); overload;

 

Link to post
Share on other sites
15 minutes ago, Abaksoft said:

There is a solution for that :  Use Polymorphing technic :  Declare your Methode as Overload :


  public
    function fct_index_Vide(cbo:TUniComboBox):boolean; overload;
    function fct_index_Vide(cbo:TUnimDBLookUpComboBox):boolean; overload;
    function fct_index_Vide(MyDataSet:TIBCQuery):boolean; overload;

    procedure Remplir_cbo_ID_Tr(Champs, MaTable, Classement:string; cbo,cboID:TUniCombobox;
       Contrainte:string; AvecClear:boolean; C:TIBCConnection); overload;
    procedure Remplir_cbo_ID_Tr(Champs, MaTable, Classement:string; cbo,cboID:TUnimCombobox;
       Contrainte:string; AvecClear:boolean; C:TIBCConnection); overload;

 

thanks.

Link to post
Share on other sites

An other way to do things right, is to use Unigui inherited object :

• Prepare some main models, containing virtual, abstract methods, where can be, later, overided by the inherited object.

This works fine, for a CRUD project.

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...