|
|
@@ -53,7 +53,7 @@
|
|
|
</view>
|
|
|
<scroll-view scroll-y="true" class="dropdown-scroll-view" lower-threshold="80"
|
|
|
@scrolltolower="loadMoreProducts">
|
|
|
- <view class="dropdown-item" v-for="(p, i) in productList" :key="getUid()" :style="p.drugEntBaseInfoId === product?.drugEntBaseInfoId || (!product?.drugEntBaseInfoId &&i == 0)
|
|
|
+ <view class="dropdown-item" v-for="(p, i) in productList" :key="getUid()" :style="p.drugEntBaseInfoId === product?.drugEntBaseInfoId || (!product?.drugEntBaseInfoId && i == 0)
|
|
|
? {
|
|
|
backgroundColor: '#2c69ff',
|
|
|
color: '#fff',
|
|
|
@@ -104,7 +104,8 @@
|
|
|
<view class="row" v-for="(item, i) in list" :key="getUid()">
|
|
|
<view v-for="(col, ci) in columns" :key="getUid()" class="cell"
|
|
|
:class="{ underline: col.underline, striped: striped && (i + 1) % 2 === 0 }"
|
|
|
- :style="bodyCellStyle(ci, col)" @click="handleClick(item, col)">{{ item[col.key] || "--" }}</view>
|
|
|
+ :style="bodyCellStyle(ci, col)" @click="handleClick(item, col)">{{ item[col.key] ? (item[col.key] +
|
|
|
+ (col.unit || '')) : '--' }}</view>
|
|
|
</view>
|
|
|
<view class="row loading-row" v-if="hasmore">
|
|
|
<view class="loading-wrapper">
|
|
|
@@ -184,14 +185,17 @@ export default {
|
|
|
{
|
|
|
key: "totalInRate",
|
|
|
title: "入库扫码率",
|
|
|
+ unit: '%'
|
|
|
},
|
|
|
{
|
|
|
key: "totalOutRate",
|
|
|
title: "出库扫码率",
|
|
|
+ unit: '%'
|
|
|
},
|
|
|
{
|
|
|
key: "totalSelfExaminationRate",
|
|
|
title: "自验证率",
|
|
|
+ unit: '%'
|
|
|
},
|
|
|
],
|
|
|
},
|
|
|
@@ -207,10 +211,6 @@ export default {
|
|
|
type: String,
|
|
|
default: "76rpx",
|
|
|
},
|
|
|
- tableWidth: {
|
|
|
- type: String,
|
|
|
- default: "100%",
|
|
|
- },
|
|
|
headerFontSize: {
|
|
|
type: String,
|
|
|
default: "32rpx",
|
|
|
@@ -227,6 +227,11 @@ export default {
|
|
|
type: String,
|
|
|
default: "#2c69ff",
|
|
|
},
|
|
|
+ //若需要横向滚动且左侧固定,则tableWidth需等于columns所有width之和(可以略小于)
|
|
|
+ tableWidth: {
|
|
|
+ type: String,
|
|
|
+ default: "100%",
|
|
|
+ },
|
|
|
columns: {
|
|
|
type: Array,
|
|
|
default: () => [
|
|
|
@@ -234,7 +239,7 @@ export default {
|
|
|
key: "regionName",
|
|
|
title: "区域",
|
|
|
underline: true,
|
|
|
- fixed: false,
|
|
|
+ fixed: true,
|
|
|
width: "",
|
|
|
},
|
|
|
{
|
|
|
@@ -244,6 +249,7 @@ export default {
|
|
|
width: "",
|
|
|
tooltip:
|
|
|
"客户出库扫码量(与下游入库单中相同的追溯码)/下游企业入库扫码量",
|
|
|
+ unit: '%'
|
|
|
},
|
|
|
{
|
|
|
key: "inScanRate",
|
|
|
@@ -252,6 +258,7 @@ export default {
|
|
|
width: "",
|
|
|
tooltip:
|
|
|
"客户入库扫码量(与上游出库单中相同的追溯码)/上游企业出库扫码量",
|
|
|
+ unit: '%'
|
|
|
},
|
|
|
{
|
|
|
key: "selfExaminationRate",
|
|
|
@@ -259,6 +266,7 @@ export default {
|
|
|
fixed: false,
|
|
|
width: "",
|
|
|
tooltip: "客户出库扫码量(与入库单中相同的追溯码)/入库扫码量",
|
|
|
+ unit: '%'
|
|
|
},
|
|
|
],
|
|
|
},
|
|
|
@@ -392,7 +400,7 @@ export default {
|
|
|
getUid,
|
|
|
getSummary(col, ci) {
|
|
|
if (ci == 0) return "合计";
|
|
|
- return this.summaryData[ci];
|
|
|
+ return this.summaryData[ci] + (col.unit || '');
|
|
|
},
|
|
|
closeAllTooltip() {
|
|
|
this.headerTooltip = {};
|
|
|
@@ -539,7 +547,7 @@ export default {
|
|
|
: [...this.list];
|
|
|
if (this.list.length < this.totalCount) {
|
|
|
this.hasmore = true;
|
|
|
- this.pageNum++;
|
|
|
+ this.tablePage++;
|
|
|
} else {
|
|
|
this.hasmore = false;
|
|
|
}
|
|
|
@@ -567,6 +575,7 @@ export default {
|
|
|
base.position = "sticky";
|
|
|
base.zIndex = 2;
|
|
|
base.top = "0rpx";
|
|
|
+ base.background = "#eaf2ff";
|
|
|
// base.display = 'flex';
|
|
|
// base.alignItems = 'center';
|
|
|
// base.justifyContent = 'center';
|
|
|
@@ -575,7 +584,6 @@ export default {
|
|
|
}
|
|
|
if (col.fixed) {
|
|
|
base.left = this.stickyLeft(ci);
|
|
|
- base.background = "#eaf2ff";
|
|
|
}
|
|
|
return base;
|
|
|
},
|
|
|
@@ -642,9 +650,9 @@ export default {
|
|
|
"®ionName=" +
|
|
|
encodeURIComponent(data.regionName) +
|
|
|
"&drugEntBaseInfoId=" +
|
|
|
- data.druGentBaseInfoId +
|
|
|
+ (data.druGentBaseInfoId || '') +
|
|
|
"&physicName=" +
|
|
|
- encodeURIComponent(data.name) +
|
|
|
+ encodeURIComponent(data.name || '') +
|
|
|
"&scanType=" +
|
|
|
this.scanType +
|
|
|
(this.params.type ? "&type=" + this.params.type : ""),
|
|
|
@@ -807,7 +815,7 @@ export default {
|
|
|
} */
|
|
|
.row {
|
|
|
display: flex;
|
|
|
- align-items: center;
|
|
|
+ align-items: stretch;
|
|
|
border-bottom: 1rpx solid #eef0f4;
|
|
|
}
|
|
|
|
|
|
@@ -861,6 +869,7 @@ export default {
|
|
|
|
|
|
.table-body .cell {
|
|
|
background-color: #fff;
|
|
|
+ text-align: center;
|
|
|
}
|
|
|
|
|
|
.table-body .striped {
|