Base solution for your next web application
Open Closed

File upload is not working as expected using Power Tools #11370


User avatar
0
sharadkpatil created

Hi Ismail,

Earlier I am able to perform file upload functionality using Power Tool. But for now for the same steps/procedure i am not able to file upload using power tool. May I know anything changed or any reason?

**Earlier: **

**Now : **

Thanks, Ramakant


10 Answer(s)
  • User Avatar
    0
    m.aliozkaya created
    Support Team

    Hi @sharadkpatil

    I tested in fresh project and it is working. Could you reproduce in new project?

  • User Avatar
    0
    sharadkpatil created

    What about existing application? How to inject or integrate in existing application?

  • User Avatar
    0
    m.aliozkaya created
    Support Team

    Hi @sharadkpatil

    The change is just about the UI and doesn't need integration. Could you try with an example entity?

  • User Avatar
    0
    sharadkpatil created

    Getting these errors

  • User Avatar
    0
    sharadkpatil created

    I can see there is Permission list for File upload in admin account in Demo application but not admin account in my existing application? why is that? Is it vary application to application ? Why it is not there?

  • User Avatar
    0
    m.aliozkaya created
    Support Team

    Hi @sharadkpatil

    If you have installed your database with the migrator, you must have an admin account. A permission list is created for the generated entities. (Create, delete, edit permission)

    Were you able to solve your problem, could you share steps for me to reproduce the issue?

  • User Avatar
    0
    [email protected] created

    Hi @sharadkpatil

    I seem to be having a similar issue. I created an entity using Power Tools with a “file” property. Everything appears to work ok until the actual save of the file. The file doesn’t actually save anywhere.

    I’m very new to the JS world, so I may be overlooking something. What I am expecting is that when selecting “file” as the data type, once saving the file it would save the file to the database.

    Version:12.0.0 Project: MVC Core & jQuery ORM: EF Core DB: MSSQL

  • User Avatar
    0
    Ojala7 created

    Hi,

    I'm having this issue now. Same as previous user. How was this resolved?

  • User Avatar
    0
    m.aliozkaya created
    Support Team

    Hi @Ojala7,

    I tested in version Aspnetzero version 12.0.0 and Power Tools version 4.1.0. I created a basic entity with power tools that contain a file property. It is working correctly, saving file as binary to dbo.AppBinaryObjects table and save binary object id to entity's file property.

    If you want to learn more about file upload, look at https://docs.aspnetzero.com/en/aspnet-core-mvc/latest/Core-Mvc-File-Upload-Tutorial

    Your problem maybe related with this, run this in powershell at mvc project location yarn create-bundles

    If your problem still occurs please send your project to [email protected]

  • User Avatar
    0
    Ojala7 created

    Yes it works when you create a brand new entity, but adding a new column to an existing entity it doesn't