mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/shipping-portal.git
synced 2026-08-19 04:24:12 +00:00
update container select packing list
This commit is contained in:
@@ -28,10 +28,11 @@
|
||||
<script>
|
||||
import componentHandler from '../../../general/mixins/componentHandler';
|
||||
export default {
|
||||
data(){
|
||||
return {
|
||||
selected: false,
|
||||
}
|
||||
props: {
|
||||
selectedPackageList: {
|
||||
type: Array,
|
||||
required: false,
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
activate(){
|
||||
@@ -45,6 +46,15 @@
|
||||
},
|
||||
noPackage() {
|
||||
return ( this.item.packages.reduce((total, obj) => 1 + total, 0));
|
||||
},
|
||||
selected() {
|
||||
var response = false;
|
||||
this.selectedPackageList.forEach((value, index) => {
|
||||
if (value.id == this.item.id) {
|
||||
response = true;
|
||||
}
|
||||
});
|
||||
return response;
|
||||
}
|
||||
},
|
||||
mixins: [componentHandler]
|
||||
|
||||
+1
-1
@@ -455,7 +455,7 @@
|
||||
</div>
|
||||
<div class="row" v-for="packingList in container.packing_lists">
|
||||
<div class="col">
|
||||
<list-packagelist-form-component :data="packingList" v-on:input="updateList($event)"></list-packagelist-form-component>
|
||||
<list-packagelist-form-component :data="packingList" :selectedPackageList="selectedPackageList" v-on:input="updateList($event)"></list-packagelist-form-component>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user