Skip to content

Commit 56c54bb

Browse files
authored
Merge pull request #25 from Scippy/master
Added the Max Total MB File Upload Limit.
2 parents b6525e4 + c1f5330 commit 56c54bb

File tree

9 files changed

+494
-361
lines changed

9 files changed

+494
-361
lines changed

App_LocalResources/EditLayoutSettings.ascx.resx

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,10 +112,10 @@
112112
<value>2.0</value>
113113
</resheader>
114114
<resheader name="reader">
115-
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
115+
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
116116
</resheader>
117117
<resheader name="writer">
118-
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
118+
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
119119
</resheader>
120120
<data name="Main.Text" xml:space="preserve">
121121
<value>Main</value>
@@ -1512,4 +1512,13 @@
15121512
<data name="plLayoutTypeTypes.Text" xml:space="preserve">
15131513
<value>Layout Type</value>
15141514
</data>
1515+
<data name="plMaxUploadLimit.Help" xml:space="preserve">
1516+
<value>Set the total max space reserved to File Upload Custom Fields (value expressed in MB)</value>
1517+
</data>
1518+
<data name="plMaxUploadLimit.Text" xml:space="preserve">
1519+
<value>Max Total File Upload Limit MB</value>
1520+
</data>
1521+
<data name="valMaxUploadLimitIsMB.ErrorMessage" xml:space="preserve">
1522+
<value>&lt;br&gt;The value is required in MB</value>
1523+
</data>
15151524
</root>

EditLayoutSettings.ascx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1114,6 +1114,16 @@
11141114
<asp:CheckBox ID="chkAgentDropdown" Runat="server" />
11151115
</td>
11161116
</tr>
1117+
<tr>
1118+
<td width="25"><img height="1" src='<%= Page.ResolveUrl("~/Images/Spacer.gif") %>' width=25></td>
1119+
<td class="SubHead" width="150"><dnn:label id="plMaxUploadLimit" runat="server" controlname="txtMaxUploadLimit" suffix=":"></dnn:label></td>
1120+
<td valign="bottom">
1121+
<asp:TextBox ID="txtMaxUploadLimit" runat="server" CssClass="NormalTextBox" />
1122+
<asp:CompareValidator ID="valMaxUploadLimitIsMB" Runat="server" ControlToValidate="txtMaxUploadLimit"
1123+
Display="Dynamic" ResourceKey="valMaxUploadLimitIsMB.ErrorMessage" CssClass="NormalRed" Operator="DataTypeCheck"
1124+
Type="Integer" />
1125+
</td>
1126+
</tr>
11171127
</table>
11181128
<br>
11191129
<dnn:sectionhead id="dshMapSettings" cssclass="Head" runat="server" text="Map Settings" section="tblMap"

EditLayoutSettings.ascx.designer.vb

Lines changed: 30 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

EditLayoutSettings.ascx.vb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -633,6 +633,7 @@ Namespace Ventrian.PropertyAgent
633633
End If
634634
chkProtectXSS.Checked = Me.PropertySettings.ProtectXSS
635635
chkAgentDropdown.Checked = Me.PropertySettings.AgentDropdownDefault
636+
txtMaxUploadLimit.Text = Me.PropertySettings.MaxUploadLimit
636637

637638
If Not (lstContactdestination.Items.FindByValue(Me.PropertySettings.ContactDestination.ToString()) Is Nothing) Then
638639
lstContactdestination.SelectedValue = Me.PropertySettings.ContactDestination.ToString()
@@ -1024,6 +1025,7 @@ Namespace Ventrian.PropertyAgent
10241025
objModules.UpdateModuleSetting(ModuleId, Constants.UPLOAD_PLACEMENT_SETTING, lstUploadPlacement.SelectedValue)
10251026
objModules.UpdateModuleSetting(ModuleId, Constants.PROTECT_XSS_SETTING, chkProtectXSS.Checked.ToString())
10261027
objModules.UpdateModuleSetting(ModuleId, Constants.AGENT_DROPDOWN_SETTING, chkAgentDropdown.Checked.ToString())
1028+
objModules.UpdateModuleSetting(ModuleId, Constants.MAX_UPLOAD_LIMIT_SETTING, txtMaxUploadLimit.Text.ToString())
10271029

10281030
objModules.UpdateModuleSetting(ModuleId, Constants.MAP_ENABLE_SETTING, chkEnableMaps.Checked.ToString())
10291031
objModules.UpdateModuleSetting(ModuleId, Constants.MAP_KEY_SETTING, txtMapKey.Text)

0 commit comments

Comments
 (0)