+ | {{ item.id }} |
{{ item.name }} |
- {{ item.result }} |
- {{ item.created_at }} |
+ {{ item.size }} |
fas fa-eye
@@ -104,18 +103,18 @@ export default {
headers: [
{
sortable: true,
+ text: "ID",
+ value: "id"
+ },
+ {
+ sortable: false,
text: "Name",
value: "name"
},
{
sortable: false,
- text: "Result",
- value: "result"
- },
- {
- sortable: false,
- text: "Date",
- value: "date"
+ text: "Size",
+ value: "size"
},
{
sortable: false,
@@ -126,9 +125,8 @@ export default {
],
filter: {
name: '',
- result: '',
+ size: '',
},
- result: ['Pass', 'Fail'],
items: [],
currentPage: 1,
lastPage: 1,
@@ -180,34 +178,12 @@ export default {
}
}
}
- },
- async generateBarcode(code) {
- const result = await ApiService.post(urls.Barcode(code));
- if (result && result.status == 200) {
- this.changeCurrentModal({
- modal: "modal-barcode-barcode",
- properties: { result }
- });
- }
}
},
- computed: {
- ...mapGetters("modal", ["getModalResult"])
- },
watch: {
currentPage(page) {
this.load(page);
},
- getModalResult(testResult) {
- for (const key in this.items) {
- if (
- this.items.hasOwnProperty(key) &&
- this.items[key].id == testResult.id
- ) {
- this.items[key] = testResult;
- }
- }
- }
}
};
diff --git a/resources/js/vue/views/Pack/AddEdit.vue b/resources/js/vue/views/Pack/AddEdit.vue
index 40fdfd49..d4cde07c 100644
--- a/resources/js/vue/views/Pack/AddEdit.vue
+++ b/resources/js/vue/views/Pack/AddEdit.vue
@@ -1,9 +1,9 @@
-
+
-
+
-
+
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- description
+ Description
@@ -58,7 +111,7 @@
-
+
keyboard_arrow_left
Back
@@ -78,6 +131,8 @@ import { mapMutations } from "vuex";
export default {
data() {
return {
+ fromMenuSterile: false ,
+ fromMenuExpire: false,
formData: {
name: "",
result: "",
@@ -85,7 +140,6 @@ export default {
items: []
},
items: [],
- result: ["Pass", "Fail"],
rules: {
required: value => !!value || "Required.",
counter: value =>
@@ -97,42 +151,53 @@ export default {
};
},
created() {
- if (this.$route.params.package) {
- this.load(this.$route.params.package);
+ if (this.$route.params.pack) {
+ this.load(this.$route.params.pack);
}
this.loadItems();
},
methods: {
async load(id) {
- const result = await ApiService.get(urls.editPackage(id));
+ const result = await ApiService.get(urls.editPack(id));
if (result.status == 200) {
this.formData = result.data.data;
}
},
async loadItems() {
- const result = await ApiService.get(urls.listAllItem());
+ const result = await ApiService.get(urls.listAllPackage());
if (result.status == 200) {
this.items = result.data.data;
}
},
async submitForm() {
let result;
- if (this.$route.params.package) {
+ if (this.$route.params.pack) {
result = await ApiService.put(
- urls.updatePackage(this.$route.params.package),
+ urls.updatePack(this.$route.params.pack),
this.formData
);
} else {
result = await ApiService.post(
- urls.storePackage,
+ urls.storePack,
this.formData
);
}
if (result && result.status == 200) {
- this.$router.push({ name: "AllPackage" });
+ this.$router.push({ name: "AllPack" });
}
}
}
};
-
\ No newline at end of file
+
+
diff --git a/resources/js/vue/views/Pack/List.vue b/resources/js/vue/views/Pack/List.vue
index ecee6854..7275efa5 100644
--- a/resources/js/vue/views/Pack/List.vue
+++ b/resources/js/vue/views/Pack/List.vue
@@ -1,111 +1,110 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- fas fa-search
- Filter
-
-
-
-
-
-
- fas fa-plus
- Add
-
-
-
-
-
-
-
-
-
-
-
-
- {{ item.unique_id }} |
- {{ item.name }} |
- {{ item.result }} |
- {{ item.created_at }} |
-
-
- fas fa-eye
- Show
-
-
-
- fas fa-pen
- Edit
-
-
-
- fas fa-times
- Remove
-
-
- fas fa-barcode
- Generate Barcode
-
- |
-
-
-
-
-
-
-
-
-
-
-
- fas fa-chevron-left
- Back
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ fas fa-search
+ Filter
+
+
+
+
+
+
+ fas fa-plus
+ Add
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ item.name }} |
+ {{ (item.user && item.user.medical_center) ? item.user.medical_center.name : '' }} |
+ {{ item.user ? item.user.name : '' }} |
+ {{ item.cycle_number }} |
+ {{ item.department }} |
+
+
+ fas fa-eye
+ Show
+
+
+
+ fas fa-pen
+ Edit
+
+
+
+ fas fa-times
+ Remove
+
+ |
+
+
+
+
+
+
+
+
+
+
+
+ fas fa-chevron-left
+ Back
+
+
+
+
+
+
diff --git a/resources/js/vue/views/Package/List.vue b/resources/js/vue/views/Package/List.vue
index 6fe6ce15..f0028f82 100644
--- a/resources/js/vue/views/Package/List.vue
+++ b/resources/js/vue/views/Package/List.vue
@@ -11,15 +11,6 @@
color="black"
>
-
-
-
- {{ item.unique_id }} |
+ {{ item.unique_id }} |
{{ item.name }} |
- {{ item.result }} |
- {{ item.created_at }} |
+ {{ item.description }} |
fas fa-eye
@@ -126,14 +116,9 @@ export default {
value: "name"
},
{
- sortable: false,
- text: "Result",
- value: "result"
- },
- {
- sortable: false,
- text: "Date",
- value: "date"
+ sortable: true,
+ text: "Description",
+ value: "description"
},
{
sortable: false,
| |