Final upload, should be running now

Took 7 minutes
This commit is contained in:
Tobias Hopp 2020-10-03 13:30:13 +02:00
parent 18d672d057
commit a1b0f7d681
4 changed files with 25 additions and 10 deletions

20
.idea/workspace.xml generated
View File

@ -21,8 +21,9 @@
<component name="ChangeListManager">
<list default="true" id="fc13552d-b118-4828-b78f-fc8714e0cfdc" name="Default Changelist" comment="">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/config.inc.php" beforeDir="false" afterPath="$PROJECT_DIR$/config.inc.php" afterDir="false" />
<change beforePath="$PROJECT_DIR$/templates/faq.tmpl.html" beforeDir="false" afterPath="$PROJECT_DIR$/templates/faq.tmpl.html" afterDir="false" />
<change beforePath="$PROJECT_DIR$/vendor/js/faq.js" beforeDir="false" afterPath="$PROJECT_DIR$/vendor/js/faq.js" afterDir="false" />
<change beforePath="$PROJECT_DIR$/vendor/js/sd" beforeDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
@ -33,7 +34,7 @@
<execution />
</component>
<component name="DarkyenusTimeTracker">
<option name="totalTimeSeconds" value="93665" />
<option name="totalTimeSeconds" value="93926" />
<option name="gitIntegration" value="true" />
<option name="naggedAbout" value="1" />
</component>
@ -77,7 +78,7 @@
<option name="number" value="Default" />
<option name="presentableId" value="Default" />
<updated>1601618466935</updated>
<workItem from="1601618467981" duration="30619000" />
<workItem from="1601618467981" duration="30879000" />
</task>
<task id="LOCAL-00001" summary="Initial commit">
<created>1601618764031</created>
@ -114,7 +115,14 @@
<option name="project" value="LOCAL" />
<updated>1601723546090</updated>
</task>
<option name="localTasksCounter" value="6" />
<task id="LOCAL-00006" summary="Fixing a bug where the answer is posted directly">
<created>1601724201344</created>
<option name="number" value="00006" />
<option name="presentableId" value="LOCAL-00006" />
<option name="project" value="LOCAL" />
<updated>1601724201344</updated>
</task>
<option name="localTasksCounter" value="7" />
<servers />
</component>
<component name="TypeScriptGeneratedFilesManager">
@ -176,10 +184,10 @@
<screen x="0" y="34" width="1920" height="1046" />
</state>
<state x="441" y="192" width="1037" height="736" key="SettingsEditor/0.34.1920.1046@0.34.1920.1046" timestamp="1601632853044" />
<state x="555" y="292" width="800" height="535" key="Vcs.Push.Dialog.v2" timestamp="1601723547161">
<state x="555" y="292" width="800" height="535" key="Vcs.Push.Dialog.v2" timestamp="1601724202405">
<screen x="0" y="34" width="1920" height="1046" />
</state>
<state x="555" y="292" width="800" height="535" key="Vcs.Push.Dialog.v2/0.34.1920.1046@0.34.1920.1046" timestamp="1601723547161" />
<state x="555" y="292" width="800" height="535" key="Vcs.Push.Dialog.v2/0.34.1920.1046@0.34.1920.1046" timestamp="1601724202405" />
<state x="809" y="122" width="639" height="876" key="com.intellij.database.view.ui.AbstractDbRefactoringDialog" timestamp="1601632983240">
<screen x="0" y="34" width="1920" height="1046" />
</state>

View File

@ -7,4 +7,4 @@ define( 'MYSQL_PASS', 'RnKVJHcUBIIu1XM2' );
define( 'MYSQL_DB', 'online-faq' );
define( 'CODE_LENGTH', 4 );
define( 'WASTED_TIME', '7hrs and 26min' );
define( 'WASTED_TIME', '26hrs and 3mins' );

View File

@ -69,7 +69,7 @@
<span class="text-danger" id="askErrorMsg"></span>
<div class="form-group">
<label for="name" class="col-form-label">Name</label><br>
<input type="text" maxlength="15" id="name">
<input type="text" class="form-control" maxlength="15" id="name">
<br>
<label for="question" class="col-form-label">Question</label>
<textarea name="question" class="form-control" id="question" maxlength="500" rows="4"></textarea>

11
vendor/js/faq.js vendored
View File

@ -144,8 +144,15 @@ function answer()
{
answerErrorMsg.html( '' );
answerModal.modal( 'hide' );
}, function() {
answerErrorMsg.html( 'An error occurred. Please try again later!' );
}, function( result ) {
switch( result.status )
{
case 905:
answerErrorMsg.html( 'You are not allowed to answer questions!' );
break;
default:
answerErrorMsg.html( 'An error occurred. Please try again later!' );
}
});
}