public DataEditor(umbraco.interfaces.IData Data, Options Configuration) { //load the prevalues savedOptions = Configuration; //ini the savedData object savedData = Data; }
public PrevalueEditor(umbraco.cms.businesslogic.datatype.BaseDataType DataType) { _datatype = DataType; jsonSerializer = new JavaScriptSerializer(); savedOptions = Configuration; }
private void buildControls() { //test for postback, decide to use db or saveBox for rendering if (Page.IsPostBack) { //test for saveBox having a value, default if not if (saveBox.Text != "") { renderingOptions = jsonSerializer.Deserialize<Options>(saveBox.Text); } else { renderingOptions = new Options(); } } else { renderingOptions = savedOptions; } BuildSettingsTable(); }