Stephen Ficklin 6 роки тому
батько
коміт
2f39c5cb06

+ 1 - 1
tripal/includes/TripalEntityUIController.inc

@@ -316,7 +316,7 @@ function tripal_view_entity($entity, $view_mode = 'full') {
        $query->propertyCondition('status', 0);
      }
    }
-   $query->propertyOrderBy('label', 'ASC');
+   //$query->propertyOrderBy('label', 'ASC');
 
    // Find out the total number of records and determine what page we're on, and
    // initialize the pager.

+ 5 - 7
tripal_chado/includes/loaders/tripal_chado.pub_importer_PMID.inc

@@ -356,7 +356,7 @@ function tripal_pub_PMID_parse_pubxml($pub_xml) {
   if (!$pub_xml) {
     return $pub;
   }
-
+  
   // read the XML and iterate through it.
   $xml = new XMLReader();
   $xml->xml(trim($pub_xml));
@@ -512,9 +512,7 @@ function tripal_pub_PMID_parse_article($xml, &$pub) {
           tripal_pub_PMID_parse_journal($xml, $pub);
           break;
         case 'ArticleTitle':
-          $xml->read();
-          // remoave any trailing period from the title
-          $pub['Title'] = trim(preg_replace('/\.$/', '', $xml->value));
+          $pub['Title'] = $xml->readString();
           break;
         case 'Abstract':
           tripal_pub_PMID_parse_abstract($xml, $pub);
@@ -675,14 +673,14 @@ function tripal_pub_PMID_parse_abstract($xml, &$pub) {
       switch ($element) {
         case 'AbstractText':
           $label = $xml->getAttribute('Label');
-          $xml->read();
+          $value = $xml->readString();
           if ($label) {
-            $part = "<p><b>$label</b></br>" . $xml->value . '</p>';
+            $part = "<p><b>$label</b></br>" . $value . '</p>';
             $abstract .= $part;
             $pub['Structured Abstract Part'][] = $part;
           }
           else {
-            $abstract .= '<p>' . $xml->value . '</p>';
+            $abstract .= "<p>" . $value . "</p>";
           }
           break;
         case 'CopyrightInformation':