public override void WriteXml(APIWriter w) { if (!Label.HasValue()) { Label = "Header"; } w.AddCdata(Type, Label); }
public override void WriteXml(APIWriter w) { if (!Label.HasValue()) { Label = "Instruction"; } w.AddCdata(Type, Label); }
public void WriteXmlMessages(XmlWriter writer, Messages messages) { var w = new APIWriter(writer); w.Start("Messages"); w.Attr("id", OrgId); w.AddComment($"{Util.UserPeopleId} {Util.Now:g}"); if (messages.Confirmation) { w.Start("Confirmation") .Add("Subject", Subject) .AddCdata("Body", Body) .End(); } if (messages.Reminder) { w.Start("Reminder") .Add("Subject", ReminderSubject) .AddCdata("Body", ReminderBody) .End(); } if (messages.Support) { w.Start("SupportEmail") .Add("Subject", SupportSubject) .AddCdata("Body", SupportBody) .End(); } if (messages.Support) { w.Start("SenderEmail") .Add("Subject", SenderSubject) .AddCdata("Body", SenderBody) .End(); } w.StartPending("Instructions"); if (messages.Login) { w.AddCdata("Login", InstructionLogin); } if (messages.Select) { w.AddCdata("Select", InstructionSelect); } if (messages.Find) { w.AddCdata("Find", InstructionFind); } if (messages.Options) { w.AddCdata("Options", InstructionOptions); } if (messages.Special) { w.AddCdata("Special", InstructionSpecial); } if (messages.Submit) { w.AddCdata("Submit", InstructionSubmit); } if (messages.Sorry) { w.AddCdata("Sorry", InstructionSorry); } w.EndPending(); w.End(); }