Fixed order
gitea/salix/pipeline/head This commit looks good Details

This commit is contained in:
Joan Sanchez 2020-06-03 12:21:03 +02:00
parent f71a2a3665
commit 613937dc8d
3 changed files with 8 additions and 7 deletions

View File

@ -4,7 +4,7 @@
user-params="::$ctrl.filterParams"
limit="20"
data="requests"
order="shipped DESC, isOk ASC"
order="shippedDate ASC, isOk ASC"
auto-load="true">
</vn-crud-model>
<vn-portal slot="topbar">

View File

@ -8,16 +8,16 @@ export default class Controller extends Section {
if (!this.$state.q) {
const today = new Date();
today.setHours(23, 59, 59, 59);
today.setHours(0, 0, 0, 0);
const lastWeek = new Date();
lastWeek.setHours(0, 0, 0, 0);
lastWeek.setDate(lastWeek.getDate() - 7);
const nextWeek = new Date();
nextWeek.setHours(23, 59, 59, 59);
nextWeek.setDate(nextWeek.getDate() + 7);
this.filterParams = {
mine: true,
from: lastWeek,
to: today
from: today,
to: nextWeek
};
}
}

View File

@ -115,6 +115,7 @@ module.exports = Self => {
s.itemFk,
i.name AS itemDescription,
t.shipped,
DATE(t.shipped) AS shippedDate,
t.nickname,
t.warehouseFk,
t.clientFk,