已修改4个文件
220 ■■■■■ 文件已修改
src/views/productionManagement/productionReporting/index.vue 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/productionManagement/workOrder/index.vue 28 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/qualityManagement/finalInspection/components/formDia.vue 24 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/salesManagement/salesLedger/index.vue 143 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/productionManagement/productionReporting/index.vue
@@ -43,6 +43,7 @@
                @selection-change="handleSelectionChange"
                :tableLoading="tableLoading"
                @pagination="pagination"
                :rowClassName="rowClassName"
                :total="page.total">
        <template #productNoSlot="{ row }">
          <el-button
@@ -240,6 +241,16 @@
    width: 120,
  },
  {
    label: "合格率",
    prop: "actualQualifiedRate",
    width: 120,
  },
  {
    label: "标准合格率",
    prop: "processQualifiedRate",
    width: 120,
  },
  {
    label: "单位",
    prop: "unit",
    width: 120,
@@ -302,6 +313,14 @@
  }
  handleQuery();
};
const rowClassName = ({row}) => {
  if (Number(row.actualQualifiedRate) < Number(row.processQualifiedRate)) {
    return 'danger-row';
  }
  return '';
};
const deleteReport = row => {
  ElMessageBox.confirm("确定删除该报工吗?", "提示", {
    confirmButtonText: "确定",
@@ -476,4 +495,8 @@
});
</script>
<style scoped></style>
<style scoped>
:deep(.danger-row td) {
  color: #e95a66 !important;
}
</style>
src/views/productionManagement/workOrder/index.vue
@@ -12,6 +12,17 @@
                    clearable
                    prefix-icon="Search"/>
        </div>
        <div class="search-item">
          <span class="search_title">生产订单号:</span>
          <el-input v-model="searchForm.productOrderNpsNo"
                    style="width: 240px"
                    placeholder="请输入"
                    @change="handleQuery"
                    clearable
                    prefix-icon="Search"/>
        </div>
        <div class="search-item">
          <el-button type="primary"
                     @click="handleQuery">搜索
@@ -25,6 +36,7 @@
                :tableData="tableData"
                :page="page"
                :tableLoading="tableLoading"
                :rowClassName="rowClassName"
                @pagination="pagination">
        <template #completionStatus="{ row }">
          <el-progress :percentage="toProgressPercentage(row?.completionStatus)"
@@ -289,7 +301,7 @@
  //   width: "80",
  // },
  {
    label: "工单编号",
    label: "工单编号1",
    prop: "workOrderNo",
    width: "140",
  },
@@ -460,6 +472,13 @@
  ]
};
const rowClassName = ({row}) => {
  if (Number(row.completionStatus) > 0 && Number(row.actualQualifiedRate) < Number(row.processQualifiedRate)) {
    return 'danger-row';
  }
  return '';
};
// 处理本次生产数量输入,限制必须大于等于1
const handleQuantityInput = (value) => {
  if (value === '' || value === null || value === undefined) {
@@ -523,6 +542,7 @@
const data = reactive({
  searchForm: {
    workOrderNo: "",
    productOrderNpsNo: "",
  },
});
const {searchForm} = toRefs(data);
@@ -875,7 +895,11 @@
}
</style>
<style lang="scss">
<style lang="scss" scoped>
:deep(.danger-row td) {
  color: #e95a66 !important;
}
@media print {
  @page {
    size: landscape;
src/views/qualityManagement/finalInspection/components/formDia.vue
@@ -2,7 +2,7 @@
  <div>
    <el-dialog
        v-model="dialogFormVisible"
        :title="operationType === 'add' ? '新增出厂检验' : '编辑出厂检验'"
        :title="operationType === 'add' ? '新增成品检验' : '编辑成品检验'"
        width="70%"
        @close="closeDia"
    >
@@ -71,10 +71,11 @@
        </el-row>
        <el-row :gutter="30">
          <el-col :span="12">
            <el-form-item label="检测单位:" prop="checkCompany">
              <el-input v-model="form.checkCompany" placeholder="请输入" clearable/>
            <el-form-item label="不良数量:" prop="defectiveQuantity">
              <el-input v-model="form.defectiveQuantity" placeholder="请输入" clearable disabled/>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="检测结果:" prop="checkResult">
              <el-select v-model="form.checkResult">
@@ -86,11 +87,8 @@
        </el-row>
        <el-row :gutter="30">
          <el-col :span="12">
            <el-form-item label="检验员:" prop="checkName">
                            <el-select v-model="form.checkName" placeholder="请选择" clearable>
                                <el-option v-for="item in userList" :key="item.nickName" :label="item.nickName"
                                                     :value="item.nickName"/>
                            </el-select>
            <el-form-item label="检测单位:" prop="checkCompany">
              <el-input v-model="form.checkCompany" placeholder="请输入" clearable/>
            </el-form-item>
          </el-col>
          <el-col :span="12">
@@ -107,6 +105,16 @@
            </el-form-item>
          </el-col>
        </el-row>
        <el-row :gutter="30">
          <el-col :span="12">
            <el-form-item label="检验员:" prop="checkName">
                            <el-select v-model="form.checkName" placeholder="请选择" clearable>
                                <el-option v-for="item in userList" :key="item.nickName" :label="item.nickName"
                                                     :value="item.nickName"/>
                            </el-select>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>
            <PIMTable
                rowKey="id"
src/views/salesManagement/salesLedger/index.vue
@@ -482,50 +482,76 @@
                        <div class="delivery-note">
                            <div class="header">
                                <div class="company-name">湖南鹏创电子有限公司</div>
                                <div class="document-title">零售发货单</div>
                                <div class="document-title">送货单</div>
                            </div>
                            
                            <div class="info-section">
                                <div class="info-row">
                                    <div>
                                        <span class="label">发货日期:</span>
                                        <span class="value">{{ formatDate(item.createTime) }}</span>
                                    </div>
                                    <div>
                                        <span class="label">发货车牌号:</span>
                                        <span class="value">{{ item.shippingCarNumber }}</span>
                                    </div>
                  <div>
                    <span class="label">客户名称:</span>
                    <span class="value">{{ item.customerName }}</span>
                  </div>
                  <div>
                    <span class="label">送货地址:</span>
                    <span class="value">{{ item.companyAddress }}</span>
                  </div>
                                </div>
                                <div class="info-row">
                                    <div>
                                        <span class="label">客户名称:</span>
                                        <span class="value">{{ item.customerName || '张爱有' }}</span>
                                    </div>
                                    <span class="label">单号:</span>
                                    <span class="value">{{ item.salesContractNo }}</span>
                  <div>
                    <span class="label">单据编号:</span>
                    <span class="value">{{ item.salesContractNo }}</span>
                  </div>
                  <div>
                    <span class="label">送货日期:</span>
                    <span class="value">{{ formatDate(null) }}</span>
                  </div>
                  <div>
                    <span class="label">联系电话:</span>
                    <span class="value">{{ item.contactPhone }}</span>
                  </div>
                                </div>
                            </div>
              <div class="info-section">
                <div class="info-row">
                  <div>
                    <span class="label">联系方式:</span>
                    <span class="value"></span>
                  </div>
                  <div>
                    <span class="label">送货单位:</span>
                    <span class="value">湖南鹏创电子有限公司</span>
                  </div>
                  <div>
                    <span class="label">地址:</span>
                    <span class="value">湖南耒阳市创新创业园A1栋</span>
                  </div>
                </div>
              </div>
              <span style="font-size: 16px;">货物详细信息:</span>
                            <div class="table-section">
                                <table class="product-table">
                                    <thead>
                                    <tr>
                                        <th>产品名称</th>
                                        <th>规格型号</th>
                                        <th>序号</th>
                                        <th>物料编号</th>
                                        <th>品名/规格</th>
                                        <th>单位</th>
                                        <th>单价</th>
                                        <th>零售数量</th>
                                        <th>零售金额</th>
                                        <th>数量</th>
                                        <th>订单号</th>
                                    </tr>
                                    </thead>
                                    <tbody>
                                    <tr v-for="product in item.products" :key="product.id">
                                        <td>{{ product.productCategory || '' }}</td>
                                        <td>{{ product.specificationModel || '' }}</td>
                                    <tr v-for="(product, index) in item.products" :key="product.id">
                                        <td>{{ index + 1 }}</td>
                                        <td>{{ product.productNo || '' }}</td>
                                        <td>{{`${product.productCategory || ''}/${product.specificationModel || ''}` }}</td>
                                        <td>{{ product.unit || '' }}</td>
                                        <td>{{ product.taxInclusiveUnitPrice || '0' }}</td>
                                        <td>{{ product.quantity || '0' }}</td>
                                        <td>{{ product.taxInclusiveTotalPrice || '0' }}</td>
                                        <td>{{ item.salesContractNo || '' }}</td>
                                    </tr>
                                    <tr v-if="!item.products || item.products.length === 0">
                                        <td colspan="6" style="text-align: center; color: #999;">暂无产品数据</td>
@@ -533,43 +559,30 @@
                                    </tbody>
                                    <tfoot>
                                    <tr>
                                        <td class="label"></td>
                                        <td class="label">合计</td>
                                        <td class="total-value"></td>
                                        <td class="total-value"></td>
                                        <td class="total-value"></td>
                                        <td class="total-value">{{ getTotalQuantity(item.products) }}</td>
                                        <td class="total-value">{{ getTotalAmount(item.products) }}</td>
                                        <td class="total-value"></td>
                                    </tr>
                                    </tfoot>
                                </table>
                <div style="width: 30px;">
                  共四联存根回单客户仓库
                </div>
                            </div>
                            <div class="footer-section">
                                <div class="footer-row">
                                    <div class="footer-item">
                                        <span class="label">收货电话:</span>
                                        <span class="value"></span>
                                    </div>
                                    <div class="footer-item">
                                        <span class="label">收货人:</span>
                                        <span class="value"></span>
                                    </div>
                                    <div class="footer-item address-item">
                                        <span class="label">收货地址:</span>
                                        <span class="value address-value"></span>
                                    </div>
                                </div>
                                <div class="footer-row">
                                    <div class="footer-item">
                                        <span class="label">操作员:</span>
                                        <span class="value">{{ userStore.nickName || '撕开前' }}</span>
                                    </div>
                                    <div class="footer-item">
                                        <span class="label">打印日期:</span>
                                        <span class="value">{{ formatDateTime(new Date()) }}</span>
                                    </div>
                                </div>
                            </div>
              <el-descriptions :column="1">
                <el-descriptions-item label="备注:">贵公司在收货后请即刻核实数量及品质,若有异议,请在3日内提出,否则视为收妥。</el-descriptions-item>
              </el-descriptions>
              <el-descriptions :column="2">
                <el-descriptions-item label="送货单位(签章):"/>
                <el-descriptions-item label="收货单位:"/>
                <el-descriptions-item label="送货人:"/>
                <el-descriptions-item label="收货人:"/>
              </el-descriptions>
                        </div>
                    </div>
                </div>
@@ -1588,7 +1601,7 @@
        }
        .label {
          font-weight: bold;
          width: 60px;
          min-width: 60px;
          font-size: 12px;
        }
        .value {
@@ -1633,7 +1646,7 @@
        }
        .footer-item .label {
          font-weight: bold;
          width: 80px;
          min-width: 80px;
          font-size: 12px;
        }
        .footer-item .value {
@@ -1782,13 +1795,14 @@
};
// 格式化日期
const formatDate = (dateString) => {
    if (!dateString) return getCurrentDate();
    if (!dateString) return getCurrentDate().replace(/-/g, '/');
    const date = new Date(dateString);
    const year = date.getFullYear();
    const month = String(date.getMonth() + 1).padStart(2, "0");
    const day = String(date.getDate()).padStart(2, "0");
    return `${year}/${month}/${day}`;
};
// 格式化日期时间
const formatDateTime = (date) => {
    const year = date.getFullYear();
@@ -2249,7 +2263,7 @@
.print-page {
    width: 220mm;
    height: 90mm;
    min-height: 90mm;
    padding: 10mm;
    margin: 0 auto;
    background: white;
@@ -2310,6 +2324,7 @@
.table-section {
    margin-bottom: 4px;
    flex: 1;
  display: flex;
    
    .product-table {
        width: 100%;
@@ -2344,20 +2359,22 @@
        display: flex;
        margin-bottom: 3px;
        line-height: 20px;
        justify-content: space-between;
        justify-content: flex-start;
        
        .footer-item {
            display: flex;
      align-items: center;
            margin-right: 20px;
            .label {
                font-weight: bold;
                width: 80px;
        white-space: nowrap;
        margin-right: 10px;
                font-size: 14px;
            }
            
            .value {
                min-width: 80px;
                min-width: 300px;
                font-size: 14px;
            }