mirror of
https://git.meshkee.com/cssd/cssd-back.git
synced 2026-10-14 03:11:07 +03:30
Merge branch 'master' of https://git.meshkee.com/cssd/cssd-back
This commit is contained in:
Vendored
+1
-1
@@ -4,7 +4,7 @@ const urls = {
|
||||
},
|
||||
showItem: function(id) {
|
||||
// return `/ShowItem/${id}`;
|
||||
return `/show-item/${id}`;
|
||||
return `/api/show-item/${id}`;
|
||||
|
||||
},
|
||||
showPackage: function(id) {
|
||||
|
||||
Vendored
+10
-5
@@ -16,26 +16,31 @@ export default [
|
||||
{
|
||||
path: '/Show/Item/:item',
|
||||
name: 'ShowItem',
|
||||
view: 'Item/ShowItem'
|
||||
view: 'Item/ShowItem',
|
||||
meta: {public: true}
|
||||
},
|
||||
{
|
||||
path: '/Show/Package/:package',
|
||||
name: 'ShowPackage',
|
||||
view: 'Package/ShowPackage'
|
||||
view: 'Package/ShowPackage',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/Show/Label/:label',
|
||||
name: 'ShowLabel',
|
||||
view: 'Label/ShowLabel'
|
||||
view: 'Label/ShowLabel',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/Show/Cycle/:cycle',
|
||||
name: 'ShowCycle',
|
||||
view: 'Cycle/ShowCycle'
|
||||
view: 'Cycle/ShowCycle',
|
||||
meta: { public: true }
|
||||
},
|
||||
{
|
||||
path: '/Show/TestResult/:id',
|
||||
name: 'ShowTestResult',
|
||||
view: 'TestResult/ShowTestResult'
|
||||
view: 'TestResult/ShowTestResult',
|
||||
meta: { public: true }
|
||||
},
|
||||
]
|
||||
|
||||
@@ -113,9 +113,12 @@ export default {
|
||||
const result = await axios.get(urls.showItem(id));
|
||||
if (result.status == 200) {
|
||||
this.data = result.data.data;
|
||||
console.log(result,'result',result.data,result.data.data)
|
||||
if(this.data){
|
||||
this.generateBarcode(this.data.id);
|
||||
this.MedicalCenter = this.data.user.medical_center.name;
|
||||
}
|
||||
}
|
||||
} catch (error) {
|
||||
console.error("Error loading data:", error);
|
||||
}
|
||||
|
||||
@@ -227,8 +227,8 @@ export default {
|
||||
}
|
||||
},
|
||||
created() {
|
||||
console.log(this.$route.params.label,'this.$route.params');
|
||||
if (this.$route.params.label) {
|
||||
console.log(this.$route.params);
|
||||
this.load(this.$route.params.label);
|
||||
}
|
||||
},
|
||||
|
||||
@@ -10,25 +10,32 @@
|
||||
<v-flex xs12 md6 sm6>
|
||||
<div class="WM-d-flex">
|
||||
<v-icon class="WMi-info"></v-icon>
|
||||
<span class="headline ml-1 CSSD-font" style="letter-spacing:0 !important">{{ data.name }}</span>
|
||||
<span class="headline ml-1 CSSD-font" style="letter-spacing:0 !important">{{
|
||||
data.name
|
||||
}}</span>
|
||||
</div>
|
||||
</v-flex>
|
||||
<v-flex xs12 md6 sm6>
|
||||
<div class="WM-d-flex">
|
||||
<v-icon class="WMi-Industry"></v-icon>
|
||||
<span class="headline ml-2 CSSD-font" style="letter-spacing:0 !important">{{ data.created_at }}</span>
|
||||
<span class="headline ml-2 CSSD-font" style="letter-spacing:0 !important">{{
|
||||
data.created_at
|
||||
}}</span>
|
||||
</div>
|
||||
</v-flex>
|
||||
<v-flex xs12 md6 sm6>
|
||||
<div class="WM-d-flex">
|
||||
<v-icon class="WMi-user"></v-icon>
|
||||
<span class="headline ml-2 CSSD-font" style="letter-spacing:0 !important">{{ data.user ? data.user.name : '' }}</span>
|
||||
<span class="headline ml-2 CSSD-font"
|
||||
style="letter-spacing:0 !important">{{ data.user ? data.user.name : '' }}</span>
|
||||
</div>
|
||||
</v-flex>
|
||||
<v-flex xs12 md6 sm6>
|
||||
<div class="WM-d-flex">
|
||||
<v-icon class="WMi-pencil"></v-icon>
|
||||
<span class="headline ml-1 CSSD-font" style="letter-spacing:0 !important">{{ data.note }}</span>
|
||||
<span class="headline ml-1 CSSD-font" style="letter-spacing:0 !important">{{
|
||||
data.note
|
||||
}}</span>
|
||||
</div>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
@@ -97,6 +104,7 @@
|
||||
<script>
|
||||
import axios from "axios";
|
||||
import {urls} from "@show/config/urls";
|
||||
|
||||
export default {
|
||||
data: () => ({
|
||||
data: {},
|
||||
@@ -110,9 +118,12 @@ export default {
|
||||
|
||||
if (result.status == 200) {
|
||||
this.data = result.data.data;
|
||||
console.log(result,'result')
|
||||
if (this.data) {
|
||||
this.generateBarcode(this.data.id);
|
||||
this.MedicalCenter = this.data.user.medical_center.name;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
async generateBarcode(packageId) {
|
||||
@@ -163,7 +174,6 @@ export default {
|
||||
}
|
||||
},
|
||||
created() {
|
||||
console.log('------------------',this.$route.params,'------------------')
|
||||
if (this.$route.params.package) {
|
||||
this.load(this.$route.params.package);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user