Missing "Types of Article" in 4.2.0-1 Ubu 12.04-1
  • Helo friends...
    I install from repos (atp.soucefabric...) NEWSCOOP 4.2.1 in Ubuntu 12.04-1. It work with some hacks... but it work ok.
    First I create a publication, choosing a theme (Rockstar) then an issue, then a section and then an article...
    But here, when I click in "New article", NC tell me that there isn't NO TYPE of article. What happend? 
    The manual tells that there are 3 by default, "link, news, page"... but "I haven't no one".

    Is this OK for the new realease? Must I make the "types"... Are there some EXTRA pakage?
    I download the "tar.gz" and install, but it's the same.

    Pehaps some one can bring me some help.

    My best for you. Success 
    Rolfo from ARG
  • 5 Comments sorted by
  • Hi, I'm wondering if you found a solution since I'm experiencing the same problem.

    The new 4.2 templates include the filter, constraints="type not poll", but "poll" is either not defined as an article type in the database (which it should be since the developers should know people with earlier versions that do not need it are upgrading to 4.2 and should add mysql tables into the upgrade script) or it is not being recognised as an article type with the result that the polls module cannot be displayed and templates crash. Although in your case it seems this problem is affecting even a new installation!

    There is also a similar problem with section
    headings being called using a new method (#SectionName#)
    since this is not recognised by the database even after running the upgrade script.

    And when I look at the errors that are being discussed in the forum (not being able to move or delete articles, not being able to make a backup, getting white screens/500 errors) I'm beginning to wonder if it was a mistake spending more than a year using Newscoop to create a website.
  • Hello Said, Rodolfo,

    newer versions of themes have new functionality that we call Dialog (option to introduce new kind of content where two authors offer pro and contra arguments on some topic, and public is able to vote using 'debate' plugin. Example: http://rockstar.lab.sourcefabric.org/en/may2013/dialogue/102/UEFA-Champions-league-Enlargement-yes-or-no.htm). Because of that, we also introduced article type 'poll' which is used to generate simple voting poll (because both poll and debate use same plugin for voting). 

    Maybe along this process of adding new functionality we were not transparent enough, but versioning of themes and database with clear compatibility relations is discussed and worked on these very days, so such problems should not occur in the near future (new themes will be released soon, meanwhile take a look to our newest theme Tommy at http://tommy.lab.sourcefabric.org/). 
    --
    Ljuba Rankovic
    Senior Front End Developer, Sourcefabric
    ljuba.rankovic@sourcefabric.org

    http://www.sourcefabric.org
    http://www.twitter.com/Sourcefabric
  • Ljuba, thank you for your feedback. The problem is not the themes (I tried Tommy today and although it doesn't have a poll on the homepage, there was a new problem with the article list length being set to 6 in the template but showing more articles).

    So the problem with the polls must be that the new tables to support the new functions you describe are not being added to the database when upgrading to 4.2, and I'm wondering if there is an sql query that can be run to fix this. (In fact, I even searched the sample .sql files in the 4.2 installation folder today but couldn't find anything using the word "poll")..

    Regards,

    Said
  • In the admin interface, click on 'Configure' and then click on 'Article Types'. If you don't have the article types that are mentioned in your theme, you should create them and add the fields you need. This can easily be done manually, but if you prefer to use SQL, try this (if you have any data in tables named Xdebate, Xlink, Xnews, Xpage or Xpoll, you need to change the query or you will lose your data): 

    --
    -- Dumping data for table `ArticleTypeMetadata`
    --

    LOCK TABLES `ArticleTypeMetadata` WRITE;
    /*!40000 ALTER TABLE `ArticleTypeMetadata` DISABLE KEYS */;
    INSERT INTO `ArticleTypeMetadata` VALUES ('news','NULL',NULL,0,1,NULL,NULL,NULL,0,NULL),('news','deck',2,0,0,NULL,'longtext','editor_size=250',0,NULL),('news','full_text',3,0,0,NULL,'body','editor_size=750',1,NULL),('news','highlight',1,0,0,NULL,'switch',NULL,0,NULL),('page','NULL',NULL,0,0,NULL,NULL,NULL,0,NULL),('page','full_text',1,0,0,NULL,'body','editor_size=750',1,NULL),('link','NULL',NULL,0,0,NULL,NULL,NULL,0,NULL),('link','url',1,0,0,NULL,'text',NULL,0,NULL),('debate','NULL',NULL,0,1,NULL,NULL,NULL,0,NULL),('debate','pro_title',2,0,0,NULL,'text',NULL,0,200),('debate','pro_text',3,0,0,NULL,'body','editor_size=250',0,NULL),('debate','contra_title',4,0,0,NULL,'text',NULL,0,200),('debate','contra_text',5,0,0,NULL,'body','editor_size=250',0,NULL),('debate','teaser',1,0,0,NULL,'body','editor_size=250',0,NULL),('poll','NULL',NULL,0,0,NULL,NULL,NULL,0,NULL);
    /*!40000 ALTER TABLE `ArticleTypeMetadata` ENABLE KEYS */;
    UNLOCK TABLES;

    --
    -- Table structure for table `Xdebate`
    --

    DROP TABLE IF EXISTS `Xdebate`;
    /*!40101 SET @saved_cs_client     = @@character_set_client */;
    /*!40101 SET character_set_client = utf8 */;
    CREATE TABLE `Xdebate` (
      `NrArticle` int(11) NOT NULL,
      `IdLanguage` int(11) NOT NULL,
      `Fpro_title` varchar(255) DEFAULT NULL,
      `Fpro_text` mediumblob,
      `Fcontra_title` varchar(255) DEFAULT NULL,
      `Fcontra_text` mediumblob,
      `Fteaser` mediumblob,
      PRIMARY KEY (`NrArticle`,`IdLanguage`)
    ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
    /*!40101 SET character_set_client = @saved_cs_client */;

    --
    -- Table structure for table `Xlink`
    --

    DROP TABLE IF EXISTS `Xlink`;
    /*!40101 SET @saved_cs_client     = @@character_set_client */;
    /*!40101 SET character_set_client = utf8 */;
    CREATE TABLE `Xlink` (
      `NrArticle` int(10) unsigned NOT NULL,
      `IdLanguage` int(10) unsigned NOT NULL,
      `Furl` varchar(255) NOT NULL,
      PRIMARY KEY (`NrArticle`,`IdLanguage`)
    ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
    /*!40101 SET character_set_client = @saved_cs_client */;

    --
    -- Table structure for table `Xnews`
    --

    DROP TABLE IF EXISTS `Xnews`;
    /*!40101 SET @saved_cs_client     = @@character_set_client */;
    /*!40101 SET character_set_client = utf8 */;
    CREATE TABLE `Xnews` (
      `NrArticle` int(10) unsigned NOT NULL,
      `IdLanguage` int(10) unsigned NOT NULL,
      `Fdeck` mediumblob NOT NULL,
      `Ffull_text` mediumblob NOT NULL,
      `Fhighlight` tinyint(1) NOT NULL,
      PRIMARY KEY (`NrArticle`,`IdLanguage`)
    ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
    /*!40101 SET character_set_client = @saved_cs_client */;

    --
    -- Table structure for table `Xpage`
    --

    DROP TABLE IF EXISTS `Xpage`;
    /*!40101 SET @saved_cs_client     = @@character_set_client */;
    /*!40101 SET character_set_client = utf8 */;
    CREATE TABLE `Xpage` (
      `NrArticle` int(10) unsigned NOT NULL,
      `IdLanguage` int(10) unsigned NOT NULL,
      `Ffull_text` mediumblob NOT NULL,
      PRIMARY KEY (`NrArticle`,`IdLanguage`)
    ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
    /*!40101 SET character_set_client = @saved_cs_client */;

    --
    -- Table structure for table `Xpoll`
    --

    DROP TABLE IF EXISTS `Xpoll`;
    /*!40101 SET @saved_cs_client     = @@character_set_client */;
    /*!40101 SET character_set_client = utf8 */;
    CREATE TABLE `Xpoll` (
      `NrArticle` int(11) NOT NULL,
      `IdLanguage` int(11) NOT NULL,
      PRIMARY KEY (`NrArticle`,`IdLanguage`)
    ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
    /*!40101 SET character_set_client = @saved_cs_client */;


    It will create the article types used in the example data. You can then go to configure article types again and make any adjustments you need. 
  • Sebastian, thank you for posting the SQL which I have only just noticed.

    I had given up on 4.2 after even manually copying missing article types shown in the admin interface of the 4.2 demo to my site didn't work and not being able to upgrade to the new way of displaying headings in the new templates, and have now gone back to 4.1 and removed/replaced references to debate, poll, etc. in  the new templates. But I will insert your SQL dump into the database when the next stable version is released.

    Regards,

    Said