x x x
x
Only portrait mode is currently supported - please rotate your device.

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

ConfiForms Form Definition
additionalFormAdminsconfluence-users
formNamecreateEvent
allowReadstrue
exporttrue


nameEvent NamePlease use only alphanumeric character's for the Event Titletext^[A-Za-z0-9 ,_-]+$

currentNameCurrent Nametext

pageNamePage Nametext

imageEvent Imageimage/*falsefiletrue

typeEvent Typefalse[pt=Production Team|mp=Minimal Production|pe=Physical Event|]select


startDateStart Date30EEE, MMM d yyyy, h:mm a ztruedatetime

endDateEnd Date30EEE, MMM d yyyy, h:mm a ztruedatetime

categoryCategoryfalse[CF=Conference|ED=Executive Dinner|FD=Founders Dinner|LL=Lunch & Learn|MG=Meeting|MP=Meetup|PD=Pitch Day|RP=Reception|VE=Virtual Events|WR=Webinar|]label;falsetruemulti

locationLocationPlease enter a location for the eventfalse[CF=Conference|ED=Executive Dinner|FD=Founders Dinner|LL=Lunch & Learn|MG=Meeting|MP=Meetup|PD=Pitch Day|RP=Reception|VE=Virtual Events|WR=Webinar|]label;falsetruetexttrue

agendaAgendawysiwyg

programProgramwysiwygtrue

cohostsCo-Hostsmultiuser

notifyNotify Cohoststruefalsecheckbox

createdPageCreated Pagepage

publishPublish Flagcheckbox

rsvpRSVP Listtrue[]multiuser

formIdForm Idread_only


confluence-usersRSVPCountRSVP Counttruenumberhidden

confluence-userssequenceSequencetruenumberhidden

startDateTimestampStart Date Timestamptruetext

endDateTimestampEnd Date Timestamptruetext


imageOrganizerOrgnaizer Imageimage/*falsefiletrue

currentImageOrganizerCurrent Organizer Imagetrueread_only

!currentImageOrganizer:[empty]Show containertruecurrentImageOrganizer.currentOrganizertrue


<!--Load the current field values-->

!formId:[empty] AND _user.userInSecurityGroup(confluence-administrators):falsename=[entry.name]&pageName=[entry.pageName]&currentName=[entry.currentName]&currentImage=[entry.currentImage]&agenda=[entry.agenda]&program=[entry.program]&cohosts=[entry.ownedBy]&createdPage=[entry.createdPage]&publish=[entry.publish]&RSVPCount=[entry.RSVPCount]&startDateTimestamp=[entry.startDate]&endDateTimestamp=[entry.endDate]&currentImageOrganizer=[entry.imageOrganizer]&location=[entry.location]&category=[entry.category.transform(id).asList]id:[entry.formId] AND ownedBy:[entry._user]Lookup and set value


<!--Load the current field values (ADMIN)-->

!formId:[empty] AND _user.userInSecurityGroup(confluence-administrators):truename=[entry.name]&pageName=[entry.pageName]&currentName=[entry.currentName]&currentImage=[entry.currentImage]&agenda=[entry.agenda]&program=[entry.program]&cohosts=[entry.ownedBy]&createdPage=[entry.createdPage]&publish=[entry.publish]&RSVPCount=[entry.RSVPCount]&startDateTimestamp=[entry.startDate]&endDateTimestamp=[entry.endDate]&currentImageOrganizer=[entry.imageOrganizer]&location=[entry.location]&category=[entry.category.transform(id).asList]id:[entry.formId]Lookup and set value

<!--Don't allow events in the past-->


<!--Don't allow end date earlier than start date-->

endDate:<=[entry.startDate]Invalid date range - please ensure the end date is after the start date..Validation ruleendDate

<!--Add cohosts to ownedBy list on new entry-->

!cohosts:[empty] AND formId:[empty]Create ConfiForms EntryonCreatedentryId=[entry.id]&ownedBy=[entry.createdBy],[entry.cohosts.asList]


<!--Update cohosts to ownedBy list on existing entry-->

!cohosts:[empty] AND !formId:[empty]Create ConfiForms EntryonCreatedentryId=[entry.formId]&ownedBy=[entry.createdBy],[entry.cohosts.asList]


<!--Update currentName from currentName on existing entry→

!currentName=name AND !formId:[empty]Create ConfiForms EntryonCreatedentryId=[entry.formId]&currentName=[entry.currentName]


<!--Update the organizer image if changed-->

!imageOrganizer:[empty] AND !formId:[empty]Create ConfiForms Entry25657553onCreatedentryId=[entry.formId]&imageOrganizer=[entry.imageOrganizer.asAttachment.displayTitle]&currentImageOrganizer=[entry.imageOrganizer.asAttachment.displayTitle]


<!--Set current attachment name on new entry-->

formId:[empty] AND PEANUTStrueCreate ConfiForms EntryonCreatedentryId=[entry.id]& currentImageOrganizer = imageOrganizer


<!--Update fields upon edit-->

!formId:[empty]Create ConfiForms EntryonCreatedentryId=[entry.formId]&name=[entry.name]&currentName=[entry.currentName]&pageName=[entry.pageName]&currentImage=[entry.currentImage]&startDate=[entry.startDate]&endDate=[entry.endDate]&agenda=[entry.agenda]&program=[entry.program]&cohosts=[entry.ownedBy]&createdPage=[entry.createdPage]&publish=[entry.publish]&RSVPCount=[entry.RSVPCount]&location=[entry.location]&category=[entry.category]createdBy:[entry._user]createEvent:4633414546334144



<!--Redirect on update-->

!formId:[empty]Redirect to URLonCreated/display/EV/[entry.pageName]


<!-- Create group when event is created send analytics Event-->

formId:[empty]Run JavaScriptonCreated



<!–TODO - Set page name from title→

formId:[empty]trueCreate ConfiForms EntryonCreatedentryId=[entry.id]&pageName=[entry.name]


<!–Create new page-->

formId:[empty]Create PageonCreated[entry.pageName]eventPC



id:[entry.id]createEvent1

4633414546334144



publisher


Publish@selfpublisherPublishtrueINLINEAre you sure you want to publish this event? It will be visible to all users platform


publishpublish flagcheckbox

formIdform idread_only

Update ConfiForms entries by filteronCreatedpublish=trueid:[entry.id]createEvent:4633414546334144




publishec


Unpublish@selfpublishecUnpublishtrueINLINEAre you sure you want to un-publish this event? It will be hidden to all non-admin users on the platform


publishpublish flagcheckbox

formIdform idread_only

Update ConfiForms entries by filteronCreatedpublish=falseid:[entry.id]createEvent:4633414546334144




f

fileAttachfileAttachfile

eventFileNameeventFileNametext

eventTitleEvent Titletext

dtWhen30EEE, MMM d yyyy, h:mm a zdatetimeinterval

eventDescriptionEvent Descriptiontextarea

messageBodyICSMessage Bodyhtml

id:fileAttachHide field

recipientRecipienttext

titleTitletext

sequenceSequencetext

trueINLINE



Create Attachment[entry.id.asEntryRef(entry.eventFileName)].icsonCreatedfileAttachtext/calendar




Send EmailAWS EdStart<awsedstart-tpms@amazon.com>onCreated[entry.id.asEntryRef(entry.title)][entry.id.asEntryRef(entry._user)]

messageBodyICS

fileAttach



fRemoveSaveRemove

fileAttachRemovefileAttachRemovefile

eventFileNameRemoveeventFileNameRemovetext

eventTitleRemoveEvent Title Removetext

dtRemoveWhenRemove30EEE, MMM d yyyy, h:mm a zdatetimeinterval

eventDescriptionRemoveEvent Description Removetextarea

messageBodyICSRemoveMessage Body Removehtml

id:fileAttachRemoveHide field

recipientRemoveRecipient Removetext

titleRemoveTitle Removetext

sequenceRemoveSequence Removetext

trueINLINE



Create Attachment[entry.id.asEntryRef(entry.eventFileNameRemove)].icsonCreatedfileAttachRemovetext/calendar




Send EmailAWS EdStart<awsedstart-tpms@amazon.com>onCreated[entry.id.asEntryRef(entry.titleRemove)][entry.id.asEntryRef(entry._user)]

messageBodyICSRemove

fileAttachRemove



fUpdateSaveUpdate

fileAttachUpdatefileAttachUpdatefile

eventFileNameUpdateeventFileNameUpdatetext

eventTitleUpdateEvent Title Updatetext

dtUpdateWhenUpdate30EEE, MMM d yyyy, h:mm a zdatetimeinterval

eventDescriptionUpdateEvent Description Updatetextarea

messageBodyICSUpdateMessage Body Updatehtml

id:fileAttachUpdateHide field

recipientUpdateRecipient Updatetext

titleUpdateTitle Updatetext

sequenceUpdateSequence Updatetext

trueINLINE



Create Attachment[entry.id.asEntryRef(entry.eventFileNameUpdate)].icsonCreatedfileAttachUpdatetext/calendar




Send EmailAWS EdStart<awsedstart-tpms@amazon.com>onCreated[entry.id.asEntryRef(entry.titleUpdate)][entry.id.asEntryRef(entry.recipientUpdate)]

messageBodyICSUpdate

fileAttachUpdate


[entry.id.asEntryRef(entry.id)]

removeFromWatchlist()CancelunregisterButtonOkThis event has been removed from your watchlist.Are you sure you want to remove this event from your Watchlist?.unregister-button

updateGuestCalendars()CancelupdateGuestCalendarsButtonOkAn email has been sent to the event guest list with the updated calendar invite and event information!This will send an email to everyone on the guest list with an updated calendar invitation!.update-rsvp-button


<!--Redirect new entry-->

formId:[empty]Redirect to URLonCreated/display/EVE/[entry.pageName]


<!–Update entry with created page url-->

formId:[empty]Create ConfiForms EntryonCreatedentryId=[entry.id]&createdPage=${iftttResult_PC.id}


<!-- Copy Organizer image to attachments bank -->

!imageOrganizer:[empty]Copy Attachment[entry.createdPage]onCreated[entry.imageOrganizer.asAttachment.id]


<!–Update entry with created page update url-->

!currentName:[entry.name] AND !currentName:[empty]Create ConfiForms EntryonCreatedentryId=[entry.id]&createdPage=${iftttResult_PCU.id}


<!--Delete update entry reference-->

!formId:[empty]Delete ConfiForms EntryonCreatedid:[entry.id]5


<!--Send email to new co-hosts-->

notify:true AND !cohosts:[empty]Send EmailAWS EdStart<awsedstart-tpms@amazon.com>onCreatedUpdates made to the [entry.name] event[entry.cohosts.asList]

Hello,

You receiving this message because you are listed as a cohost on the [entry.name] event.

To view changes, edit, or publish the event, go <a href="[entry.createdPage.urlPath]">here</a>.


Thank you,

AWS EdStart Team


...

HTML
<script>
function getQueryVariableFromUrl(variable){
  var query = window.location.search.substring(1);
  var vars = query.split("&");
  for (var i=0;i<vars.length;i++) {
    var pair = vars[i].split("=");
    if(pair[0] == variable){return pair[1];}
    }
       return(false);
}

var entry_id = getQueryVariableFromUrl('entry_id');
var startDate;
var startDateLocalTime = '';
var startDateFixed = '';
var endDate;
var endDateLocalTime = '';
var endDateFixed = '';

const getTimeStamps = async (entry_id) => {
  let eventData = await jQuery.ajax({
    url: '/ajax/confiforms/rest/filter.action?pageId=4633414546334144&f=createEvent&q=id:' + entry_id, 
    type: "get", 
    dataType: 'json', 
    async: true
  }).then(res => res);
  return eventData;
}

const formatDates = async (startDateLocalTime, endDateLocalTime) => {
  for (var month in calendar) {
    if (startDateLocalTime.includes(month)) {
      console.log("about to do start Date Fixed")
      startDateFixed = `${startDateLocalTime.replace(month, calendar[month])} ${new Date().toString().match(/([-\+][0-9]+)\s/)[1]}`;
      console.log("did start Date Fixed")
    }

    if (endDateLocalTime.includes(month)) {
      console.log("about to do end Date Fixed")
      endDateFixed = `${endDateLocalTime.replace(month, calendar[month])} ${new Date().toString().match(/([-\+][0-9]+)\s/)[1]}`;
      console.log("did end Date Fixed")
    }
  }
}

async function formatDateLong2(d) {
  const monthNames = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
  const dayNames = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"];

  var hh = d.getHours(); 
  var m = d.getMinutes();
  var s = d.getSeconds();
  var dd = "am";
  var h = hh;
  if (h >= 12) {
    h = hh-12;
    dd = "pm";
  }
  if (h == 0) {
    h = 12;
  }
  m = m<10?"0"+m:m;
  s = s<10?"0"+s:s;

  var strTime = h+":"+m+" "+dd
  return dayNames[d.getDay()] + ", " + monthNames[d.getMonth()] + " " + d.getDate() + " " + d.getFullYear() + ", " + strTime;
}

$("#i_startDateTimestamp").waitUntilExists(() => {
  getTimeStamps(entry_id).then((data) => {
    startDate = new Date(data.list.entry[0].fields.startDate);
    endDate = new Date(data.list.entry[0].fields.endDate);

    formatDateLong2(startDate).then((startDateFormatted) => {
      startDateLocalTime = startDateFormatted;
      formatDateLong2(endDate).then((endDateFormatted) => {
        endDateLocalTime = endDateFormatted;
        formatDates(startDateLocalTime, endDateLocalTime).then(() => {
          $("#i_startDate").val(startDateFixed);
          $("#i_endDate").val(endDateFixed);
        })
      })
    })
  })
})
</script>

...