zh před 2 roky
rodič
revize
21d927900c

+ 1 - 1
src/views/sales_control/sales_management/components/customer_sales_details.vue

@@ -16,7 +16,7 @@
         </el-button>
       </template>
     </sales-table>
-    <LogisticsTabs v-if="details.status == 2 && details.stockType == 1 " style="margin:20px;" :details-id="detailsId" :jiaxian-order-id="details.jiaxianOrderId"/>
+    <LogisticsTabs v-if="details.status == 2 && details.stockType == 1 " :return-show="false" style="margin:20px;" :details-id="detailsId" :jiaxian-order-id="details.jiaxianOrderId"/>
     <sales-dialog
       :dialog-visible="dialogVisible"
       :customer-number="customerNumber"

+ 270 - 149
src/views/sales_policy/components/TabelTransfer.vue

@@ -1,47 +1,52 @@
 <template>
   <div class="mymain-container">
+    <!-- 经销商信息 -->
     <slot name="header">
       <el-row class="radio">
         <el-radio-group v-model="region">
           <el-radio label="0">指定经销商</el-radio>
           <el-radio
-            label="1"
             v-if="!adminWebsit || !adminWebsit.websitNumber || (adminWebsit && adminWebsit.websitNumber === 'GZ')"
-            >广州经销商</el-radio
-          >
+            label="1"
+          >广州经销商</el-radio>
           <el-radio
-            label="2"
             v-if="!adminWebsit || !adminWebsit.websitNumber || (adminWebsit && adminWebsit.websitNumber === 'FS')"
-            >佛山经销商</el-radio
-          >
+            label="2"
+          >佛山经销商</el-radio>
         </el-radio-group>
-        <template  v-if="region == 0">
+        <template v-if="region == 0">
           <el-upload
-           class="import-btn"
-          :action="baseURL + 'student/import'"
-          :http-request="handleImport"
-          :file-list="importFileList"
-          :show-file-list="false"
-        >
-          <el-button type="primary" size="mini">导入经销商</el-button>
-        </el-upload>
-        <el-button  type="primary" size="mini" @click="hanleDownloadFiles">下载模板</el-button>
+            class="import-btn"
+            :action="baseURL + 'student/import'"
+            :http-request="handleImport"
+            :file-list="importFileList"
+            :show-file-list="false"
+          >
+            <el-button type="primary" size="mini">导入经销商</el-button>
+          </el-upload>
+          <el-button type="primary" size="mini" @click="hanleDownloadFiles">下载模板</el-button>
         </template>
       </el-row>
-      <el-row type="flex" v-if="region == 0">
+      <el-row v-if="region == 0" type="flex">
         <el-col :xs="24" :sm="12" :lg="14">
           <el-input v-model="keyword" placeholder="查找经销商" size="mini" />
         </el-col>
-        <el-col :xs="24" :sm="1" :lg="1" style="margin-left: 10px"
-          ><el-button size="mini" @click="submitScreenForm">确定</el-button></el-col
-        >
-        <el-col :xs="24" :sm="1" :lg="1" style="margin-left: 20px"
-          ><el-button size="mini" @click="resetScreenForm">重置</el-button></el-col
-        >
+        <el-col
+          :xs="24"
+          :sm="1"
+          :lg="1"
+          style="margin-left: 10px"
+        ><el-button size="mini" @click="submitScreenForm">确定</el-button></el-col>
+        <el-col
+          :xs="24"
+          :sm="1"
+          :lg="1"
+          style="margin-left: 20px"
+        ><el-button size="mini" @click="resetScreenForm">重置</el-button></el-col>
       </el-row>
     </slot>
-    <el-row :gutter="20" v-if="region == 0">
-      <el-col :span="10" :offset="0" >
+    <el-row v-if="region == 0" :gutter="20">
+      <el-col :span="10" :offset="0">
         <h5>未选经销商</h5>
         <el-divider direction="horizontal" content-position="left" />
         <div class="table">
@@ -62,12 +67,15 @@
             <!--            label="经销商编码"-->
             <!--            align="left"-->
             <!--          />-->
-            <el-table-column prop="name" label="经销商名称" align="left"
-              ><template slot-scope="scope">
-                <CopyButton :copy-text="scope.row.name" />
-                <span>{{ scope.row.name }}</span>
-                <span class="red">{{scope.row.number}}</span>
-              </template>
+            <el-table-column
+              prop="name"
+              label="经销商名称"
+              align="left"
+            ><template slot-scope="scope">
+              <CopyButton :copy-text="scope.row.name" />
+              <span>{{ scope.row.name }}</span>
+              <span class="red">{{ scope.row.number }}</span>
+            </template>
             </el-table-column>
           </el-table>
         </div>
@@ -116,133 +124,247 @@
               <template slot-scope="scope">
                 <CopyButton :copy-text="scope.row.customerName" />
                 <span>{{ scope.row.customerName }}</span>
-                <span class="red">{{scope.row.customerNumber}}</span>
+                <span class="red">{{ scope.row.customerNumber }}</span>
               </template>
             </el-table-column>
           </el-table>
         </div>
       </el-col>
     </el-row>
-    <div>
-      <h4 style="display: inline-block; margin-right: 20px">经销商上限</h4>
-
-      <el-divider />
-    </div>
-    <div style="margin: 20px 0">
-      <el-upload
-        class="import-btn cus-btn"
-        :action="baseURL + 'student/import'"
-        :http-request="handleImports"
-        :file-list="importFileList"
-        :show-file-list="false"
-      >
-        <el-button type="primary" size="mini">导入经销商</el-button>
-      </el-upload>
-      <el-button type="primary" size="mini" @click="hanleDownloadFilesPolicy">下载模板</el-button>
-    </div>
-    <el-row type="flex" style="margin: 20px 0" >
-      <el-col :xs="24" :sm="12" :lg="14">
-        <el-input v-model="keyword2" placeholder="查找经销商" size="mini" />
-      </el-col>
-      <el-col :xs="24" :sm="1" :lg="1" style="margin-left: 10px"
-        ><el-button size="mini" @click="submitScreenForm2">确定</el-button></el-col
-      >
-      <el-col :xs="24" :sm="1" :lg="1" style="margin-left: 20px"
-        ><el-button size="mini" @click="resetScreenForm2">重置</el-button></el-col
-      >
-    </el-row>
-    <div >
-      <div class="table">
-        <el-table
-          v-loading="clistLoading"
-          :data="list"
-          element-loading-text="Loading"
-          border
-          fit
-          highlight-current-row
-          stripe
-          @select-all="handleSelectionAllChange2"
-          @selection-change="handleSelectionChange2"
+    <!-- 销售政策类型 ———— 限量-->
+    <div v-if="policyType === 'LIMIT'">
+      <div>
+        <h4 style="display: inline-block; margin-right: 20px">经销商上限</h4>
+        <el-divider />
+      </div>
+      <div style="margin: 20px 0">
+        <el-upload
+          class="import-btn cus-btn"
+          :action="baseURL + 'student/import'"
+          :http-request="handleImports"
+          :file-list="importFileList"
+          :show-file-list="false"
         >
-          <!-- <el-table-column type="selection" width="55" align="left" /> -->
-          <el-table-column
-            prop="customerNumber"
-            label="经销商编号
-"
-            align="left"
-          >
-            <template slot-scope="scope">
-              <CopyButton :copy-text="scope.row.customerNumber" />
-              <span>{{ scope.row.customerNumber }}</span>
-            </template>
-          </el-table-column>
-          <el-table-column prop="customerName" label="经销商名称" align="left">
-            <template slot-scope="scope">
-              <CopyButton :copy-text="scope.row.customerName" />
-              <span>{{ scope.row.customerName }}</span>
-            </template>
-          </el-table-column>
-          <el-table-column
-            prop="materialName"
-            label="物料名称
-
-"
-            align="left"
+          <el-button type="primary" size="mini">导入经销商</el-button>
+        </el-upload>
+        <el-button type="primary" size="mini" @click="hanleDownloadFilesPolicy">下载模板</el-button>
+      </div>
+      <el-row type="flex" style="margin: 20px 0">
+        <el-col :xs="24" :sm="12" :lg="14">
+          <el-input v-model="keyword2" placeholder="查找经销商" size="mini" />
+        </el-col>
+        <el-col
+          :xs="24"
+          :sm="1"
+          :lg="1"
+          style="margin-left: 10px"
+        ><el-button size="mini" @click="submitScreenForm2">确定</el-button></el-col>
+        <el-col
+          :xs="24"
+          :sm="1"
+          :lg="1"
+          style="margin-left: 20px"
+        ><el-button size="mini" @click="resetScreenForm2">重置</el-button></el-col>
+      </el-row>
+      <div>
+        <div class="table">
+          <el-table
+            v-loading="clistLoading"
+            :data="list"
+            element-loading-text="Loading"
+            border
+            fit
+            highlight-current-row
+            stripe
+            @select-all="handleSelectionAllChange2"
+            @selection-change="handleSelectionChange2"
           >
-            <template slot-scope="scope">
-              <CopyButton :copy-text="scope.row.materialName" />
-              <span>{{ scope.row.materialName }}</span>
-            </template>
-          </el-table-column>
-          <el-table-column
-            prop="materialNumber"
-            label="物料编号
+            <el-table-column
+              prop="customerNumber"
+              label="经销商编号
 "
-            align="left"
-          >
-            <template slot-scope="scope">
-              <CopyButton :copy-text="scope.row.materialNumber" />
-              <span>{{ scope.row.materialNumber }}</span>
-            </template>
-          </el-table-column>
+              align="left"
+            >
+              <template slot-scope="scope">
+                <CopyButton :copy-text="scope.row.customerNumber" />
+                <span>{{ scope.row.customerNumber }}</span>
+              </template>
+            </el-table-column>
+            <el-table-column prop="customerName" label="经销商名称" align="left">
+              <template slot-scope="scope">
+                <CopyButton :copy-text="scope.row.customerName" />
+                <span>{{ scope.row.customerName }}</span>
+              </template>
+            </el-table-column>
+            <el-table-column
+              prop="materialName"
+              label="物料名称
 
-          <el-table-column
-            prop="examineOrderNums"
-            label="已审订单数
 "
-            align="left"
-          >
-            <template slot-scope="scope">
-              {{ scope.row.examineOrderNums | numToFixed }}
-            </template>
-          </el-table-column>
+              align="left"
+            >
+              <template slot-scope="scope">
+                <CopyButton :copy-text="scope.row.materialName" />
+                <span>{{ scope.row.materialName }}</span>
+              </template>
+            </el-table-column>
+            <el-table-column
+              prop="materialNumber"
+              label="物料编号
+"
+              align="left"
+            >
+              <template slot-scope="scope">
+                <CopyButton :copy-text="scope.row.materialNumber" />
+                <span>{{ scope.row.materialNumber }}</span>
+              </template>
+            </el-table-column>
 
-          <el-table-column
-            prop="limitQty"
-            label="购买量上限
+            <el-table-column prop="examineOrderNums" label="已审订单数" align="left">
+              <template slot-scope="scope">
+                {{ scope.row.examineOrderNums | numToFixed }}
+              </template>
+            </el-table-column>
 
-"
-            align="left"
-          >
-            <template slot-scope="scope">
-              {{ scope.row.limitQty | numToFixed }}
-            </template>
-          </el-table-column>
-        </el-table>
+            <el-table-column prop="limitQty" label="购买量上限" align="left">
+              <template slot-scope="scope">
+                {{ scope.row.limitQty | numToFixed }}
+              </template>
+            </el-table-column>
+          </el-table>
+        </div>
+        <!-- 分页 -->
+        <div style="margin: 20px 0">
+          <el-pagination
+            :current-page="policyList.currentPages"
+            :page-sizes="[10, 20, 30, 50]"
+            :page-size="10"
+            layout="total, sizes, prev, pager, next, jumper"
+            :total="cTotal"
+            @size-change="handleSizeChanges2"
+            @current-change="handleCurrentChanges2"
+          />
+        </div>
+      </div>
+    </div>
+    <!-- 销售政策类型 ————  配提 综合 -->
+    <div v-else>
+      <div>
+        <h4 style="display: inline-block; margin-right: 20px">经销商上限</h4>
+        <el-divider />
       </div>
-      <!-- 分页 -->
       <div style="margin: 20px 0">
-        <el-pagination
-          :current-page="policyList.currentPages"
-          :page-sizes="[10, 20, 30, 50]"
-          :page-size="10"
-          layout="total, sizes, prev, pager, next, jumper"
-          :total="cTotal"
-          @size-change="handleSizeChanges2"
-          @current-change="handleCurrentChanges2"
-        />
+        <el-upload
+          class="import-btn cus-btn"
+          :action="baseURL + 'student/import'"
+          :http-request="handleImports"
+          :file-list="importFileList"
+          :show-file-list="false"
+        >
+          <el-button type="primary" size="mini">导入经销商</el-button>
+        </el-upload>
+        <el-button type="primary" size="mini" @click="hanleDownloadFilesPolicy">下载模板</el-button>
+      </div>
+      <el-row type="flex" style="margin: 20px 0">
+        <el-col :xs="24" :sm="12" :lg="14">
+          <el-input v-model="keyword2" placeholder="查找经销商" size="mini" />
+        </el-col>
+        <el-col
+          :xs="24"
+          :sm="1"
+          :lg="1"
+          style="margin-left: 10px"
+        ><el-button size="mini" @click="submitScreenForm2">确定</el-button></el-col>
+        <el-col
+          :xs="24"
+          :sm="1"
+          :lg="1"
+          style="margin-left: 20px"
+        ><el-button size="mini" @click="resetScreenForm2">重置</el-button></el-col>
+      </el-row>
+      <div style="font-size: 14px;">注:经销商最大提货套数仅与经销商相关联,与机型没有限制关联;机型订货上线仅对机型做限制</div>
+      <div>
+        <div class="table">
+          <el-table
+            v-loading="clistLoading"
+            :data="list"
+            element-loading-text="Loading"
+            border
+            fit
+            highlight-current-row
+            stripe
+            @select-all="handleSelectionAllChange2"
+            @selection-change="handleSelectionChange2"
+          >
+            <el-table-column
+              type="index"
+              width="50"
+            />
+            <el-table-column
+              prop="customerNumber"
+              label="经销商编号
+"
+              align="left"
+            >
+              <template slot-scope="scope">
+                <CopyButton :copy-text="scope.row.customerNumber" />
+                <span>{{ scope.row.customerNumber }}</span>
+              </template>
+            </el-table-column>
+            <el-table-column prop="customerName" label="经销商名称" align="left">
+              <template slot-scope="scope">
+                <CopyButton :copy-text="scope.row.customerName" />
+                <span>{{ scope.row.customerName }}</span>
+              </template>
+            </el-table-column>
+
+            <el-table-column prop="maxBuyNum" label="最大配套套数" align="left">
+              <template slot-scope="scope">
+                {{ scope.row.maxBuyNum }}
+              </template>
+            </el-table-column>
+            <el-table-column prop="examineOrderNums" label="已审订单数" align="left">
+              <template slot-scope="scope">
+                {{ scope.row.examineOrderNums }}
+              </template>
+            </el-table-column>
+            <el-table-column prop="orderNums" label="已下订单数" align="left">
+              <template slot-scope="scope">
+                {{ scope.row.orderNums }}
+              </template>
+            </el-table-column>
+            <el-table-column prop="materialName" label="物料名称" align="left">
+              <template slot-scope="scope">
+                {{ scope.row.materialName }}
+              </template>
+            </el-table-column>
+            <el-table-column prop="materialNumber" label="物料编号" align="left">
+              <template slot-scope="scope">
+                {{ scope.row.materialNumber }}
+              </template>
+            </el-table-column>
+            <el-table-column prop="limitQty" label="订货上限" align="left">
+              <template slot-scope="scope">
+                {{ scope.row.limitQty }}
+              </template>
+            </el-table-column>
+          </el-table>
+        </div>
+        <!-- 分页 -->
+        <div style="margin: 20px 0">
+          <el-pagination
+            :current-page="policyList.currentPages"
+            :page-sizes="[10, 20, 30, 50]"
+            :page-size="10"
+            layout="total, sizes, prev, pager, next, jumper"
+            :total="cTotal"
+            @size-change="handleSizeChanges2"
+            @current-change="handleCurrentChanges2"
+          />
+        </div>
       </div>
     </div>
+    <!-- 操作按钮 -->
     <slot name="footer">
       <el-row style="margin: 20px 0 0 0">
         <el-button type="primary" size="mini" @click="handleSave">
@@ -274,7 +396,7 @@ export default {
   },
   mixins: [Minxin],
   // eslint-disable-next-line vue/require-prop-types
-  props: ['code', 'yregion'],
+  props: ['code', 'yregion', 'policyType'],
   data() {
     return {
       keyword: '',
@@ -395,9 +517,9 @@ export default {
         }
         this.dataL = res.data.records
         for (let k = 0; k < this.dataL.length; k++) {
-          ;(this.dataL[k].customerId = this.dataL[k].id),
-            (this.dataL[k].customerName = this.dataL[k].name),
-            (this.dataL[k].customerNumber = this.dataL[k].number)
+          (this.dataL[k].customerId = this.dataL[k].id),
+          (this.dataL[k].customerName = this.dataL[k].name),
+          (this.dataL[k].customerNumber = this.dataL[k].number)
         }
         this.clistTotal = res.data.total
       })
@@ -529,7 +651,7 @@ export default {
       downloadFiles('policy/limit/download')
     },
     getCommonApi(row) {
-      ;(this.isEdit = 2), (this.cid = row.id), (this.cpolicyId = row.policyId)
+      (this.isEdit = 2), (this.cid = row.id), (this.cpolicyId = row.policyId)
       console.log(this.cpolicyId, this.comCode, this.cpolicyId === this.comCode)
     },
     getCond() {
@@ -575,7 +697,7 @@ export default {
      * @param {String} index - 索引值
      * @return Boolean
      */
-    selectable: function (row, index) {
+    selectable: function(row, index) {
       // row.disabled == undefined 才能被选中
       if (row.disabled === undefined || row.disabled === false) {
         return true
@@ -747,8 +869,7 @@ export default {
   display: flex;
   align-items: center;
 }
-.red{
-
+.red {
   color: #f00;
 }
 </style>

+ 2 - 1
src/views/supply/transferOrder/transferOrderForm.vue

@@ -811,6 +811,7 @@ export default {
             var { value } = props
             return (
               <zj-table
+                style='height: 600px;'
                 tableAttributes={{ ...this.defaultTableAttributes }}
                 isDrop={true}
                 columns={this.formLogistics}
@@ -845,7 +846,7 @@ export default {
           {
             param: 'order_code',
             compare: '=',
-            value: this.detailsId
+            value: this.jiaxianOrderId
           }
         ]
       }).then(res => {