Code Monkey home page Code Monkey logo

Comments (3)

mehmetaydogduu avatar mehmetaydogduu commented on May 19, 2024 1

Yes, It is worked after clear browser cache. Thanks.

from filepond.

mehmetaydogduu avatar mehmetaydogduu commented on May 19, 2024

Myconfig:

document.addEventListener('FilePond:pluginloaded', e => {
    console.log('FilePond plugin is ready for use', e.detail);
  });
  document.addEventListener('FilePond:loaded', e => {
    console.log('FilePond ready for use', e.detail);
  });
  document.addEventListener('turbolinks:load', e => {
    console.log('Turbolinks load', e.detail);
    FilePond.registerPlugin(FilePondPluginFileEncode, FilePondPluginFileValidateType);
    const inputElement = document.querySelector('#shipment_csv');
    const pond = FilePond.create( inputElement );
    // attributes have been set to pond options
    console.log(pond.name);  // 'filepond'
    console.log(pond.maxFiles); // 10
    console.log(pond.required); // true
    FilePond.setOptions({
      allowDrop: false,
      allowReplace: false,
      //allowRevert: false,
      allowMultiple: false,
      allowFileEncode: true,
      instantUpload: true,
      allowFileTypeValidation: true,
      acceptedFileTypes: ['text/csv'],
      server: {
          url: "#{import_shipments_path}",
          process: {
              url: '/',
              method: 'POST',
              credentials: 'same-origin',
              withCredentials: true,
              headers: {
                //'Content-Type': 'application/json',
                'X-CSRF-Token': "#{session[:_csrf_token]}"
              },
              timeout: 7000
          },
          revert: '/',
          restore: '/',
          fetch: '/'
      },
      //Translates:
      //labelIdle: 'Dosyalarınızı sürükleyip bırakın veya<span class="filepond--label-action"> Dosya Seçin </span>',
      labelIdle: 'Tek seferde birden fazla yüklemek için CSV kabul ediyoruz.<span class="filepond--label-action"> Dosya Seçin </span>',
      labelFileWaitingForSize: 'Dosya boyutu bekleniyor',
      labelFileSizeNotAvailable: 'Dosya boyutu belirli değil',
      labelFileLoading: 'Yükleniyor',
      labelFileLoadError: 'Yüklenirken bir sorun oluştu',
      labelFileProcessing: 'Sunucuya Yükleniyor',
      labelFileProcessingComplete: 'Sunucuya Yüklendi',
      labelFileProcessingAborted: 'Dosyanın sunucuya yüklenmesi iptal edildi',
      labelFileProcessingError: 'Sunucuya yüklenirken bir hata oluştu',
      labelTapToCancel: 'İptal Et',
      labelTapToRetry: 'Tekrar Dene',
      labelTapToUndo: 'Geri al',
      labelButtonRemoveItem: 'Sil',
      labelButtonRetryItemLoad: 'Tekrar Dene',
      labelButtonAbortItemProcessing: 'İptal Et',
      labelButtonUndoItemProcessing: 'Geri al',
      labelButtonRetryItemProcessing: 'Tekrar gönder',
      labelButtonProcessItem: 'Yükle'
    });
  });

from filepond.

rikschennink avatar rikschennink commented on May 19, 2024

Can you please double check? As the allowRevert setting only impacts the visibility of a single button ( see below ) I suspect something else might be going on.

screen shot 2018-05-15 at 08 58 23

from filepond.

Related Issues (20)

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.