• Jonathan Swiff
  • NEWBIE
  • 0 Points
  • Member since 2021

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 5
    Replies
I need to apply "width:100%" to "article" element inside "lightning-card"

Nothing seem to work, please help.
 
<template>
    <lightning-card  title="Test" icon-name="action:share_poll" style="display:flex; height: 100%;">

        <lightning-datatable
                key-field="id"
                data={data}
                columns={columns}
                hide-checkbox-column>
        </lightning-datatable>

    </lightning-card>
</template>

​​​

 
I am new to LWC and cant seem to figure out how to open the source code for LWC. Aura can be opened in the dev console but from what i understand this is not possible with LWC.

Is it possible to open a LWC source code from within the org? I have a LWC that was developed by someone else that needs editing. How can I access the source code?
Hey guys,

i am not familar with javascript, but i really like how the chart.js libary looks. To get started i want to create some cool Salesforce Dashboards with chart.js. I have already create a visualforce Page to show a simple bar chart. Now, i am looking for a way to get the controller variable to the javascript function : 
http://www.chartjs.org/docs/latest/

This is the javascript Code: 
var ctx = document.getElementById("myChart").getContext('2d');
var myChart = new Chart(ctx, {
    type: 'bar',
    data: {
        labels: ["M1", "M2", "M3", "M4", "M5", "M6"],
        datasets: [{
            label: '# of Votes',
            data: [12, 19, 3, 5, 2, 3],   
            backgroundColor: [
                'rgba(255, 99, 132, 0.2)',
                'rgba(54, 162, 235, 0.2)',
                'rgba(255, 206, 86, 0.2)',
                'rgba(75, 192, 192, 0.2)',
                'rgba(153, 102, 255, 0.2)',
                'rgba(255, 159, 64, 0.2)'
            ],
            borderColor: [
                'rgba(255,99,132,1)',
                'rgba(54, 162, 235, 1)',
                'rgba(255, 206, 86, 1)',
                'rgba(75, 192, 192, 1)',
                'rgba(153, 102, 255, 1)',
                'rgba(255, 159, 64, 1)'
            ],
            borderWidth: 1
        }]
    },
    options: {
        scales: {
            yAxes: [{
                ticks: {
                    beginAtZero:true
                }
            }]
        }
    }
});
</script>
How can i change the label and dataset with controller variables ? My idea is to create a simple list and transform the list to string. Does this work ? 

Thanks for help guys. I cant find any help for chart.js and visualforce...

Greetings,

Marry





 
Anyone else having trouble connecting to the UpWork group for Salesforce.com? I've tried everything and can't get past the screen to start a dev. org. and submit my application. *sigh*
Hi,
  I need to autopopulate the number datatype field after the record is deleted.
For example,
I have 5 records and their serial numbers are  1,2,3,4 and 5. If i delete the 3rd record , then the serial number of the 4th record should be automatically populated as 3 and 5th records as 4.
How to achieve this delete operation?

My Trigger Code:

trigger RecordSteps on Record__c(before insert,after delete) 
    {
        List<Record__c> cp = new List<Record__c>(); 
        set<id> id = new set<id>();
        List <AggregateResult> requirements = new List<AggregateResult>();  
       if (Trigger.isBefore && Trigger.isInsert)
       { 
        for(Record__c pt:trigger.new)
        {
         requirements=[select Count(Seq__c) from Record__c];
         if(requirements.size() > 0)
         {
         for(AggregateResult ar:requirements)
         {
         pt.Seq__c = Decimal.ValueOf(String.ValueOf(ar.get('expr0')));
          }
      }
      }
}
      if (Trigger.isAfter&& Trigger.isDelete) 
      {
      for(Record__c pt1:trigger.old)
        {
          }
          }   
     }