zone warehouse error
gitea/salix/dev This commit looks good Details

This commit is contained in:
Javi Gallego 2019-11-07 07:49:37 +01:00
parent 729f6cb767
commit eaa2ef4570
3 changed files with 9 additions and 5 deletions

View File

@ -23,7 +23,9 @@ BEGIN
ENGINE = MEMORY
SELECT vWarehouseFk warehouseFk,
TIMESTAMPADD(DAY,zo.travelingDays, vShipped) landed,
zo.zoneFk
vShipped shipped,
zo.zoneFk,
z.agencyModeFk
FROM tmp.zoneOption zo
JOIN zone z ON z.id = zo.zoneFk
WHERE agencyModeFk = vAgencyModeFk;

View File

@ -23,9 +23,12 @@ BEGIN
SELECT * FROM (
SELECT zo.zoneFk,
TIMESTAMPADD(DAY,-zo.travelingDays, vLanded) shipped,
zw.warehouseFk
zw.warehouseFk,
z.agencyModeFk
FROM tmp.zoneOption zo
JOIN zoneWarehouse zw ON zw.zoneFk = zo.zoneFk
JOIN zone z ON z.id = zo.zoneFk
WHERE z.agencyModeFk = vAgencyModeFk
ORDER BY shipped) t
GROUP BY warehouseFk;

View File

@ -1,6 +1,5 @@
<vn-crud-model
url="Zones"
include="{relation: 'warehouse'}"
data="zones"
order="name"
auto-load="true">
@ -86,7 +85,7 @@
ng-model="$ctrl.zoneId"
vn-acl="productionBoss">
<tpl-item>
<span>{{::name}} - {{::warehouse.name}} - Max. {{::hour | date: 'HH:mm'}} h.</span>
<span>{{::name}} - Max. {{::hour | date: 'HH:mm'}} h.</span>
</tpl-item>
</vn-autocomplete>
</vn-horizontal>