forked from verdnatura/salix-front
Improvements
This commit is contained in:
parent
b22d54f490
commit
3f5c711fa1
|
@ -18,7 +18,7 @@ defineProps({
|
||||||
:class="{ empty: !$props.item.value5 }"
|
:class="{ empty: !$props.item.value5 }"
|
||||||
:title="$props.item.tag5 + ': ' + $props.item.value5"
|
:title="$props.item.tag5 + ': ' + $props.item.value5"
|
||||||
>
|
>
|
||||||
{{ $props.item.value5 }}
|
{{ $props.item.value5 }}s
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
class="inline-tag"
|
class="inline-tag"
|
||||||
|
|
|
@ -9,7 +9,6 @@ import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
|
||||||
import VnInputDate from 'src/components/common/VnInputDate.vue';
|
import VnInputDate from 'src/components/common/VnInputDate.vue';
|
||||||
import EditTableCellValueForm from 'src/components/EditTableCellValueForm.vue';
|
import EditTableCellValueForm from 'src/components/EditTableCellValueForm.vue';
|
||||||
import ItemFixedPriceFilter from './ItemFixedPriceFilter.vue';
|
import ItemFixedPriceFilter from './ItemFixedPriceFilter.vue';
|
||||||
// TODO: mostrar item descriptor en fetchedtags
|
|
||||||
import ItemDescriptorProxy from './Card/ItemDescriptorProxy.vue';
|
import ItemDescriptorProxy from './Card/ItemDescriptorProxy.vue';
|
||||||
|
|
||||||
import { useStateStore } from 'stores/useStateStore';
|
import { useStateStore } from 'stores/useStateStore';
|
||||||
|
@ -27,7 +26,6 @@ const { openConfirmationModal } = useVnConfirm();
|
||||||
const state = useState();
|
const state = useState();
|
||||||
const { notify } = useNotify();
|
const { notify } = useNotify();
|
||||||
|
|
||||||
// const fixedPricesFetchRef = ref(null);
|
|
||||||
const editTableCellDialogRef = ref(null);
|
const editTableCellDialogRef = ref(null);
|
||||||
const user = state.getUser();
|
const user = state.getUser();
|
||||||
const fixedPrices = ref([]);
|
const fixedPrices = ref([]);
|
||||||
|
@ -306,7 +304,7 @@ const upsertPrice = async ({ row, col, rowIndex }, resetMinPrice = false) => {
|
||||||
row = data;
|
row = data;
|
||||||
fixedPricesOriginalData.value[rowIndex][col.field] = row[col.field];
|
fixedPricesOriginalData.value[rowIndex][col.field] = row[col.field];
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
console.error('Error upserting price', err);
|
console.error('Error editing price', err);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -381,7 +379,6 @@ const updateMinPrice = async (value, props) => {
|
||||||
};
|
};
|
||||||
|
|
||||||
const isLower = (date) => {
|
const isLower = (date) => {
|
||||||
// TODO: APLICAR ESTO A CHIPS A LAS FECHAS DE ENDED DATE
|
|
||||||
let today = Date.vnNew();
|
let today = Date.vnNew();
|
||||||
today.setHours(0, 0, 0, 0);
|
today.setHours(0, 0, 0, 0);
|
||||||
|
|
||||||
|
@ -393,7 +390,6 @@ const isLower = (date) => {
|
||||||
};
|
};
|
||||||
|
|
||||||
const isBigger = (date) => {
|
const isBigger = (date) => {
|
||||||
// TODO: APLICAR ESTO A CHIPS A LAS FECHAS DE STARTED DATE
|
|
||||||
let today = Date.vnNew();
|
let today = Date.vnNew();
|
||||||
today.setHours(0, 0, 0, 0);
|
today.setHours(0, 0, 0, 0);
|
||||||
|
|
||||||
|
@ -505,7 +501,10 @@ onUnmounted(() => (stateStore.rightDrawer = false));
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-description="{ row }">
|
<template #body-cell-description="{ row }">
|
||||||
<QTd class="col">
|
<QTd class="col">
|
||||||
<span>{{ row.name }} {{ row.subName }}</span>
|
<span class="link">
|
||||||
|
{{ row.name }}
|
||||||
|
</span>
|
||||||
|
<ItemDescriptorProxy :id="row.itemFk" />
|
||||||
<fetched-tags :item="row" :max-length="6" />
|
<fetched-tags :item="row" :max-length="6" />
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
|
@ -551,10 +550,15 @@ onUnmounted(() => (stateStore.rightDrawer = false));
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-started="props">
|
<template #body-cell-started="props">
|
||||||
<QTd class="col" style="min-width: 150px">
|
<QTd class="col" style="min-width: 160px">
|
||||||
<VnInputDate
|
<VnInputDate
|
||||||
v-model="props.row.started"
|
v-model="props.row.started"
|
||||||
v-on="getRowUpdateInputEvents(props, false, 'date')"
|
v-on="getRowUpdateInputEvents(props, false, 'date')"
|
||||||
|
v-bind="
|
||||||
|
isBigger(props.row.started)
|
||||||
|
? { 'bg-color': 'warning', 'is-outlined': true }
|
||||||
|
: {}
|
||||||
|
"
|
||||||
/>
|
/>
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
|
@ -563,6 +567,11 @@ onUnmounted(() => (stateStore.rightDrawer = false));
|
||||||
<VnInputDate
|
<VnInputDate
|
||||||
v-model="props.row.ended"
|
v-model="props.row.ended"
|
||||||
v-on="getRowUpdateInputEvents(props, false, 'date')"
|
v-on="getRowUpdateInputEvents(props, false, 'date')"
|
||||||
|
v-bind="
|
||||||
|
isLower(props.row.ended)
|
||||||
|
? { 'bg-color': 'warning', 'is-outlined': true }
|
||||||
|
: {}
|
||||||
|
"
|
||||||
/>
|
/>
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
|
|
Loading…
Reference in New Issue