JavaScript - Создание двух радиогрупп
Я попытался изменить JavaScript ниже. Я хочу создать две радиогруппы. Код ниже работает без второй радиогруппы, начиная с:
// This maps to a Radio Group in the PDF named 'Information'
radioGroup: "Information",
radioButtons: [
// value maps to the 'Choice' of each radio button in the group, description will show on the dialog
{
value: "No Comments",
description: "No Comments"
},
{
value: "Comments As Noted",
description: "Comments As Noted"
},
],
radioErrorMsg: "Please select a Information"
Не могли бы вы помочь?
Спасибо,
var builder = {
// These map to Text Fields in the Stamp
textBoxes: [{
field: "Arch",
description: "Arch:",
default: function() {
return Collab.user;
}
},
{
field: "Mech",
description: "Mech:",
default: function() {
return "";
}
},
{
field: "Struct",
description: "Struct:",
default: function() {
return "";
}
},
{
field: "Elect",
description: "Elect:",
default: function() {
return "";
}
},
{
field: "Civil",
description: "Civil:",
default: function() {
return "";
}
},
{
field: "By",
description: "By:",
default: function() {
return "";
}
},
{
field: "Date",
description: "Date:",
default: function() {
var curDate = new Date();
return (curDate.getMonth() + 1) + "/" + curDate.getDate() + "/" + curDate.getFullYear();
}
},
{
field: "Countersigned By",
description: "Countersigned By:",
default: function() {
return "";
}
},
{
field: "Countersigned Date",
description: "Countersigned Date:",
default: function() {
var curDate = new Date();
return (curDate.getMonth() + 1) + "/" + curDate.getDate() + "/" + curDate.getFullYear();
}
},
{
field: "Spec. Section",
description: "Spec. Section:",
default: function() {
return "";
}
},
{
field: "File No.",
description: "File No.:",
default: function() {
return "";
}
},
{
field: "Submittal No.",
description: "Submittal No.:",
default: function() {
return "";
}
}
],
// This maps to a Radio Group in the PDF named 'Status'
radioGroup: "Status",
radioButtons: [
// value maps to the 'Choice' of each radio button in the group, description will show on the dialog
{
value: "Approved",
description: "Approved"
},
{
value: "Approved As Noted",
description: "Approved As Noted"
},
{
value: "Rejected",
description: "Rejected"
},
{
value: "Revise And Resubmit",
description: "Revise And Resubmit"
}
],
radioErrorMsg: "Please select a Status"
// This maps to a Radio Group in the PDF named 'Information'
radioGroup: "Information",
radioButtons: [
// value maps to the 'Choice' of each radio button in the group, description will show on the dialog
{
value: "No Comments",
description: "No Comments"
},
{
value: "Comments As Noted",
description: "Comments As Noted"
},
],
radioErrorMsg: "Please select a Information"
}