| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162 |
- using InABox.Configuration;
- using InABox.Core;
- using System;
- using System.Collections.Generic;
- using System.Text;
- namespace Comal.Classes
- {
- [Caption("Staging Panel Settings")]
- public class StagingPanellSettings : BaseObject, IGlobalConfigurationSettings
- {
- [Caption("PDF Markup Program Pathway", IncludePath = false)]
- [FileNameEditor]
- [EditorSequence(1)]
- public string MarkupPathway { get; set; } = "";
- [FolderEditor(Environment.SpecialFolder.CommonDocuments)]
- [EditorSequence(2)]
- public string SetoutsFolder { get; set; } = "";
- [Comment("Maximum Document Size (MB)")]
- [IntegerEditor(Caption = "Maximum Document Size (MB)", ToolTip = "The user will be warned when uploading documents which are larger than this size in megabytes. Set to zero for no maximum.")]
- [EditorSequence(3)]
- public int MaximumDocumentSize { get; set; } = 0;
- [ScriptEditor]
- [EditorSequence(4)]
- public string? Script { get; set; }
- [Comment("Variable name for the EmbeddedImage document field on StagingSetout forms")]
- [EditorSequence(5)]
- public string FormVariable { get; set; } = "";
- private class DefaultFormLookup : LookupDefinitionGenerator<DigitalForm, StagingPanellSettings>
- {
- public override Filter<DigitalForm>? DefineFilter(StagingPanellSettings[] items)
- {
- return Filter<DigitalForm>.Where(x => x.AppliesTo).IsEqualTo(nameof(StagingSetout));
- }
- }
- [Comment("Default form to be used for requesting site measurements")]
- [EditorSequence(6)]
- [LookupDefinition(typeof(DefaultFormLookup))]
- public DigitalFormLink DefaultForm { get; set; }
- public static string DefaultScript()
- {
- return @"
- using PRSDesktop;
- using InABox.Core;
- using System.Collections.Generic;
- public class Module
- {
- /*public void CustomiseSetouts(CustomiseSetoutsArgs args)
- {
- // Perform customisation on the setouts when they are added to the 'Staged Documents' grid.
- }*/
- }";
- }
- }
- }
|