-
ChatterFeed
-
0Best Answers
-
0Likes Received
-
0Likes Given
-
5Questions
-
2Replies
I have a doubt in the activity timeline
How to remove the task from the activity timeline is it possiable to remove those from the activity timeline
Thanks in advance
Thanks in advance
-
- niranjan e
- November 07, 2017
- Like
- 0
- Continue reading or reply
hi i have a doubt in creating a visualforce page
Visual force page for Contact records. The page should display
Contact detail page without the related list,
the related account’s detail view in the same screen
the opportunities to be displayed as a calendar view displayed or categorized as month
how to achive the calander view with the repective opportuninites created on that month ...
Contact detail page without the related list,
the related account’s detail view in the same screen
the opportunities to be displayed as a calendar view displayed or categorized as month
how to achive the calander view with the repective opportuninites created on that month ...
-
- niranjan e
- August 16, 2017
- Like
- 0
- Continue reading or reply
hi need to about test classes and can anyone help me in writing the test class for the below trigger . started writing test classes.. need to know more about it
trigger case4trigger on User (after insert , after update)
{
list<account>acclist = new list<account>();
list<account>templist = new list<account>();
Account acc = new Account();
User u = new User();
for(User u : trigger.new)
{
acclist = [select Id,OwnerId,Owner.leave__c,Type,Owner.DelegatedApproverId from Account where OwnerId =: u.Id];
}
for(Account acc : acclist)
{
if(trigger.IsInsert)
{
if( acc.Owner.leave__c > 90 && acc.Owner.leave__c <180)
{
acc.Type = 'Former Client';
templist.add(acc);
}
system.debug('asdf'+templist);
if(acc.Owner.DelegatedApproverId!= null && acc.Owner.leave__c >180)
{
acc.OwnerId = acc.Owner.DelegatedApproverId ;
templist.add(acc);
}
system.debug('qwerty'+templist);
if(acc.Owner.DelegatedApproverId == null && acc.Owner.leave__c >180)
{
acc.Type = 'deactivated';
templist.add(acc);
}
system.debug('zxcv'+templist);
}
if(trigger.IsUpdate)
{
if( acc.Owner.leave__c > 90 && acc.Owner.leave__c <180)
{
acc.Type = 'Former Client';
templist.add(acc);
}
system.debug('asdf'+templist);
if(acc.Owner.DelegatedApproverId!= null && acc.Owner.leave__c >180)
{
acc.OwnerId = acc.Owner.DelegatedApproverId ;
templist.add(acc);
}
system.debug('qwerty'+templist);
if(acc.Owner.DelegatedApproverId == null && acc.Owner.leave__c >180)
{
acc.Type = 'deactivated';
templist.add(acc);
}
system.debug('zxcv'+templist);
}
}
update templist;
}
{
list<account>acclist = new list<account>();
list<account>templist = new list<account>();
Account acc = new Account();
User u = new User();
for(User u : trigger.new)
{
acclist = [select Id,OwnerId,Owner.leave__c,Type,Owner.DelegatedApproverId from Account where OwnerId =: u.Id];
}
for(Account acc : acclist)
{
if(trigger.IsInsert)
{
if( acc.Owner.leave__c > 90 && acc.Owner.leave__c <180)
{
acc.Type = 'Former Client';
templist.add(acc);
}
system.debug('asdf'+templist);
if(acc.Owner.DelegatedApproverId!= null && acc.Owner.leave__c >180)
{
acc.OwnerId = acc.Owner.DelegatedApproverId ;
templist.add(acc);
}
system.debug('qwerty'+templist);
if(acc.Owner.DelegatedApproverId == null && acc.Owner.leave__c >180)
{
acc.Type = 'deactivated';
templist.add(acc);
}
system.debug('zxcv'+templist);
}
if(trigger.IsUpdate)
{
if( acc.Owner.leave__c > 90 && acc.Owner.leave__c <180)
{
acc.Type = 'Former Client';
templist.add(acc);
}
system.debug('asdf'+templist);
if(acc.Owner.DelegatedApproverId!= null && acc.Owner.leave__c >180)
{
acc.OwnerId = acc.Owner.DelegatedApproverId ;
templist.add(acc);
}
system.debug('qwerty'+templist);
if(acc.Owner.DelegatedApproverId == null && acc.Owner.leave__c >180)
{
acc.Type = 'deactivated';
templist.add(acc);
}
system.debug('zxcv'+templist);
}
}
update templist;
}
-
- niranjan e
- August 10, 2017
- Like
- 0
- Continue reading or reply
hi guys i have doubt can u please clarify,my problem is to dynamically populate value to a picklist and to save the selected value in the database.Here i am getting the value in the picklist but while re·trieveing it in the controller to save it showerror
//component
<aura:attribute name="Companys" type="Object[]"></aura:attribute>
<aura:handler name="init" value="{!this}" action="{!c.doInit}" />
<ui:inputSelect label="Proviences" class="dynamic" aura:id="InputSelectDynamic" value="{!v.Companys}" change="{!c.onSelectChange}"> required="False">
<aura:iteration items="{!v.Companys}" var="levels">
<ui:inputSelectOption text="{!levels.value}" label="{!levels.label}"/>
</aura:iteration>
//controller
doInit : function(component, event, helper) {
var action = component.get("c.getLeadStatus");
var inputsel = component.find("InputSelectDynamic");
var opts=[];
action.setCallback(this, function(a) {
for(var i=0;i< a.getReturnValue().length;i++){
opts.push({"class": "optionClass", label: a.getReturnValue()[i], value: a.getReturnValue()[i]});
}
inputsel.set("v.Companys", opts);
component.set("v.Companys",opts);
});
$A.enqueueAction(action);
},
onSelectChange : function(component, event, helper) {
var selected = component.find("InputSelectDynamic").get("v.Companys");
alert('tt'+ selected); /// here i get ttundefined
}
//Serverside controller
@AuraEnabled
public static List<String> getLeadStatus(){
List<String> options = new List<String>();
Schema.DescribeFieldResult fieldResult = company__c.Province__c.getDescribe();
List<Schema.PicklistEntry> ple = fieldResult.getPicklistValues();
for (Schema.PicklistEntry f: ple) {
options.add(f.getLabel());
}
system.debug('asdf'+options);
return options;}
<aura:attribute name="Companys" type="Object[]"></aura:attribute>
<aura:handler name="init" value="{!this}" action="{!c.doInit}" />
<ui:inputSelect label="Proviences" class="dynamic" aura:id="InputSelectDynamic" value="{!v.Companys}" change="{!c.onSelectChange}"> required="False">
<aura:iteration items="{!v.Companys}" var="levels">
<ui:inputSelectOption text="{!levels.value}" label="{!levels.label}"/>
</aura:iteration>
//controller
doInit : function(component, event, helper) {
var action = component.get("c.getLeadStatus");
var inputsel = component.find("InputSelectDynamic");
var opts=[];
action.setCallback(this, function(a) {
for(var i=0;i< a.getReturnValue().length;i++){
opts.push({"class": "optionClass", label: a.getReturnValue()[i], value: a.getReturnValue()[i]});
}
inputsel.set("v.Companys", opts);
component.set("v.Companys",opts);
});
$A.enqueueAction(action);
},
onSelectChange : function(component, event, helper) {
var selected = component.find("InputSelectDynamic").get("v.Companys");
alert('tt'+ selected); /// here i get ttundefined
}
//Serverside controller
@AuraEnabled
public static List<String> getLeadStatus(){
List<String> options = new List<String>();
Schema.DescribeFieldResult fieldResult = company__c.Province__c.getDescribe();
List<Schema.PicklistEntry> ple = fieldResult.getPicklistValues();
for (Schema.PicklistEntry f: ple) {
options.add(f.getLabel());
}
system.debug('asdf'+options);
return options;}
-
- niranjan e
- August 08, 2017
- Like
- 0
- Continue reading or reply
hi guys i have doubt can u please clarify,my problem is to dynamically populate value to a picklist and to save the selected value in the database.Here i am getting the value in the picklist but while re·trieveing it in the controller to save it showerror
//component
<aura:attribute name="Companys" type="Object[]"></aura:attribute>
<aura:handler name="init" value="{!this}" action="{!c.doInit}" />
<ui:inputSelect label="Proviences" class="dynamic" aura:id="InputSelectDynamic" value="{!v.Companys}" change="{!c.onSelectChange}"> required="False">
<aura:iteration items="{!v.Companys}" var="levels">
<ui:inputSelectOption text="{!levels.value}" label="{!levels.label}"/>
</aura:iteration>
//controller
doInit : function(component, event, helper) {
var action = component.get("c.getLeadStatus");
var inputsel = component.find("InputSelectDynamic");
var opts=[];
action.setCallback(this, function(a) {
for(var i=0;i< a.getReturnValue().length;i++){
opts.push({"class": "optionClass", label: a.getReturnValue()[i], value: a.getReturnValue()[i]});
}
inputsel.set("v.Companys", opts);
component.set("v.Companys",opts);
});
$A.enqueueAction(action);
},
onSelectChange : function(component, event, helper) {
var selected = component.find("InputSelectDynamic").get("v.Companys");
alert('tt'+ selected); /// here i get ttundefined
}
//Serverside controller
@AuraEnabled
public static List<String> getLeadStatus(){
List<String> options = new List<String>();
Schema.DescribeFieldResult fieldResult = company__c.Province__c.getDescribe();
List<Schema.PicklistEntry> ple = fieldResult.getPicklistValues();
for (Schema.PicklistEntry f: ple) {
options.add(f.getLabel());
}
system.debug('asdf'+options);
return options;}
<aura:attribute name="Companys" type="Object[]"></aura:attribute>
<aura:handler name="init" value="{!this}" action="{!c.doInit}" />
<ui:inputSelect label="Proviences" class="dynamic" aura:id="InputSelectDynamic" value="{!v.Companys}" change="{!c.onSelectChange}"> required="False">
<aura:iteration items="{!v.Companys}" var="levels">
<ui:inputSelectOption text="{!levels.value}" label="{!levels.label}"/>
</aura:iteration>
//controller
doInit : function(component, event, helper) {
var action = component.get("c.getLeadStatus");
var inputsel = component.find("InputSelectDynamic");
var opts=[];
action.setCallback(this, function(a) {
for(var i=0;i< a.getReturnValue().length;i++){
opts.push({"class": "optionClass", label: a.getReturnValue()[i], value: a.getReturnValue()[i]});
}
inputsel.set("v.Companys", opts);
component.set("v.Companys",opts);
});
$A.enqueueAction(action);
},
onSelectChange : function(component, event, helper) {
var selected = component.find("InputSelectDynamic").get("v.Companys");
alert('tt'+ selected); /// here i get ttundefined
}
//Serverside controller
@AuraEnabled
public static List<String> getLeadStatus(){
List<String> options = new List<String>();
Schema.DescribeFieldResult fieldResult = company__c.Province__c.getDescribe();
List<Schema.PicklistEntry> ple = fieldResult.getPicklistValues();
for (Schema.PicklistEntry f: ple) {
options.add(f.getLabel());
}
system.debug('asdf'+options);
return options;}
- niranjan e
- August 08, 2017
- Like
- 0
- Continue reading or reply