Giter VIP home page Giter VIP logo

copycat's People

Contributors

asross avatar ecbypi avatar steve9001 avatar

Stargazers

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

Watchers

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

copycat's Issues

Doesn't work in Rails 4.1+

Getting the "undefined method `attr_accessible' for #Class:0x007fa32ee13ab0" error as we need to use strong parameters.

custom copycat url

I would like to change the copycat url to something other than /copycat_translations.

Sort out loading order

Rails initialization invokes I18n.translate after the engine is loaded. This leads to AR query, which fails if the table doesn't exist, which is the case when the installation migration is running.

generator to install plugin

We need a generator that creates an initializer. The initializer sets the username and password. Those should be randomly generated by the generator and reported in output of install command.

The migration should also be installed with the one command 'rake copycat_plugin:install'

Deal with LIKE

The original LIKE implementation was reported to be incompatible with MySQL. The subsequent implementation used .to_sql of arel but that appears to require a recent version of either Rails or Arel, and isn't compatible with Rails 3.1.

Getting error when loading /copycat_translations

Couldn't find all CopycatTranslations with 'id': (all, {:select=>"distinct locale"}) (found 0 results, but was looking for 2)

Looks to be because of the line CopycatTranslation.find(:all, select: 'distinct locale'). I think it may not be supported in latest Rails maybe? CopycatTranslation.all.select('distinct locale').map(&:locale) works

In-place editing

Is there an easy way to enable in-place editing for fields if you're logged in as an admin? I started looking into best_in_place, but it seems to want to modify model fields and copycat is based on translations. If anybody has solved this already, I'd love to know how to do it.

If nobody has, this would be an awesome feature.

authentication

HTTP Basic Authentication to protect the controller. username and password are set in the initializer

massive concurrency to tables from busy app

Are there further optimizations that can be made to code or schema to support high concurrency for copycat_translations lookups. We're seeing some latency to the database table at high concurrency.

Thanks.

Add option to not cache empty values

Currently, the first time a key is looked up by copycat, and it doesn't find the key in the DB, it cascades the lookup to Rails (en.yml), and then always creates a new entry in the DB for that key with whatever value was in the yml. If there was no value it still creates a key with a blank value. That means if somebody later adds a value to the yml it will not make it to the copycat table because subsequent lookups will find the key in the db and never cascade to the yml lookup.

Add a configuration option to not cache keys with no values. That way if a developer adds the key to the template and renders the page before writing the value in en.yml, it won't prevent them from seeding the values later when they add values to the yml.

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.