Giter VIP home page Giter VIP logo

core's Introduction

Novius OS Build Status Gitter chat

Novius OS is an Open Source PHP Content Management System designed as an applications platform, hence the ‘OS’ suffix. You tailor Novius OS to your content through the creation of custom applications. Your well-structured content is to ready to be published to any channel—present and future.

Novius OS is built with the MVC framework, FuelPHP. “FuelPHP is a simple, flexible, community driven PHP 5.3+ framework, based on the best ideas of other frameworks, with a fresh start!” Novius OS HTML5 interface is powered by jQuery UI and the Wijmo library.

  • Current version: Novius OS 5.0.1 (Elche)

Requirements

  • Novius OS requires PHP 5.3+, a SQL database and an HTTP server.
  • Fully tested on LAMP (Ubuntu) and WAMP (Apache’s mod_rewrite enabled).
  • Community tested on Nginx and Raspberry Pi.
  • Can theoretically run on Mac and/or PostgreSQL.

Installation

(This is the quick install procedure. Command line access to the server with sudo admin rights and Git are required. Alternative methods are available.)

Open a terminal and run:

cd /var/www
sudo wget http://raw.github.com/novius-os/ci/master/elche/tools/install.sh && sh install.sh

Once the installation completes:

  • Open your browser at http://your.domain/novius-os/ (replace novius-os with the directory name you’ve chosen).
  • Let the install wizard guide you.

Documentation & support

All you need to know to create applications, extend existing ones or contribute to Novius OS is to be found at docs.novius-os.org.

If you don’t find answers to your questions in the docs, you’ll find help in the forum.

La documentation et le forum sont aussi disponibles en français.

Demo & further information

Contacts & contributions

License

Novius OS is licensed under GNU Affero General Public License v3 or (at your option) any later version.

core's People

Contributors

domeyd avatar felixgilles avatar foine avatar freddubois avatar fredelcia avatar garsaud avatar gpascal avatar jay3 avatar jguyomard avatar jiboule avatar kcazer avatar meroje avatar mouton-rebelle avatar mvy avatar ounziw avatar savageman avatar sdrdis avatar seb-c avatar shaoshiva avatar theogil avatar tonyyb avatar unibozu avatar vrcalbert avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

core's Issues

The last version made some buggy url for urlEnhancer on a page

Hello,
I think the commit 6706518 ("Bugfix for Tools_Url::page() returning path version of URL without .html") is responsible of one problem that doesn't appear before.
An example is more powerful than a long speach so :
in this page : http://oppoc.fr/blog.html , urls for the posts are not good. In the other page of the site, they are working properly (the url() method is call everywhere).

I hope you will find a solution for this problem.

The Front Controller "getContext" method don't work after cache

Hello !

I found that the "getContext" method do not work if you use it after the cache.
But if you use

\Nos\Nos::main_controller->getPage()->context

It works perfectly.
I don't know what is the better method to prevent this issue.
Fallback on the second method when you call the first after the cache or fill the "_context" properties of the front controller even after the cache.

Enhancer previews are not displayed in the same way when update or save.

Hello,

I found that enhancer previews are not displayed in the same way when you save it or when it is updated.

The difference is here :
novius-os/static/admin/vendor/tinymce/plugins/nosenhancer/editor_plugin_src.js
line 66 and line 218
In the first case (display is updated) the html of preview is send directly.

enhancer.html(json.preview);

In the second case, for security,the preview is put in a jQuery object before and the result of the "html" method is send like this :

.html($(json.preview).html());

But in that way, you just have the inner html of your preview.
For exemple if your preview is

<div>My div</div>

the result of :

$('<div>My div</div>').html();

is

My div

And that is what append in the line 218.
To prevent that, I suggest to do :

.html($(json.preview).get());

instead of

.html($(json.preview).html());

I suggest to to this also in line 66 to have the same behaviour in the two case.

Thanks in advance for your answer.

url() method without item

Hello!

I've thought about something which might be helpfull to front developpers.
Up to now, using urlEnhancer and the url() method is only available with an existing item. It sometimes happens to deal with specific views thanks to an url enhancer without having a specific item.

eg : I have a list of items (default view directly on the page wich contains the url enhancer) or I can display a specific item of this list thanks to $object->url(...), but I may want to display a different kind of list (eg with a filter). The 3rd option should be available by doing something like

\Nos\Tools_Enhancer::url('enhancer_name', array(
    ...
    'params' => array( 
        'some filter/page' => 'some value'
    )
    ...
)); 

where the key "params" is used to call the get_url_model($item, $params) method of the front controller, with $item = null

This would return an url like www.website.com/path/to/urlenhancer/requested_page.html whereas now we can only have www.website.com/path/to/urlenhancer.html.

Is this sounds acceptable? Or is there another way to do it?

Thanks in advance!

Twinnable HasMany relation with cascade delete doesn't work as expected

For a Twinnable HasMany relation you can configure the cascade_delete by setting true or false.

With cascade_delete set to false there are 2 possible behaviours :

  • if key_to is not a common field on the target model, the item will be soft deleted (key_to set to 0), the items in the others contexts won't be deleted.
  • if key_to is a common field on the target model, the item and the items in the others contexts will be soft deleted (the key_to is set to 0) .

But with cascade_delete set to true there is only one behaviour :

  • regardless whether the key_to is a common field or not, the item will be hard deleted (removed from database), and items in the others contexts won't be deleted.

... instead it should be :

  • if key_to is not a common field on the target model, the item will be hard deleted (removed from database), the items in the others contexts won't be deleted.
  • if key_to is a common field on the target model, the item and the items in the others contexts will be hard deleted (removed from database).

To fix this issue we will have to write a custom save method on Nos\Orm_Twinnable_HasMany instead of using the save method of the parent class Orm\HasMany.

Here is the part of the save method that hard deletes the related item :

$model_from->unfreeze();
$obj->delete();
$model_from->freeze();

It could be patched this way :

$model_from->unfreeze();

// Deletes the items in the other contexts if key_to is a common field
if (check_if_key_to_is_a_common_field()) { // @todo
    foreach ($obj->find_other_contexts()  as $other_obj) {
        $other_obj->delete();
    }
}

// Deletes the item in the current context
$obj->delete();

$model_from->freeze();

Will try to start a pull request when I'll have time.

In the meantime if you need to remove the items in all the contexts, use the soft delete (cascade_delete set to false).

Edit: updated patch code

Style format are not take in count when you redefine it in local config

Hello,
I wanted to add some styles in the wysiwygs of my project.

but my style are note displayed :

<?php
return array(
    'setups' => array(
        'default' => array(
            'theme_advanced_style_formats' =>  array(
                array(
                    'title' => 'Chapo',
                    'inline' => 'strong',
                ),
                array(
                    'title' => 'Lien fleche',
                    'block' => 'p',
                    'classes' => 'bt-plus'
                ),
            ),
        ),
    ),
);

This configuration is merged to the native configuration (I see it in the renderer options) but it seems that it's not take in count by JS.

Did I do something wrong ?

Thanks in advance.

Crash on Inspector with belongs-to relation

When using an Inspector with a custom query using a belongs-to relation the controller will create a query using wrong aliases resulting in a crash.

Config example:

return array(
    'model' => 'Model_With_BelongsTo',
    'query' => array(
        'model'    => 'Model_With_BelongsTo',
       'related' => array('relation'),
        'callback' => function ($query) {
                return $query->where('relation.field', 1);
            }

    ),
    'input' => array(
        'key' => 'id',
    )
);

Will create something similar to

SELECT COUNT(DISTINCT `t0`.`id`) AS count_result,
`t1`.`id` AS `t1_c0`,`t1`.`other_fields_from_t0` AS `t1_c1`,
`t1`.`t1_real_fields` as `t1_c2`
FROM `table_0` AS `t0`
LEFT JOIN `table_2` AS `t1` ON (`t0`.`rel_id` = `t1`.`id`)
WHERE `t0`.`id` = 1

The where is executed on the wrong table and half the fields are selected on the wrong alias too.

Default preview for enhancers

Would it be possible to add a default preview to the enhancers? For example, it could use a title and an image provided by the config file.
This could save time to create simple enhancers.

Thanks
Jay

Bad detection of script for the addJavascriptInline method

Hello.
When you use the "addJavascriptInline" method, the core test if the string starts with '<script '. But, for example, twitter give us this code fore tweet button :
<script>!function(d,s,id)...

So the script node is not detected.
Does the "addJavascriptInline" method should not test if the string starts with '<script' instead of '<script ' ?
Thank you for your reply.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.