呼叫套轴添加呼叫计划148

This commit is contained in:
2026-08-25 17:18:13 +08:00
parent a1b0a8dc2d
commit f7a69256b1
8 changed files with 494 additions and 53 deletions

View File

@@ -14,9 +14,9 @@ uni-button:after {
/** iconfont */
@font-face {
font-family: 'iconfont';
src: url('@/static/iconfont/iconfont.woff2?t=1665454521636') format('woff2'),
url('@/static/iconfont/iconfont.woff?t=1665454521636') format('woff'),
url('@/static/iconfont/iconfont.ttf?t=1665454521636') format('truetype');
src: url('@/static/iconfont/iconfont.woff2?t=1787635254843') format('woff2'),
url('@/static/iconfont/iconfont.woff?t=1787635254843') format('woff'),
url('@/static/iconfont/iconfont.ttf?t=1787635254843') format('truetype');
}
.iconfont {
font-family: "iconfont" !important;
@@ -721,3 +721,262 @@ uni-button[disabled]:not([type]) {
padding: 20rpx 0 19rpx 0;
box-shadow: 0 0 20rpx 0 rgba(160,160,160,0.7);
}
/**
*
*/
.add_content {
display: flex;
flex-direction: column;
gap: 20rpx;
width: 100%;
height: 100%;
padding: calc(var(--status-bar-height) + 108rpx) 15rpx 114rpx 14rpx;
}
.filter-card {
background-color: #fff;
border-radius: 4rpx;
padding: 14rpx;
box-shadow: 0px 3px 3px 0px rgba(160,160,160,0.20);
flex: none;
}
.plan-panel {
background-color: #fff;
border-radius: 4rpx;
box-shadow: 0px 3px 3px 0px rgba(160,160,160,0.20);
flex: 1;
min-height: 0;
display: flex;
flex-direction: column;
overflow: hidden;
}
.filter-head {}
.filter-title {
font-size: 30rpx;
line-height: 30rpx;
color: #23272f;
font-weight: 700;
gap: 14rpx;
}
.filter-title text {
display: block;
width: 8rpx;
height: 32rpx;
border-radius: 8rpx;
background-color: #f36b2a;
}
.icon_down {
font-size: 30rpx;
line-height: 30rpx;
color: #f36b2a;
padding: 18rpx;
border-radius: 50%;
background-color: #fff3eb;
transition: .2s;
}
.icon_up {
transform: rotate(180deg);
}
.filter-grid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 16rpx;
margin-top: 16rpx;
}
.filter_field {
width: 100%;
margin-bottom: 10rpx;
}
.filter-field-full {
grid-column: 1 / -1;
}
.filt_label {
font-size: 24rpx;
line-height: 24rpx;
color: #323232;
margin: 0 0 8rpx 4rpx;
}
.filt_input_wraper {
width: 100%;
margin: 0;
}
.panel-head {
padding: 14rpx 14rpx 18rpx;
border-bottom: 1px solid #f0f1f3;
flex: none;
}
.icon-shuaxin-wrap text {
font-size: 28rpx;
line-height: 28rpx;
color: #f36b2a;
}
.icon_shuaxin {
font-size: 32rpx;
line-height: 32rpx;
color: #f36b2a;
transition: .2s;
}
.stats {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 14rpx;
margin-top: 20rpx;
}
.stat {
padding: 18rpx 14rpx;
border-radius: 18rpx;
background: #f7f8fa;
}
.stat text {
font-size: 22rpx;
color: #7b8491;
}
.stat.primary {
background-color: #fff3eb;
}
.stat.primary .stat_num {
color: #f36b2a;
}
.stat_num {
font-size: 40rpx;
line-height: 1.1;
color: #23272f;
font-weight: 700;
}
.list-toolbar {
padding: 16rpx 14rpx 10rpx;
font-size: 24rpx;
color: #7b8491;
}
.seg {
background: #f1f2f4;
border-radius: 14rpx;
padding: 4rpx;
}
.seg button {
border: 0;
background: transparent;
color: #69727e;
border-radius: 12rpx;
padding: 10rpx 18rpx;
font-size: 24rpx;
line-height: 34rpx;
}
.seg button.on {
background: #fff;
color: #f36b2a;
box-shadow: 0 2rpx 8rpx rgba(0, 0, 0, .09);
}
.plan-list {
flex: 1;
min-height: 0;
overflow: auto;
padding: 8rpx 14rpx 24rpx;
overscroll-behavior: contain;
}
.list_empty {
height: 100%;
display: grid;
place-items: center;
text-align: center;
}
.icon_local {
font-size: 40rpx;
color: #b5bbc2;
margin-bottom: 10rpx;
}
.icon_local text {
color: #7b8491;
font-size: 26rpx;
}
.plan-item{
background:#fff;
border:1px solid #e8ebef;
border-radius:20rpx;
margin-bottom:16rpx;
overflow:hidden;
}
.plan-main{
padding:20rpx;
display:flex;
justify-content:space-between;
align-items:flex-start;
gap:16rpx;
}
.plan-left{
flex:1;
}
.plan-code{
font-size:28rpx;
font-weight:bold;
}
.plan-sub{
margin-top:10rpx;
font-size:24rpx;
color:#7b8491;
display:flex;
flex-wrap:wrap;
gap:10rpx 24rpx;
}
.plan-right{
display:flex;
flex-direction:column;
align-items:flex-end;
gap:8rpx;
}
.status{
font-size:22rpx;
padding:8rpx 14rpx;
border-radius:24rpx;
}
.status.fitted{
color:#26a269;
background:#eaf8f1;
}
.status.waiting{
color:#c27408;
background:#fff5df;
}
.expand-btn {
font-size:22rpx;
color:#9aa1aa;
display:flex;
align-items:center;
gap:8rpx;
}
.expand-btn .iconfont {
font-size:18rpx;
transition: transform 0.2s;
}
.expand-btn .iconrotate {
transform: rotate(180deg);
}
.plan-details{
display:none;
background:#fafbfc;
border-top:1px dashed #e3e6e9;
padding:18rpx 24rpx;
font-size:24rpx;
color:#59636f;
line-height:1.8;
}
.plan-details text {
display: block;
}
.plan-item.open .plan-details{
display: grid;
grid-template-columns: 1fr 1fr;
gap: 6rpx 20rpx;
}
.spin-icon {
animation: rotateSpin 1s linear infinite;
}
@keyframes rotateSpin {
from {
transform: rotate(0deg);
}
to {
transform: rotate(360deg);
}
}

View File

@@ -2,8 +2,8 @@
"name" : "海亮铜箔",
"appid" : "__UNI__3A002CD",
"description" : "海亮铜箔二期手持系统",
"versionName" : "1.4.7",
"versionCode" : 147,
"versionName" : "1.4.8",
"versionCode" : 148,
"transformPx" : false,
/* 5+App */
"app-plus" : {

View File

@@ -2,59 +2,127 @@
<view class="zd_container">
<!-- <nav-bar title="呼叫套轴"></nav-bar> -->
<nav-bar :title="title"></nav-bar>
<view class="zd_content">
<view class="zd_wrapper">
<view class="filter_item">
<view class="filter_label">区域</view>
<view class="filter_input_wraper">
<uni-data-select v-model="index1" :localdata="options1" @change="selectChange1"></uni-data-select>
<view class="add_content">
<view class="filter-card">
<view class="zd-row filter-head">
<view class="zd-row filter-title"><text></text>作业条件</view>
<view class="iconfont icon_down" :class="{'icon_up': !collapse}" @tap="toCollapse">&#xe65d;</view>
</view>
<view v-if="!collapse">
<view class="filter-grid">
<view class="filter_field">
<view class="filt_label">区域</view>
<view class="filter_input_wraper filt_input_wraper">
<uni-data-select v-model="index1" :localdata="options1" @change="selectChange1"></uni-data-select>
</view>
</view>
<view class="filter_field">
<view class="filt_label">位置</view>
<view class="filter_input_wraper filt_input_wraper">
<uni-data-select v-model="index2" :localdata="options2" @change="selectChange2"></uni-data-select>
</view>
</view>
<view class="filter_field filter-field-full">
<view class="filt_label">左管</view>
<view class="filter_input_wraper filt_input_wraper">
<uni-data-select v-model="upL" :searchInput="true" :localdata="newaxis1" @handleChange="handleChange1" @showSelector="showSelector1"></uni-data-select>
</view>
</view>
<view class="filter_field filter-field-full">
<view class="filt_label">右管</view>
<view class="filter_input_wraper filt_input_wraper">
<uni-data-select v-model="upR" :searchInput="true" :localdata="newaxis2" @handleChange="handleChange2" @showSelector="showSelector2"></uni-data-select>
</view>
</view>
<view class="filter_field">
<view class="filt_label">尺寸</view>
<view class="filter_input_wraper filt_input_wraper">
<uni-data-select v-model="index3" :localdata="options3" @change="selectChange3"></uni-data-select>
</view>
</view>
<view class="filter_field">
<view class="filt_label">代数</view>
<view class="filter_input_wraper filt_input_wraper">
<uni-data-select v-model="index4" :localdata="options4" @change="selectChange4"></uni-data-select>
</view>
</view>
<view class="filter_field filter-field-full">
<view class="filt_label">数量</view>
<view class="filter_input_wraper filt_input_wraper">
<NumberInput
v-model="qty"
input-class="filter_input"
mode="integer"
/>
</view>
</view>
</view>
</view>
<view class="filter_item">
<view class="filter_label_wraper">
<span class="filter_label">位置</span>
</view>
<view class="plan-panel">
<view class="panel-head">
<view class="zd-row filter-head">
<view class="zd-row filter-title">呼叫计划</view>
<view class="zd-row">
<view class="zd-row icon-shuaxin-wrap" @tap="handleRefresh">
<view class="iconfont icon_shuaxin" :class="{'spin-icon': refreshing}">&#xe650;</view>
<text>&nbsp;刷新</text>
</view>
</view>
</view>
<view class="filter_input_wraper">
<uni-data-select v-model="index2" :localdata="options2" @change="selectChange2"></uni-data-select>
<view class="stats">
<view class="stat" :class="{'primary': state === 'all'}">
<view class="stat_num">{{statTotal}}</view>
<text>呼叫总数</text>
</view>
<view class="stat" :class="{'primary': state === '02'}">
<view class="stat_num">{{statFitted}}</view>
<text>已套轴</text>
</view>
<view class="stat" :class="{'primary': state === '01'}">
<view class="stat_num">{{statWaiting}}</view>
<text>待套轴</text>
</view>
</view>
</view>
<view class="filter_item">
<view class="filter_label">左管</view>
<view class="filter_input_wraper">
<uni-data-select v-model="upL" :searchInput="true" :localdata="newaxis1" @handleChange="handleChange1" @showSelector="showSelector1"></uni-data-select>
<view class="zd-row list-toolbar">
<text class="resultText">{{resultText}}</text>
<view class="zd-row seg">
<button class="seg_all" :class="{'on': state === 'all'}" @tap="state='all'">全部</button>
<button class="seg_on" :class="{'on': state === '02'}" @tap="state='02'">已套轴</button>
<button class="seg_waiting" :class="{'on': state === '01'}" @tap="state='01'">待套轴</button>
</view>
</view>
<view class="filter_item">
<view class="filter_label">右管</view>
<view class="filter_input_wraper">
<uni-data-select v-model="upR" :searchInput="true" :localdata="newaxis2" @handleChange="handleChange2" @showSelector="showSelector2"></uni-data-select>
</view>
</view>
<view class="filter_item">
<view class="filter_label_wraper">
<span class="filter_label">尺寸</span>
</view>
<view class="filter_input_wraper">
<uni-data-select v-model="index3" :localdata="options3" @change="selectChange3"></uni-data-select>
</view>
</view>
<view class="filter_item">
<view class="filter_label_wraper">
<span class="filter_label">代数</span>
</view>
<view class="filter_input_wraper">
<uni-data-select v-model="index4" :localdata="options4" @change="selectChange4"></uni-data-select>
</view>
</view>
<view class="filter_item">
<view class="filter_label">数量</view>
<view class="filter_input_wraper">
<!-- <input type="number" class="filter_input" v-model="qty"> -->
<NumberInput
v-model="qty"
input-class="filter_input"
mode="integer"
/>
<view class="plan-list">
<block v-for="(item, index) in filteredPlanList" :key="index">
<view class="plan-item" :class="{'open': item._expand}">
<view class="plan-main">
<view class="plan-left">
<view class="plan-code">{{ item.paper_tube_or_FRP === '1' ? item.paper_tube_description : item.frp_description }}</view>
<view class="plan-sub">
<text>管芯尺寸 · {{ item.qzz_size }}</text>
<text>管芯代数 · {{ item.qzz_generation }}</text>
</view>
</view>
<view class="plan-right">
<text class="status" :class="item.status==='01' ? 'waiting' : 'fitted'">
{{ item.status === '01' ? '待套轴' : '已套轴'}}
</text>
<view class="expand-btn" @tap="toggleExpand(item)">
<text>{{ item._expand ? '收起明细' : '查看明细' }}</text>
<view class="iconfont" :class="{'iconrotate': item._expand}">&#xe65e;</view>
</view>
</view>
</view>
<view class="plan-details">
<text>呼叫时间{{ item.call_time }}</text>
<text>管芯重量{{ item.paper_weight }}</text>
<text>是否套轴完成{{ item.is_child_tz_ok === 1 ? '是' : '否' }}</text>
</view>
</view>
</block>
<view v-if="!filteredPlanList.length" class="list_empty">
<view class="iconfont icon_local">&#xe61f;<br /><text>请先选择位置<br />系统将加载该位置的呼叫计划</text></view>
</view>
</view>
</view>
@@ -71,7 +139,7 @@
import SearchBox from '@/components/SearchBox.vue'
import NumberInput from '@/components/NumberInput.vue'
import {queryProductArea, queryDeviceByarea} from '@/utils/getData2.js'
import {slitXnplan, slitXnarea, paperQueryPaperMaterial} from '@/utils/getData3.js'
import {slitXnplan, slitXnarea, paperQueryPaperMaterial, getBindXnPlan} from '@/utils/getData3.js'
export default {
components: {
NavBar,
@@ -81,6 +149,9 @@
data() {
return {
title: '',
collapse: false,
state: 'all',
refreshing: false,
options1: [],
index1: '',
options2: [],
@@ -96,15 +167,50 @@
upR: '',
qty: null,
disabled: false,
disabled1: false
disabled1: false,
planList: []
};
},
computed: {
resultText() {
if (!this.index2) {
return '选择位置后加载'
}
const posItem = this.options2.find(o => o.value === this.index2)
const posLabel = posItem ? posItem.text : this.index2
const list = this.planList
return `${posLabel} · 共 ${list.length}`
},
filteredPlanList() {
if (this.state === 'all') {
return this.planList
} else if (this.state === '01') {
return this.planList.filter(p => p.status === '01')
} else if (this.state === '02') {
return this.planList.filter(p => p.status !== '01')
}
return []
},
statTotal() {
return this.planList.length
},
statWaiting() {
return this.planList.filter(p => p.status === '01').length
},
statFitted() {
return this.statTotal - this.statWaiting
}
},
onLoad (options) {
this.title = options.title
this._queryProductArea()
this._paperQueryPaperMaterial()
},
methods: {
toCollapse () {
this.collapse = !this.collapse
},
/** 生产区域下拉框查询 */
async _queryProductArea () {
let res = await queryProductArea()
@@ -126,6 +232,20 @@
this.options2 = []
}
},
async _getBindXnPlan (e) {
try {
let res = await getBindXnPlan(e)
if (res && res.status === 200) {
this.planList = res.plans.map(p=>{
return { ...p, _expand:false }
})
} else {
this.planList = []
}
} catch (e) {
this.planList = []
}
},
selectChange1(e) {
this.index1 = e
if (e) {
@@ -136,6 +256,11 @@
},
selectChange2(e) {
this.index2 = e
if (e) {
this._getBindXnPlan(e)
} else {
this.planList = []
}
},
selectChange3(e) {
this.index3 = e
@@ -157,6 +282,9 @@
this.qty = null
this.disabled = false
this.disabled1 = false
this.state = 'all',
this.refreshing = false
this.planList = []
},
async _slitXnplan () {
this.disabled = true
@@ -181,6 +309,9 @@
title: res.message,
icon: 'none'
})
if(this.index2){
this._getBindXnPlan(this.index2)
}
} catch (e) {
this.disabled = false
}
@@ -216,6 +347,21 @@
},
showSelector2 () {
this.newaxis2 = this.axis
},
handleRefresh() {
if (!this.index2) {
uni.showToast({ title:'请先选择位置', icon:'none' })
return
}
if(this.refreshing) return
this.refreshing = true
this._getBindXnPlan(this.index2).finally(()=>{
this.refreshing = false
})
},
toggleExpand(item) {
this.$set(item, '_expand', !item._expand)
}
}
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -392,6 +392,12 @@ export const urgentPlan = (data) => request({
url:'api/pda/slitter/urgentPlan',
data: data
})
export const getBindXnPlan = (location) => request({
url:'api/pda/slitter/get-bind-xn-plan',
data: {
location: location
}
})
/**
* 空轴回库(一期分切管理)
*/

View File

@@ -358,3 +358,33 @@ export const getUnbindPlan = () => {
]
return res
}
export const getBindXnPlan = () => {
let res = {
"status" : 200,
"plans" : [
{
"paper_tube_description": 'JH-20260824-018',
"paper_tube_model": null,
"FRP_material": null,
"FRP_description": 'FRP_description',
"paper_tube_or_FRP": 1,
"status": '01',
"is_child_tz_ok": 1,
"call_time": '15:20',
"paper_weight": '20'
},
{
"paper_tube_description": 'JH-20260824-018',
"paper_tube_model": null,
"FRP_material": null,
"FRP_description": 'FRP_description',
"paper_tube_or_FRP": null,
"status": '04',
"is_child_tz_ok": 1,
"call_time": '15:20',
"paper_weight": '20'
}
]
}
return res
}