MediaWiki:DRN-wizard.js: Difference between revisions
Content deleted Content added
add |
|||
Line 17:
//Involved users
//Previous forums
Line 31:
this.drawTitleInput = function() {
//Appends to $("#drwContent1")
$("#drwContent1").append("<h3>Location of dispute</h3>");
$("#drwContent1").append("<p>What is the ___location of this dispute? If there are multiple forums, separate them with commas.</p>");
var inputbox = $( document.createElement('input') );
inputbox.attr({
type: "text",
name: "article_title",
value: this.article_title
});
inputbox.change( function() { gDRW.article_title = this.value; } );
$("#drwContent1").append( inputbox );
}
Line 57 ⟶ 58:
rows: 6,
cols: 60,
maxlength: 2000
});
desc.text( this.dispute_description );
$("#drwContent1").append( desc );
Line 68 ⟶ 70:
}
// Involved users
this.drawUserInput = function() {
//Appends to $("#drwContent1")
$("#drwContent1").append("<h3>Users involved</h3>");
$("#drwContent1").append("<p>Who else is involved in the dispute? Enter them into the below box, without the User:, separated by commas: e.g. Example, Example2. (Please remember to notify them of this discussion)</p>");
var inputbox = $( document.createElement('input') );
inputbox.attr({
type: "text",
name: "involved_users",
value: this.involved_users
});
inputbox.change( function() { gDRW.involved_users = this.value; } );
$("#drwContent1").append( inputbox );
}
// Draw previous forums
this.drawPreviousInput = function() {
//Appends to $("#drwContent1")
$("#drwContent1").append("<h3>Resolving the dispute </h3>");
$("#drwContent1").append("<p>What other steps, if any, have you tried to resolve this dispute?</p>");
var desc = $( document.createElement('textarea') );
desc.attr({
rows: 3,
cols: 60,
maxlength: 500
});
desc.text( this.previous_forums );
$("#drwContent1").append( desc );
Line 109 ⟶ 112:
}
this.drawOutcomeInput = function() {
//Appends to $("#drwContent1")
$("#drwContent1").append("<p>How do you think we can help resolve the dispute?</p>");
var desc = $( document.createElement('textarea') );
desc.attr({
rows: 5,
cols: 60,
maxlength: 500
});
desc.text( this.desired_outcome );
$("#drwContent1").append( desc );
$("#drwContent1").append( $("<p id='ocCount'>"+this.desired_outcome.length+"/500</p>") );
}
Line 159 ⟶ 162:
}
// Generate a WikiText string, representing the report.
// Returns a string of wikitext
this.getWikitextReport = function() {
Line 439 ⟶ 442:
}
▲ gDRW.dispute_description = textbox.value;
▲ gDRW.previous_forums = textbox.value;
▲ gDRW.desired_outcome = textbox.value;
▲ $("#taCount").text(""+textbox.value.length+" / 2000");
▲ $("#pcCount").text(""+textbox.value.length+" / 500");
▲ $("#ocCount").text(""+textbox.value.length+" / 500");
function updateLink( box ) {
gDRW.forum_links[box.name] = box.value;
|