thick line after one week, solve #14

This commit is contained in:
Sockenklaus
2021-10-14 01:13:09 +02:00
parent e050db4155
commit 82ca721a9f

View File

@@ -14,39 +14,45 @@ AddEmployeeModal(
thead thead
tr tr
td.fw-bold(style="width: 150px") {{ format(startDates[mIndex], "MMMM", {locale: de}) }} td.fw-bold(style="width: 150px") {{ format(startDates[mIndex], "MMMM", {locale: de}) }}
td(v-for="(day, index) in weekdays" :key="index" :class="{'text-body text-opacity-50 bg-secondary bg-opacity-10' : row.dates[index] === null}") {{ day }} td(v-for="(day, dIndex) in weekdays" :key="dIndex" :style="dIndex === 6 ? 'border-right : 2px solid' : ''" :class="{'text-body text-opacity-50 bg-secondary bg-opacity-10' : row.dates[dIndex] === null}") {{ day }}
tr tr
td.fw-bold {{ format(startDates[mIndex], "y") }} td.fw-bold() {{ format(startDates[mIndex], "y") }}
td(v-for="(date, dIndex) in row.dates" :key="dIndex" :class="{'bg-secondary bg-opacity-10' : row.dates[dIndex] === null}") td(v-for="(date, dIndex) in row.dates" :key="dIndex" :style="dIndex === 6 ? 'border-right : 2px solid' : ''" :class="{'bg-secondary bg-opacity-10' : row.dates[dIndex] === null}")
template(v-if="date !== null") {{ format(date, "dd.MM.")}} template(v-if="date !== null") {{ format(date, "dd.MM.")}}
tbody tbody
tr(v-for="(employee, eIndex) in row.employees" :key="eIndex") tr(v-for="(employee, eIndex) in row.employees" :key="eIndex")
td td()
.row.justify-content-between.align-items-center.employee-wrapper .row.justify-content-between.align-items-center.employee-wrapper
.col.text-start.ps-3 {{employee.handle}} .col.text-start.ps-3 {{employee.handle}}
.col.text-end .col.text-end
button.btn( button.btn.btn-sm(
@click="removeEmployee(mIndex, rIndex, employee)" @click="removeEmployee(mIndex, rIndex, employee)"
) )
i.bi-x-lg i.bi-x-lg
td( td(
v-for="(date, dIndex) in row.dates" v-for="(date, dIndex) in row.dates"
:key="dIndex" :key="dIndex"
:style="dIndex === 6 ? 'border-right : 2px solid' : ''"
:class="{'bg-secondary bg-opacity-10' : row.dates[dIndex] === null, 'selected' : isSelected(mIndex, rIndex, eIndex, dIndex)}" :class="{'bg-secondary bg-opacity-10' : row.dates[dIndex] === null, 'selected' : isSelected(mIndex, rIndex, eIndex, dIndex)}"
@click.exact="row.dates[dIndex] !== null ? select(mIndex, rIndex, eIndex, dIndex) : null" @click.exact="row.dates[dIndex] !== null ? select(mIndex, rIndex, eIndex, dIndex) : null"
@click.ctrl.exact="row.dates[dIndex] !== null ? ctrlSelect(mIndex, rIndex, eIndex, dIndex) : null" @click.ctrl.exact="row.dates[dIndex] !== null ? ctrlSelect(mIndex, rIndex, eIndex, dIndex) : null"
@click.shift.exact="row.dates[dIndex] !== null ? shiftSelect(mIndex, rIndex, eIndex, dIndex) : null" @click.shift.exact="row.dates[dIndex] !== null ? shiftSelect(mIndex, rIndex, eIndex, dIndex) : null"
) )
tr() tr()
td.text-end td().text-end
button( button(
class="btn" class="btn btn-sm"
@click="addEmployeeRow = rIndex; addEmployeeMonth = mIndex" @click="addEmployeeRow = rIndex; addEmployeeMonth = mIndex"
data-bs-toggle="modal" data-bs-toggle="modal"
:data-bs-target="'#'+modalId" :data-bs-target="'#'+modalId"
) )
i.bi.bi-plus-lg i.bi.bi-plus-lg
td(v-for="(date, dIndex) in row.dates" :key="dIndex" :class="{'bg-secondary bg-opacity-10' : row.dates[dIndex] === null}")   td(
v-for="(date, dIndex) in row.dates"
:key="dIndex"
:style="dIndex === 6 ? 'border-right : 2px solid' : ''"
:class="{'bg-secondary bg-opacity-10' : row.dates[dIndex] === null}"
)  
</template> </template>