pegros / peg_misc Goto Github PK
View Code? Open in Web Editor NEWSmall package of standalone LWC components for the App Builder, addressing simple Use Cases in a very easy to configure approach.
License: MIT License
Small package of standalone LWC components for the App Builder, addressing simple Use Cases in a very easy to configure approach.
License: MIT License
Is your feature request related to a problem? Please describe.
Using a text custom field to store the id can compromise data integrity if the contentDocument is deleted.
To avoid this, it would be great if we could use the related list relation name instead of a custom field to store the ContentDocumentId
Describe the solution you'd like
We can have parameters on the LWC to store the relatedList relation name and a filter.
Describe alternatives you've considered
// Related list Data Fetch
error;
records;
@wire(getRelatedListRecords, {
parentRecordId: "$recordId",
relatedListId: 'ListEmails',
fields: ['ListEmail.Id'],
where: "{ and: [{ Name: { like: \"Bob%\" }}] }"
}) listInfo({ error, data }) {
console.log('wiredRelated: wired');
if (data) {
this.records = data.records;
this.error = undefined;
} else if (error) {
this.error = error;
this.records = undefined;
}
}
@AuraEnabled(cacheable=true)
public static Id getContentDocumentId(Id sobjectId, String relationName, String fieldName, String title){
String sobjectName = sobjectId.getSobjectType().getDescribe().getName();
String query = 'SELECT Id, (SELECT ' + fieldName + ' FROM ';
query+= relationName + ' WHERE Title LIKE \'' + title + '\') FROM ' + sobjectName + ' WHERE Id=:sobjectId';
SObject sobj = Database.query(query);
List<SObject> sobjList = sobj.getSObjects(relationName);
return objList.get(0).get(fieldName);
}
Additional context
WARNING:
All the related list are not available through the wire service, for example AttachedContentDocuments on Campaign
Describe the bug
When selecting "ActivityHistories" for a Related List, there following error message when component is displayed by a non administrator user.
"There is an implementation restriction on ActivityHistories. When you query this relationship, security evaluation is implemented for users who don't have administrator permissions, and you must specify a LIMIT with a maximum of 500"_
To Reproduce
Steps to reproduce the behavior:
Expected behavior
The KPI should be displayed without error message.
Desktop (please complete the following information):
Describe the bug
Master-Detail relations do not appear in "Related list #" while configuring the component in Lightning App builder. Seems that only related lists are displayed.
To Reproduce
Steps to reproduce the behavior:
0. Having Objet A and Object B, with a Master-Detail relation (A is master of B, field A__r on Object B)
Expected behavior
Related relation "A__r" to appear (like other related lists).
Screenshots
n/a
Desktop (please complete the following information):
Is your feature request related to a problem? Please describe.
Currently, KPIs are generated server side and not automatically updated if the related lists change.
The refresh button may be provided but requires user intervention to trigger KPI updates.
Describe the solution you'd like
LWC framework provides the uiRelatedListApi
wire service which could be leveraged to automatically refresh the KPIs if an update occurs on a related list
(e.g. the getRelatedListCount
wire adapter).
Describe alternatives you've considered
N/A
Additional context
N/A
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.