mirror of
https://git.meshkee.com/cssd/cssd-back.git
synced 2026-10-10 19:11:07 +03:30
fix : try to fix vue part
This commit is contained in:
Generated
-17224
File diff suppressed because it is too large
Load Diff
Vendored
+2
-1
@@ -3,7 +3,8 @@ const urls = {
|
||||
return `/ShowTestResult/${id}`;
|
||||
},
|
||||
showItem: function(id) {
|
||||
return `/Items/${id}`;
|
||||
return `/ShowItem/${id}`;
|
||||
|
||||
},
|
||||
showPackage: function(id) {
|
||||
return `/ShowPackage/${id}`;
|
||||
|
||||
@@ -103,13 +103,16 @@ export default {
|
||||
}),
|
||||
methods: {
|
||||
async load(id) {
|
||||
const result = await axios.get(urls.showItem(id));
|
||||
|
||||
if (result.status == 200) {
|
||||
this.data = result.data.data;
|
||||
this.generateBarcode(this.data.id);
|
||||
this.MedicalCenter = this.data.user.medical_center.name;
|
||||
}
|
||||
try {
|
||||
const result = await axios.get(urls.showItem(id));
|
||||
if (result.status == 200) {
|
||||
this.data = result.data.data;
|
||||
this.generateBarcode(this.data.id);
|
||||
this.MedicalCenter = this.data.user.medical_center.name;
|
||||
}
|
||||
} catch (error) {
|
||||
console.error("Error loading data:", error);
|
||||
}
|
||||
},
|
||||
|
||||
async generateBarcode(itemId) {
|
||||
@@ -160,10 +163,9 @@ export default {
|
||||
}
|
||||
},
|
||||
created() {
|
||||
if (this.$route.params.item) {
|
||||
// console.log(this.$route.params.item);
|
||||
this.load(this.$route.params.item);
|
||||
}
|
||||
if (this.$route.params.Item) {
|
||||
this.load(this.$route.params.Item);
|
||||
}
|
||||
},
|
||||
// mounted() {
|
||||
// this.generateBarcode(this.data.id);
|
||||
|
||||
@@ -143,7 +143,7 @@
|
||||
</template>
|
||||
</v-layout>
|
||||
</v-layout>
|
||||
<v-layout align-left justify-left wrap class="px-5 my-3">
|
||||
<v-layout align-left justify-left wrap class="my-3">
|
||||
<h3 class="ml-3 CSSD-font">Image</h3>
|
||||
<v-flex xs12>
|
||||
<hr class="v-divider theme--light" />
|
||||
|
||||
Vendored
+1
@@ -117,6 +117,7 @@ export default [
|
||||
view: 'TestResult/Show',
|
||||
meta: {
|
||||
public: true,
|
||||
title:'Show Test Result | CSSD Dashboard'
|
||||
},
|
||||
},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user