Subversion Repositories VORC

Rev

Rev 173 | Rev 236 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 173 Rev 235
Line 94... Line 94...
94
  use REST::Client;
94
  use REST::Client;
95
  use JSON;
95
  use JSON;
Line 96... Line 96...
96
  
96
  
97
  my $sth = $dbh->prepare ("update ticket set wrstbnd_accountid = ? where id = ?");
97
  my $sth = $dbh->prepare ("update ticket set wrstbnd_accountid = ? where id = ?");
98
  my @REGIDS;
98
  my @REGIDS;
99
  push @REGIDS, map { @{$_} } @{ $dbh->selectall_arrayref ("select id from ticket where event_name = ? and isnull(wrstbnd_accountid) = 1", undef, "RollerCon 2024") };
99
  push @REGIDS, map { @{$_} } @{ $dbh->selectall_arrayref ("select id from ticket where event_name = ? and isnull(wrstbnd_accountid) = 1", undef, "RollerCon 2025") };
100
  foreach (@REGIDS) {
100
  foreach (@REGIDS) {
101
    my $regid = $_;
101
    my $regid = $_;
102
  	my $wbdid = getAccountId ($regid);
102
  	my $wbdid = getAccountId ($regid);
103
  	$sth->execute ($wbdid, $regid);
103
  	$sth->execute ($wbdid, $regid);
Line 107... Line 107...
107
sub getAccountId {
107
sub getAccountId {
108
	my $eventsReg = shift // "";
108
	my $eventsReg = shift // "";
109
	warn "ERROR: No Events.com Regstration provided to getAccountId()!" and return "" unless $eventsReg;
109
	warn "ERROR: No Events.com Regstration provided to getAccountId()!" and return "" unless $eventsReg;
Line 110... Line 110...
110
	
110
	
111
	my $headers = { Authorization => '601037851507c624' };
111
	my $headers = { Authorization => '601037851507c624' };
112
	my $wb_event_id = "event_Y5567UWwS5";
112
	my $wb_event_id = "event_893C6u5olU";
Line 113... Line 113...
113
	my $client = REST::Client->new();
113
	my $client = REST::Client->new();
114
	
114
	
115
	$client->setHost('https://core.wrstbnd.io');
115
	$client->setHost('https://core.wrstbnd.io');