Giter Club home page Giter Club logo

mediaremove's People

Contributors

petrenslavik avatar

Stargazers

 avatar

Watchers

 avatar

mediaremove's Issues

404 Error on basically all Endpoints

Hello!
I've installed MediaRemove on an instance of Umbraco 9.1.2

When opening the Media Remove tab under settings I get 404 errors popping up on the following endpoints:
/umbraco/api/mediaRemove/GetRebuildStatus
/umbraco/api/mediaRemove/GetUnusedMediaStatus
/umbraco/api/mediaRemove/IsBuilt
/umbraco/api/mediaRemove/DeleteUnusedMediaStatus

The UI also only shows an empty panel. Did I install it wrong or is there something I could do to fix it?

Best regards,
Joshua

Tried adding support for the Block Grid editor (Umbraco11+)

I added a parser for it:

public class BlockGridEditorParser : BaseTextParser
{
    public override bool IsParserFor(string propertyEditorAlias)
    {
        return propertyEditorAlias.Equals("Umbraco.BlockGrid");
    }
}

but it still does not find the images in the block grid editor content. Is there something else needed to be added?

This is more of a request rather than an issue

We would like to use this plugin in a clients Umbraco 8 website but there a few things stopping us:

a) We need an option so that the media files get moved to the recycle bin instead of deleted: (MediaRemoveController)

mediaService.MoveToRecycleBin(mediaService.GetById(id));

b) One of our developers added a routine to look for non-referenced Media files in content.

if (!string.IsNullOrWhiteSpace(root.Model.Source))
                        {
                            string src = "";

                            if (root.Model.Source.ToLower().Trim().StartsWith("/media"))
                            {
                                src = root.Model.Source.ToLower().Trim();
                            }
                            else
                            {
                                JObject json = JObject.Parse(root.Model.Source);
                                src = json["src"].Value<string>();
                            }                            

                            if (!string.IsNullOrWhiteSpace(src))
                            {
                                this.logger.Info<MediaRemoveController>("querying: " + src);

                                var result = db.Query<string>("SELECT Data FROM [dbo].[cmsContentNu] where data like '%" + src + "%' and published > 0 and rv > 0 ");

                                if (result != null && result.Count() > 0)
                                {
                                    //referenced in the site but not using Umbraco ID, so do not delete
                                    mediaRemoveContext.JustAMessage += src + " |";
                                    this.logger.Info<MediaRemoveController>("referenced but not using UDI: " + src);
                                }
                                else
                                {
                                    this.logger.Info<MediaRemoveController>("unused: " + src);
                                    mediaRemoveContext.UnusedMedia.Add(root);
                                }
                            }
                        }

c) Also since we use Continuous Integration it would be better to be able to install the plugin via Nuget.

Shall i submit a pull request with these changes?

Regards,
Marshall

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.