Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F123611876
20130802.heraldphids.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Mon, Jul 28, 16:24
Size
490 B
Mime Type
text/x-php
Expires
Wed, Jul 30, 16:24 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
27693480
Attached To
rPH Phabricator
20130802.heraldphids.php
View Options
<?php
$table
=
new
HeraldRule
();
$conn_w
=
$table
->
establishConnection
(
'w'
);
echo
"Assigning PHIDs to Herald Rules...
\n
"
;
foreach
(
new
LiskMigrationIterator
(
new
HeraldRule
())
as
$rule
)
{
$id
=
$rule
->
getID
();
echo
"Rule {$id}.
\n
"
;
if
(
$rule
->
getPHID
())
{
continue
;
}
queryfx
(
$conn_w
,
'UPDATE %T SET phid = %s WHERE id = %d'
,
$table
->
getTableName
(),
PhabricatorPHID
::
generateNewPHID
(
HeraldPHIDTypeRule
::
TYPECONST
),
$rule
->
getID
());
}
echo
"Done.
\n
"
;
Event Timeline
Log In to Comment