Skip to content

Instantly share code, notes, and snippets.

@capeterson
Created September 25, 2011 22:34
Show Gist options
  • Save capeterson/1241262 to your computer and use it in GitHub Desktop.
Save capeterson/1241262 to your computer and use it in GitHub Desktop.
Tag Upload Controller
public with sharing class TagDemoController {
Public ApexPages.StandardController sc {get; set;}
public DocumentTag documentSelector {get; set;}
public TagDemoController(ApexPages.StandardController sc){
this.sc = sc;
documentSelector = new DocumentTag(); //Initialize our tag to avoid a null pointer
}
public PageReference save(){
sc.getRecord().put('someIdField__c',documentSelector.itemId);
return sc.save();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment