shish 1 năm trước cách đây
mục cha
commit
6565cef0de

+ 2 - 2
ghs/src/views/order/add-live.vue

@@ -4,7 +4,7 @@
 		<div>
 		<div>
 			<el-select @change="getCurrentItem" v-model="currentItemName" filterable remote reserve-keyword placeholder="搜索花材" clearable ref="itemSearchRef"
 			<el-select @change="getCurrentItem" v-model="currentItemName" filterable remote reserve-keyword placeholder="搜索花材" clearable ref="itemSearchRef"
 			:remote-method="searchItem" style="width:280px;margin-left:30px;margin-top:15px;">
 			:remote-method="searchItem" style="width:280px;margin-left:30px;margin-top:15px;">
-				<el-option v-for="item in itemList" :key="item.id" :label="`${item.name}(${item.id})`" :value="item"> </el-option>
+				<el-option v-for="item in itemList" :key="item.id" :label="`${item.name}( ${item.stock?parseFloat(item.stock):0} )`" :value="item"> </el-option>
 			</el-select>
 			</el-select>
 			<el-input v-model="price" placeholder="请输入价格" style="width:130px;margin-left:10px;"></el-input>
 			<el-input v-model="price" placeholder="请输入价格" style="width:130px;margin-left:10px;"></el-input>
 		</div>
 		</div>
@@ -12,7 +12,7 @@
 		<div>
 		<div>
 			<el-select @change="getCurrentCustom" v-model="currentCustomName" filterable remote reserve-keyword placeholder="搜索客户" clearable ref="customSearchRef"
 			<el-select @change="getCurrentCustom" v-model="currentCustomName" filterable remote reserve-keyword placeholder="搜索客户" clearable ref="customSearchRef"
 			:remote-method="searchCustom" style="width:280px;margin-left:30px;margin-top:15px;">
 			:remote-method="searchCustom" style="width:280px;margin-left:30px;margin-top:15px;">
-				<el-option v-for="item in customList" :key="item.id" :label="`${item.name}(${item.id})`" :value="item"> </el-option>
+				<el-option v-for="item in customList" :key="item.id" :label="`${item.name}(${item.seatSn})`" :value="item"> </el-option>
 			</el-select>
 			</el-select>
 
 
 			<el-input v-model="name1" placeholder="客户名称" size="big" style="width:150px;margin-left:30px;"></el-input>
 			<el-input v-model="name1" placeholder="客户名称" size="big" style="width:150px;margin-left:30px;"></el-input>

+ 18 - 4
ghs/src/views/order/live-list.vue

@@ -25,6 +25,14 @@
             <i class="el-icon-success" style="color:green;font-size:18px;"></i>
             <i class="el-icon-success" style="color:green;font-size:18px;"></i>
           </span>
           </span>
       </template>
       </template>
+
+      <template #table-column-stock="{scope}">
+          <span v-if="scope.row.switchOrder==1">{{ scope.row.stock }}</span>
+          <span v-else>
+            <span v-if="Number(scope.row.stock)>Number(scope.row.itemNum)">{{ scope.row.stock }}</span>
+            <span v-else style="font-weight:bold;color:blue;font-size:20px;">{{ scope.row.stock }}</span>
+          </span>
+      </template>
       
       
       <template #table-column-printOrder="{scope}">
       <template #table-column-printOrder="{scope}">
           <span v-if="scope.row.printOrder==0" @click="printA4(scope.row)" style="cursor: pointer;">
           <span v-if="scope.row.printOrder==0" @click="printA4(scope.row)" style="cursor: pointer;">
@@ -276,6 +284,12 @@ export default {
                 align: 'center',
                 align: 'center',
                 width: '100'
                 width: '100'
               },
               },
+              {
+                prop: 'itemAmount',
+                label: '金额',
+                align: 'center',
+                width: '100'
+              },
               {
               {
                 prop: 'itemNum',
                 prop: 'itemNum',
                 label: '花材数',
                 label: '花材数',
@@ -283,8 +297,8 @@ export default {
                 width: '100'
                 width: '100'
               },
               },
               {
               {
-                prop: 'itemAmount',
-                label: '金额',
+                prop: 'stock',
+                label: '库存',
                 align: 'center',
                 align: 'center',
                 width: '100'
                 width: '100'
               },
               },
@@ -298,7 +312,7 @@ export default {
                 prop: 'staffName',
                 prop: 'staffName',
                 label: '开单人',
                 label: '开单人',
                 align: 'center',
                 align: 'center',
-                width: '120'
+                width: '110'
               },
               },
               {
               {
                 prop: 'printOrder',
                 prop: 'printOrder',
@@ -335,7 +349,7 @@ export default {
             op: {
             op: {
               visible: true,
               visible: true,
               props: {
               props: {
-                width: 240,
+                width: 150,
                 align: 'center',
                 align: 'center',
                 fixed: 'right',
                 fixed: 'right',
                 label: '操作'
                 label: '操作'