metasfresh / metasfresh-webui-frontend-legacy

metasfresh Webui Frontend
GNU General Public License v2.0
57 stars 34 forks source link

Drag and Drop Attachments #1640

Open metas-lc opened 6 years ago

metas-lc commented 6 years ago

Is this a bug or feature request?

fr

What is the current behavior?

right now you can't drag and drop multiple files at the same time

Which are the steps to reproduce?

  1. open e.g. sales order
  2. drag and drop 2 files => one uploaded, one not image

What is the expected or desired behavior?

should be able to upload multiple files at the same time

pablosichert commented 6 years ago

The following translation keys need to be added:

metas-lc commented 6 years ago

IT

  1. make a new order, save
  2. drag and drop 3 files => only 1 or 2 files are uploaded NOK => error: org.postgresql.util.PSQLException: ERROR: duplicate key value violates unique constraint "ad_attachment_record_id_ad_table_id" Detail: Key (record_id, ad_table_id)=(1000009, 259) already exists. SQL: INSERT INTO AD_Attachment (AD_Attachment_ID,AD_Client_ID,AD_Org_ID,AD_Table_ID,Created,CreatedBy,IsActive,Record_ID,Title,Updated,UpdatedBy) VALUES (nextval('ad_attachment_seq'),1000000,1000000,259,TO_TIMESTAMP('2018-03-12 17:08:14','YYYY-MM-DD HH24:MI:SS'),2188223,'Y',1000009,'.',TO_TIMESTAMP('2018-03-12 17:08:14','YYYY-MM-DD HH24:MI:SS'),2188223) RETURNING AD_Attachment_ID

image

  1. remove the attachments and drag and drop them again => works: all 3 files are imported, without errors OK (except the trl errors. Follow-up: https://github.com/metasfresh/metasfresh/issues/3664)
pablosichert commented 6 years ago

@teosarca is this a backend issue or does the client need to submit files differently?

siemiatj commented 6 years ago

@teosarca from error messages looks like either we need some unique keys/id's for each file, or backend needs some changes.