Explorar o código

库存:详情

chris %!s(int64=3) %!d(string=hai) anos
pai
achega
b63a0833de

+ 6 - 4
src/views/modules/common/Description.vue

@@ -16,8 +16,8 @@
       .filter(item => item.tag === 'Description')
       .map(item => ({
         tag: item.tag,
-        term: (item.data && item.data.attrs.term) || '暂无',
-        detail: (item.children && item.children[0].text) || '暂无'
+        term: (item.data && item.data.attrs.term) || '',
+        detail: (item.children && item.children[0].text) || ''
       }))
 }
 
@@ -32,7 +32,7 @@ export default {
       },
       col: {
         type: [Number, String],
-        default: 8
+        default: 6
       }
     },
 
@@ -52,7 +52,7 @@ export default {
 <style lang="less" scoped>
   .description_text {
     .title {
-      font-weight: 700;
+      font-weight: 800;
       font-size: 16px;
       line-height: 1.5;
       margin-bottom: 20px;
@@ -67,6 +67,7 @@ export default {
       margin-right: 8px;
       white-space: nowrap;
       display: table-cell;
+      /*min-width: 100px;*/
       &:after {
         content: ":";
         margin: 0 8px 0 2px;
@@ -77,6 +78,7 @@ export default {
     .detail {
       font-size: 14px;
       line-height: 1.5;
+      min-width: 200px;
       width: 100%;
       padding-bottom: 16px;
       color: rgba(0, 0, 0, 0.65);

+ 41 - 4
src/views/modules/warehouse/stock-details.vue

@@ -5,8 +5,27 @@
         :close-on-click-modal="false"
         :visible.sync="visible">
         <DescriptionList title="" col="6" :content="dataForm">
-          <Description term="物料编码">{{dataForm.materialName}}</Description>
-          <Description term="物料名称">{{dataForm.materialName}}</Description>
+          <Description term="编码">{{dataForm.materialName}}</Description>
+          <Description term="名称">{{dataForm.materialName}}</Description>
+          <Description term="类别">{{dataForm.materialTypeId}}</Description>
+        </DescriptionList>
+        <DescriptionList title="" col="6" :content="dataForm">
+          <Description term="规格">{{dataForm.specifications}}</Description>
+          <Description term="单位">{{dataForm.unitName}}</Description>
+          <Description term="数量">{{dataForm.cnt}}</Description>
+        </DescriptionList>
+        <DescriptionList title="" col="6" :content="dataForm">
+          <Description term="单价">{{dataForm.price}}</Description>
+          <Description term="金额">{{dataForm.amount}}</Description>
+          <Description term="批次号"> </Description>
+        </DescriptionList>
+        <DescriptionList title="" col="6" :content="dataForm">
+          <Description term="来源"></Description>
+          <Description term="存放仓库">{{dataForm.warehouseId}}</Description>
+          <Description term="存放货架">{{dataForm.shelveName}}</Description>
+        </DescriptionList>
+        <DescriptionList title="" col="6" :content="dataForm">
+          <Description term="备注说明">{{dataForm.notes}}</Description>
         </DescriptionList>
         <span slot="footer" class="dialog-footer">
           <el-button @click="visible = false">取消</el-button>
@@ -19,13 +38,22 @@
   import DescriptionList from '../common/Description'
   export default {
     name: 'stock-details',
-    components: { DescriptionList},
+    components: {DescriptionList},
     data () {
       return {
         visible: false,
         dataForm: {
           materialId: 0,
-          materialName: ''
+          materialName: '',
+          materialTypeId: '',
+          specifications: '',
+          unitName: '',
+          cnt: '',
+          price: '',
+          amount: '',
+          warehouseId: '',
+          shelveName: '',
+          notes: ''
         }
       }
     },
@@ -43,6 +71,15 @@
               this.visible = true
               this.dataForm.materialId = data.data.materialId
               this.dataForm.materialName = data.data.materialName
+              this.dataForm.materialTypeId = data.data.materialTypeId
+              this.dataForm.specifications = data.data.specifications
+              this.dataForm.unitName = data.data.unitName
+              this.dataForm.cnt = data.data.cnt
+              this.dataForm.price = data.data.price
+              this.dataForm.amount = data.data.amount
+              this.dataForm.warehouseId = data.data.warehouseId
+              this.dataForm.shelveName = data.data.shelveName
+              this.dataForm.notes = data.data.notes
             } else {
               this.$message.error(data.msg)
             }