jcmoraisjr / press-sdk Goto Github PK
View Code? Open in Web Editor NEWPressObjects SDK is MVP and OPF frameworks for desktop applications
License: Other
PressObjects SDK is MVP and OPF frameworks for desktop applications
License: Other
Converted from SourceForge issue 1583754, submitted by jcmoraisjr
If a business class doesn't implement
InternalMetadataStr, the ClassMetadata method will
duplicate the parent metadata whenever the method is
called, because the correct metadata instance will
never be found.
Converted from SourceForge issue 2843950, submitted by joaolevada
Translation of MVP wiki article to Brazilian Portuguese.
Tradução do artigo sobre MVP, do Wiki, para português brasileiro.
Johnny, há um pequeno problema quando se usa o caractere "(" para título das colunas do grid. O Press se atrapalha e acaba colocando aspas no começo da string que deveria ser usada como DisplayName e corta a string na posição do caractere ")".
Este não é um problema grave, dá pra ser tranquilamente contornado. Apenas abri esta issue pra deixar registrado.
Converted from SourceForge issue 2062002, submitted by webcss
PressMessages translated into German. You're welcome! ;-)
Converted from SourceForge issue 1583749, submitted by jcmoraisjr
FastReport, by default, saves user-defined variables
and the FR broker is re-creating such variables
without removing, or at least verifying if the
variables exist.
Converted from SourceForge issue 2359690, submitted by jcmoraisjr
BulkRetrieve doesn't retrieve unloaded attributes (lazy loading) of proxies with an instance. Eg:
Session.BulkRetrieve(ProxyList, 0, Count, 'attr')
instances are skipped, because of that it doesn't retrieve the 'attr' field of instantiated objects.
Converted from SourceForge issue 2057241, submitted by webcss
Is it possible (if not already implemented) to set default values based on other values, e.g.
setting an orderitem's price based on the product choosen?
(sorry, cannot reach either of the mailing lists, mail is returned saying list not active)
Converted from SourceForge issue 2099874, submitted by webcss
Sorry for still using SF Tracker over mailinglists, but this postmaster thingie won't work ;)
Is it possible to access Objects involved in the MVP in a direct manner, thus I can formulate a complex query by code or manipulate items by code in an easy way and all this is reflected via MVP?
Converted from SourceForge issue 2359644, submitted by jcmoraisjr
Create a data packet object which holds persistent data of a business object.
Starts with object retrieving or storage of a non persistent object (against a session) and finishes when the object is destroyed (notification event? direct event?)
A data packet is a session object. TPressSessionPacket or TPressSessionObject are candidates to the name of the class.
Stores the persistent id and update count properties.
Stores the state of the object. The data packet need to know if the object wasn't changed, or if the change is relative or not.
An object that has a data packet object is a persistent one, otherwise (an object without a data packet) means the object wasn't persisted. A session is able to query the persistence state of an object.
The data packet also need to listen proxies and proxylists in order to instantiate class/id, or bulkretrieve on demand. When assigning a reference to a proxy, the session need to make a data packet to listen, or listen itself the proxy events in order to instantiate object(s) when necessary.
Remove static public procedures, IPressSession interface, TPressObject.IsUpdated property, as well as PersistentId and UpdateCount params.
InternalStore/Refresh/Dispose need to be refactored. An option is an interface that a BO implements in order to be notified of such events. Another option is use notification.
Converted from SourceForge issue 2803619, submitted by joaolevada
Translation of the article Metadata from english to portuguese-brazil.
Olá João, acho que encontrei um pequeno bug no PressObjects.
Para reproduzir a condição do problema, é fácil.
Basta criar uma classe, com pelo menos 1 atributo TPressCurrency e estar usando o PostgreSQL como servidor de banco de dados.
Inserir um registro novo e ao salvar, esta mensagem de erro aparece:
Preparation of query failed. (PostgreSQL: ERROR: column "cost" is of type numeric but expression is of type money
LINE 1: ...money,int,bigint) as update TEquipment set Cost = $1, Update...
^
HINT: You will need to rewrite or cast the expression.
).
Creio que seja um problema do framework, pois alterando o tipo do atributo pra TPressDouble, o problema sumiu.
Entretanto, ainda sou novato no PostgreSQL e não sei se falta configurar algum parâmetro que envolva campos numéricos usados para valores monetários.
Converted from SourceForge issue 2388643, submitted by jcmoraisjr
The order of the items of a selection is, currently, determined by the order the items was selected, instead of the order of the items in the container.
Converted from SourceForge issue 2815245, submitted by joaolevada
When I double click, to edit an item, on a TStringGrid, the edit form is called twice.
Converted from SourceForge issue 2810482, submitted by joaolevada
Translation of article Persistence from English to Portuguese.
Tradução do artigo Persistence do Inglês para o Português.
Converted from SourceForge issue 2073044, submitted by webcss
Hi, I'm trying to assign a command to a detailgrid's context menu but I cannot figure out how to accomplish this task. Sourcecode attached.
Converted from SourceForge issue 1519345, submitted by jcmoraisjr
Notifications raises AV exception after unassign
duplicated events. The
TPressNotificationList.RemoveNotification remove only
the first occurence, resulting some invalid pointers.
Converted from SourceForge issue 1523220, submitted by jcmoraisjr
An AV is raised whenever the framework look for a
Command instance, and there is at least one nil
pointer into de Command list.
Checking if the pointer is nil will fix this issue.
Converted from SourceForge issue 2052915, submitted by webcss
Using either GUIDs or DB-Generators will cause an exception on foreign key references for newly added Objects when they contain a TPressPart Attribute.
Solution: generate ID from bottom up, e.g. for a Person with an Address Part:
Generate the Persons ID prior to the Address ID
Converted from SourceForge issue 1527511, submitted by jcmoraisjr
Whenever an invalid Proxy is assigned to a ProxyList,
eg, a Proxy referencing a class that isn't allowed to
that List, the framework raises an AV due to an object
destroyed inside the ProxyList notification.
Simply removing the try/except block solves the issue,
but might cause memory leakage.
Converted from SourceForge issue 3056022, submitted by joaolevada
Hello Morais.
I saw you've changed PressMessages.inc to fix charset issues with FPC, calling the PressEncodeString function.
That looks ok. But it's missing an update on resource string files. They're still on CP1252 codepage, and that's end on corrupted strings after the PressEncodeString function.
Can you verify this?
I've personally checked the PressMessages_ptbr.inc file.
Let me know, if I can help somehow.
Converted from SourceForge issue 3062098, submitted by joaolevada
Translation of Business classes article (http://wiki.pressobjects.org/Business_classes) to Brazilian Portuguese
Converted from SourceForge issue 3601245, submitted by None
Hello,
please find attached modified code in order to add :
Hope this could be included in trunk
Regards
Clinique
Converted from SourceForge issue 2805447, submitted by joaolevada
Translation of article Configuration file from English to Brazilian Portuguese.
Tradu\u00e7\u00e3o do artigo "Configuration file" de Ingl\u00eas para portugu\u00eas do Brasil.
Converted from SourceForge issue 1583538, submitted by jcmoraisjr
When a notification causes a notifier destruction the
next notifier isn't called, because after it's
destruction, the "next" will be the "current" item:
with CurrentItem.Notifiers.CreateIterator do
try
BeforeFirstItem;
// 2nd - skipping the current and not processed
while NextItem do
// 1st - removing the current notifier
CurrentItem.ProcessEvent(AEvent);
finally
Free;
end;
Converted from SourceForge issue 1523223, submitted by jcmoraisjr
DateTime attribute present an invalid date if the date
part of a DateTime isn't defined.
Converted from SourceForge issue 2073074, submitted by webcss
Shortcuts musst be localized as well, e.g.
on an english system PressWidgets.Short('Ctrl+Ins') is corresponding to PressWidgets('Strg+Einf') on a german system.
Solution: move Shortcuts consts to messages unit.
Converted from SourceForge issue 2073049, submitted by webcss
...not solely to forms.
Converted from SourceForge issue 2052913, submitted by webcss
Custom Attributes are not accepted by Metadata as it is described in the WIKI.
E.g. assuming a CustomAttribute TPressPercentageValue
'Discount: TPressPercentageValue;' won't work.
Converted from SourceForge issue 2801417, submitted by jcmoraisjr
Translation of "Projeto Agenda" articles from ptbr to english.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.