GithubHelp home page GithubHelp logo

dcat-cropper's People

Contributors

weiwait 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

Watchers

 avatar  avatar

dcat-cropper's Issues

無法刪除上傳圖片

您好,請問我要刪除上傳後的圖,從剪裁視窗是可以透過刪除按鈕來刪除預覽圖,可是送出後該圖片仍然存在,完全無法刪除,這可以怎麼解決呢?

上传云存储,会报错

在CroppingController文件中,有这么一句
$filename = Storage::disk(config('admin.upload.disk'))->putFile('weiwait/cropper', $request->file('file'));
然后上传云存储,
在 Cropping.php中
} elseif (str_starts_with($file, 'weiwait/cropper')) { $storage = Storage::disk(config('admin.upload.disk')); $cached = $storage->get($file); //...... }
文件提示找不到,只好把整段ELSE删除。
看这段 else 是上传 weiwait 的临时文件然后删除吗? 那为何不直接在 controller 中
$filename = Storage::disk(config('admin.upload.disk'))->putFile(config('admin.upload.directory.image'), $request->file('file'));

Field type [cropper] does not exist.

composer require weiwait/dcat-cropper
php artisan vendor:publish --tag=weiwait.dcat-cropper --force
php artisan admin:ide-helper
全部执行完毕后,页面显示
Field type [cropper] does not exist.

裁切后上传云存储会报路径找不到。

vendor\weiwait\dcat-cropper\src\Form\Field\Cropper.php
的 prepareInputValue 方法中
$this->callInterventionMethods($this->getStorage()->path($file), $this->getStorage()->mimeType($file));

修改为
$this->callInterventionMethods($this->getStorage()->path($file), null);

正常。

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.