This commit is contained in:
Teng 2025-11-14 13:27:26 +08:00
commit e9d88c0c03
13 changed files with 608 additions and 130 deletions

View File

@ -146,4 +146,12 @@ export const getTreeDataWlnum = (params) => {
data: params,
})
}
// (业务)查询全部供应商信息
export const getGysList = (params) => {
return request({
url: `${uni.getStorageSync('serverUrl')}/api/pad/invoicing/getGysList`,
method: 'get',
data: params,
})
}

View File

@ -51,7 +51,7 @@
<image class="guodu" :style="v.zk?'transform: rotate(180deg);':''" :src="'/static/index/procurement/l.png'" mode="aspectFill"></image>
</view>
<view class="zkadd guodu" :class="v.isAdd==1?'zkf':''">
<view @click.stop @touchend.stop>出入库</view>
<view @click.stop="crk(v,index)" @touchend.stop>出入库</view>
<view @click.stop="addcar(v)" v-if="v.isAdd!=1" @touchend.stop>
<view>
<text>加购</text>
@ -86,7 +86,7 @@
required: true,
},
})
const emit = defineEmits(['addcartory','tolower','solleft'])
const emit = defineEmits(['addcartory','tolower','solleft','crk'])
const serverUrl = ref('')
onMounted(()=>{
serverUrl.value = uni.getStorageSync('serverUrl') + '/sys/common/static/';
@ -156,11 +156,14 @@
}
})
}
// const scrollLeft = ref(0)
// const scroll = (e)=>{
// scrollLeft.value = e.detail.scrollLeft
// // console.log(e.detail.scrollLeft)
// }
const scrollLeft = ref(0)
const scroll = (e)=>{
// scrollLeft.value = e.detail.scrollLeft
// console.log(e.detail.scrollLeft)
}
const crk=(v,i)=>{
emit('crk',v,i)
}
</script>
<style scoped lang="less">

View File

@ -0,0 +1,140 @@
<template>
<view>
<view class="addall" v-if="show">
<view>温馨提示</view>
<view>
<image src="/static/index/procurement/ddj.png" mode="aspectFill"></image>
</view>
<view>确认将所有未添加状态的库存预警物料添加至购物车中并且物料的采购数量为物料的库存上限-库存数量吗</view>
<view>
<view @click="$emit('back')">取消</view>
<view class="qd" @click="config()">确定</view>
</view>
</view>
</view>
</template>
<script>
import { queryInvoicingList,addShoppingCartList } from '../api/lunpan.js'
export default {
props:{
show:false,
},
data() {
return {
Materialarr:[]
}
},
methods: {
config(){
let warn = {
nuId: uni.getStorageSync('nuId'),
pageSize: -1,
isWaring: 1
}
queryInvoicingList(warn).then(res => {
this.Material=res.result.records;
this.add()
})
},
add(){
let r = []
this.Material.forEach(item=>{
if(item.isAdd!=1){
let n = item.suppliers_dictText.split(/[, ]+/);
let id = item.suppliers.split(/[, ]+/);
let max = Number(item.upperLimit)- Number(item.kcsl);
let dt = {
nuId:uni.getStorageSync('nuId'),
purchaseQuantity:max,
suppliersId:id[0],
suppliersName:n[0],
wlId:item.wlId,
kcsl:item.kcsl,
wlUnits:item.materialUnits,
referenceUnitPrice:item.referenceUnitPrice,
dhbl:type.num
}
r.push(dt)
}
})
addShoppingCartList(r).then(res=>{
uni.showToast({
icon:res.success?'success':'none',
title:res.message
})
this.$emit('config')
})
}
}
}
</script>
<style scoped lang="less">
.addall{
width: 42.4vw;
height: 25vw;
background: #FFFFFF;
box-shadow: 0rpx 0rpx 1.3vw 0rpx rgba(163,167,182,0.16);
border-radius: 1.6vw;
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
margin: auto;
padding: 2.8vw;
z-index: 120;
>view{
&:nth-child(4){
width: 22vw;
display: flex;
justify-content: space-around;
margin: 1.8vw auto 0;
view{
width: 8.2vw;
height: 3.3vw;
background: #EDEDEF;
border-radius: 1.6vw;
font-weight: 400;
font-size: 1.6vw;
color: #888888;
display: flex;
justify-content: center;
align-items: center;
border: 1px solid #888888;
}
.qd{
background: linear-gradient(0deg, #CAE0F9, #E9F4FF);
border: 1px solid rgba(3,133,250,0.34);
color: #0385FA;
}
}
&:nth-child(3){
width: 31vw;
height: 3.4vw;
font-weight: 400;
font-size: 1.2vw;
color: #888888;
line-height: 1.7vw;
margin: 0.4vw auto 0;
}
&:nth-child(2){
width: 7.6vw;
height: 7.6vw;
margin: 1.1vw auto 0;
image{
width: 100%;
height: 100%;
}
}
&:nth-child(1){
font-weight: 400;
font-size: 1.6vw;
color: #333333;
}
}
}
</style>

View File

@ -12,7 +12,7 @@
<scroll-view scroll-y="true" class="gysscrol">
<view v-for="(v,i) in gysarr" :key='i' :class="gysidnum==i?'acts':''" @click="gysid(i)">
<text>{{v.name}}</text>
<image src="/static/index/warehouse/procurement/d.png" mode="aspectFill"></image>
<image src="/static/index/procurement/d.png" mode="aspectFill"></image>
</view>
</scroll-view>
</view>
@ -26,22 +26,38 @@
</view>
</view>
<view class="qinggou-font">
采购数量
采购数量 <text style="color: red;" v-if="sx==true">超过库存上限</text>
</view>
<view class="stringShow-father">
<view class="jj" @click="jjnum(-1)" @longpress="handleTouchStart(-1)" @touchend="handleTouchEnd">
-
</view>
<view class="stringShow-kuai">
<view v-for="(item,index) in stringShow" :key="index" >
<view v-for="(item,index) in stringShow" :key="index" :style="sx==true?'color: red':''">
{{item}}
</view>
</view>
<view class="jj" @click="jjnum(1)" @longpress="handleTouchStart(1)" @touchend="handleTouchEnd">
<view class="jj" :style="sx==true?'background:#f8f8f8':''" @click="jjnum(1)" @longpress="handleTouchStart(1)" @touchend="handleTouchEnd">
+
</view>
</view>
<view class="cgdw">
<view class="leftr">
<view>采购单位</view>
<text>{{type.unit}}</text>
</view>
<view class="tz" @click="cgdwflag=!cgdwflag">调整</view>
<view class="dwdw" v-if="cgdwflag">
<view class="gysscrol">
<view v-for="(v,i) in cgdwarr" :key='i' :class="type.multiUnitType==v.multiUnitType?'acts':''"
@click="cd(v,i)" :style="v.unit&&v.num?'':'height:0 !important'">
<text v-if="v.unit&&v.num">{{v.unit}}</text><text v-if="v.unit&&v.num">{{v.num}}{{caigouobj.materialUnits}}</text>
<image src="/static/index/procurement/d.png" mode="aspectFill"></image>
</view>
</view>
</view>
</view>
<view class="plsbuy-bottom">
<view class="quxiao" @click="colse">
取消
@ -66,17 +82,14 @@
const emit = defineEmits(['right','colse','jjnum'])
const blueNumber = ref(-1);
const gysflag = ref(false)
const cgdwflag = ref(false)
const sx = ref(false)
const type = ref({})
const gysarr = ref([])
const cgdwarr = ref([])
const gysidnum = ref(0)
const props = defineProps({
doOnce: {
type: Number,
required: true,
},
translateNumber: {
type: Number,
required: true,
},
show: {
type: Boolean,
default:false,
@ -88,18 +101,61 @@
}
});
watch(
() => props.doOnce,
() => {
relNumber.value = props.translateNumber
stringShow.value = toFixed4ByPadStart(relNumber.value)
}
)
// watch(
// () => type.value,
// (news,old) => {
// console.log(old,news)
// if(!old.num){return}
// if(old.num==1){
// let num = Number(props.caigouobj.upperLimit)-Number(props.caigouobj.kcsl);
// let m = Math.floor(relNumber.value/news.num);
// huansuan(m)
// }
// if(old.num!=1){
// let f = relNumber.value*old.num;
// let num = Number(props.caigouobj.upperLimit)-Number(props.caigouobj.kcsl);
// f = f>num?num:f;
// // let m = Math.floor(num/type.value.num)
// let m = Math.floor(f/news.num);
// huansuan(m)
// }
// }
// )
watch(
()=>props.show,
()=>{
if(props.show){
console.log(props.caigouobj)
let a = [
{
multiUnitType:1,
price:props.caigouobj.oneUnitPrice,
unit:props.caigouobj.oneUnit,
num:props.caigouobj.oneUnitProportion
},
{
multiUnitType:2,
price:props.caigouobj.twoUnitPrice,
unit:props.caigouobj.twoUnit,
num:props.caigouobj.twoUnitProportion
},
{
multiUnitType:3,
price:props.caigouobj.referenceUnitPrice,
unit:props.caigouobj.materialUnits,
num:1
}
];
a.forEach((v,i)=>{
if(v.price==null||!v.price){
a.splice(i,1)
}
})
type.value = a.find(item=>
item.multiUnitType == props.caigouobj.multiUnitType
);
cgdwarr.value = a;
let n = [];
let id = [];
gysarr.value = [];
@ -108,10 +164,40 @@
n.forEach((item,i)=>{
gysarr.value.push({'name':item,'id':id[i]})
})
jssl()
}else{
gysflag.value = false;
cgdwflag.value = false;
type.value = {};
sx.value = false;
}
})
const jssl=()=>{
let num = Number(props.caigouobj.upperLimit)-Number(props.caigouobj.kcsl);
let m = Math.floor(num/type.value.num)
console.log(m)
huansuan(m)
console.log(stringShow.value)
}
const huansuan=(m:number)=>{
relNumber.value = m;
stringShow.value = toFixed4ByPadStart(relNumber.value);
}
const cy=()=>{
let num = Number(props.caigouobj.upperLimit)-Number(props.caigouobj.kcsl);
let bl = relNumber.value*type.value.num
if(bl>num){
sx.value = true
}else{
sx.value = false
}
console.log(sx.value,num,bl)
}
const cd =(v,i)=>{
type.value = v;
cgdwflag.value = false;
jssl()
}
const gysid = (e:number)=>{
gysidnum.value = e;
gysflag.value = false;
@ -144,7 +230,7 @@
} else {
relNumber.value = relNumber.value * 10 + item;
}
cy()
stringShow.value = toFixed4ByPadStart(relNumber.value)
}
@ -163,10 +249,25 @@
}, 120);
}
const jjnum = (e:number)=>{
emit('jjnum',e)
let num = Number(props.caigouobj.upperLimit)-Number(props.caigouobj.kcsl);
let m = Math.floor(num/type.value.num)
if(m<=relNumber.value&&e==1){relNumber.value = m; return}
if(relNumber.value<=1&&e==-1){relNumber.value==1; return}
relNumber.value+=e;
stringShow.value = toFixed4ByPadStart(relNumber.value)
cy()
// emit('jjnum',e)
}
const closeIt = () => {
emit('right', relNumber.value,gysarr.value[gysidnum.value])
if(relNumber.value<1){
uni.showToast({
title:'采购数量不能为0',
icon:'none'
})
return
}
emit('right', relNumber.value,gysarr.value[gysidnum.value],type.value)
}
const colse = ()=>{
emit('colse')
@ -189,23 +290,26 @@
</script>
<style lang="less" scoped>
.gys{
width: 100%;
height: 8vw;
.cgdw{
width: 90%;
height: 3.5vw;
display: flex;
justify-content: space-between;
margin: 1.5vw auto 0.8vw;
position: relative;
>.tanchu{
width: 25vw;
height: 7vw;
.dwdw{
width: 15vw;
height: 11vw;
background: #FFFFFF;
box-shadow: 0rpx 0rpx 0.5vw 0rpx rgba(174,175,176,0.35);
border-radius: 1.1vw;
padding: 0 1.4vw;
padding: 0 1vw;
position: absolute;
right: 7.2vw;
top: 7vw;
left:7vw;
top: -16vw;
.gysscrol{
width: 100%;
height: 7vw;
height: 10vw;
.acts{
color: #0385FA !important;
image{
@ -217,13 +321,99 @@
justify-content: space-between;
align-items: center;
font-weight: 400;
font-size: 1vw;
font-size: 1.5vw;
color: #666666;
margin-bottom: 0.9vw;
margin-bottom: 1.2vw;
padding-right: 1.5vw;
position: relative;
&:nth-child(1){
margin-top: 0.9vw;
margin-top: 1vw;
}
image{
position: absolute;
right: 0.2vw;
top: 25%;
width: 1vw !important;
height: 0.7vw !important;
display: none;
}
}
}
}
.tz{
width: 7vw;
height: 3.3vw;
background: rgba(255,255,255,0.6);
border-radius: 1.6vw;
border: 1px solid #D9DADC;
box-shadow: 0.05vw 0.5vw 0.5vw #dadee1;
display: flex;
justify-content: center;
align-items: center;
font-weight: 400;
font-size: 1.5vw;
color: #555555;
}
.leftr{
width: 21vw;
display: flex;
align-items: center;
white-space: nowrap;
view{
width: 8.6vw;
font-weight: 400;
font-size: 1.6vw;
color: #555555;
}
text{
font-weight: 400;
font-size: 1.4vw;
color: #888888;
}
}
}
.gys{
width: 100%;
height: 7vw;
position: relative;
margin-top: 0.5vw;
>.tanchu{
width: 25vw;
height: 15vw;
background: #FFFFFF;
box-shadow: 0rpx 0rpx 0.5vw 0rpx rgba(174,175,176,0.35);
border-radius: 1.1vw;
padding: 0 1.4vw;
position: absolute;
right: 7.2vw;
top: 7vw;
.gysscrol{
width: 100%;
height: 15vw;
.acts{
color: #0385FA !important;
image{
display: block;
}
}
view{
display: flex;
justify-content: space-between;
align-items: center;
font-weight: 400;
font-size: 1.5vw;
color: #666666;
margin-bottom: 1.2vw;
padding-right: 1.5vw;
position: relative;
&:nth-child(1){
margin-top: 1.2vw;
}
image{
position: absolute;
right: 0.2vw;
top: 25%;
width: 1vw !important;
height: 0.7vw !important;
display: none;
@ -237,21 +427,21 @@
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 1vw;
margin-top:0.8vw;
text{
width: 7.1vw;
height: 3.3vw;
background: linear-gradient(-45deg, rgba(223, 244, 252, 0.43), rgba(204, 228, 249, 0.43));
border-radius: 1.65vw;
border: 1px solid #1083F8;
font-weight: 400;
font-size: 1.5vw;
color: #1083F8;
color: #555;
display: flex;
justify-content: center;
align-items: center;
border: 1px solid #D9DADC;
box-shadow: 0.05vw 0.5vw 0.5vw #dadee1;
}
>view{
view{
width: 22vw;
height: 3.3vw;
white-space: nowrap;
@ -274,23 +464,23 @@
align-items: center;
flex-direction: column;
width: 36vw;
height: 90vh;
height: 95vh;
background: rgba(250, 251, 252, 1);
overflow: hidden;
box-shadow: 0rpx 0rpx 1.6vw 0rpx rgba(136,141,153,0.28);
border-radius: 2.2vw;
top: 5vw;
top: 2.5vw;
left: 32vw;
position: fixed;
z-index: 200;
padding: 2.8vw;
padding:1.5vw 2.8vw;
}
.plsbuy-bottom {
width: 90%;
margin-top: 4.5vw;
height: 70rpx;
margin-top: 3vw;
height: 7vw;
display: flex;
justify-content: flex-end;
font-size: 35rpx;
@ -318,12 +508,11 @@
.calculator-father {
width: 24vw;
height: 57%;
height: 45vh;
margin :0 auto 0;
flex-wrap: wrap;
display: grid;
grid-template-columns: 1fr 1fr 1fr;
.calculator-kuai {
display: flex;
justify-content: center;
@ -333,7 +522,7 @@
border-radius: 25rpx;
font-size: 42rpx;
font-weight: 500;
margin: 15rpx 20rpx 0 20rpx;
margin: 12rpx 20rpx 0 20rpx;
width: 6.1vw;
height: 6.1vw;
}
@ -347,8 +536,8 @@
.stringShow-father {
width: 100%;
height: 70rpx;
margin-top: 20rpx;
height:7vw;
margin-top:0.5vw;
display: flex;
align-items: center;
.jj{
@ -399,7 +588,7 @@
.qinggou-font {
font-size: 27rpx;
font-weight: 500;
margin: 1.4vw auto;
margin: 0.8vw auto 0;
}
</style>

View File

@ -51,7 +51,7 @@
<image :src="'/static/index/procurement/+.png'" mode="aspectFill"></image>
</view>
<view class="zkadd guodu" :class="v.isAdd==1?'zkf':''">
<view @click.stop @touchend.stop>出入库</view>
<view @click.stop="crk(v,index)" @touchend.stop>出入库</view>
<view @click.stop="addcar(v,index)" v-if="v.isAdd!=1" @touchend.stop>
<view>
<text>加购</text>
@ -85,24 +85,12 @@
required: true,
},
})
const emit = defineEmits(['addcartory', 'scrolltolower','addcar'])
const emit = defineEmits(['addcartory', 'scrolltolower','addcar','crk'])
const serverUrl = ref('')
onMounted(() => {
serverUrl.value = uni.getStorageSync('serverUrl') + '/sys/common/static/';
})
const caigouobj = ref({})
const clkzk = (v : any, i : number) => {
caigouobj.value = v;
caigouobj.value.Limitnum = Number(caigouobj.value?.upperLimit) - Number(caigouobj.value.kcsl);
caigouobj.value.index = i;
caigouobj.value.yj = false;
let n = caigouobj.value.suppliers_dictText.split(/[, ]+/);
let id = caigouobj.value.suppliers.split(/[, ]+/);
let obj = {id:id[0],name:n[0]}
emit('addcar', caigouobj.value,obj)
}
const addcar = (v : any,i:number) => {
caigouobj.value = v;
caigouobj.value.index = i;
@ -158,6 +146,9 @@
// scrollLeft.value = e.detail.scrollLeft
// console.log(e.detail.scrollLeft)
}
const crk=(v,i)=>{
emit('crk',v,i)
}
</script>
<style scoped lang="less">

View File

@ -1,6 +1,22 @@
<template>
<view>
<view class="ifclass" v-if="show">
<view class="ifclass guodu" :class="show?'':'unclass'">
<view class="gyss">
<view class="lef"> </view>
<view class="set" @click="selt = !selt">
<text :class="gysidnum>-1?'n':''">{{gysidnum>-1?gysarr[gysidnum].suppliersName:'请选择供应商'}}</text>
<image @click.stop="qingkong" class="guodu" :style="selt&&gysidnum==-1?'transform: rotate(180deg);':''"
:src="gysidnum<0?'/static/index/procurement/sj.png':'/static/index/procurement/x.png'" mode="aspectFill"></image>
</view>
<view class="xuze guodu" :class="selt?'':'hei0'">
<scroll-view scroll-y="true" class="gysscrol guodu" :class="selt?'':'hei0'">
<view v-for="(v,i) in gysarr" :key='i' :class="gysidnum==i?'acts':''" @click="gysidnum=i;selt=false;getTreelnum()">
<text>{{v.suppliersName}}</text>
<image src="/static/index/procurement/d.png" mode="aspectFill"></image>
</view>
</scroll-view>
</view>
</view>
<view class="titletop">物料分类</view>
<view class="toptype">
<view v-for="v in ['一','二','三']">{{v+'级分类'}}</view>
@ -44,12 +60,16 @@
</template>
<script setup lang="ts">
import { ref, onMounted, reactive, onBeforeUnmount, computed, nextTick, defineProps } from 'vue';
import { getMaterialTreeData , getTreeDataWlnum} from '../api/lunpan.js'
import { ref, onMounted, reactive, onBeforeUnmount, computed, nextTick, defineProps ,watch} from 'vue';
import { getMaterialTreeData , getTreeDataWlnum,getGysList} from '../api/lunpan.js'
import { onShow, onLoad, onHide, onPageScroll } from "@dcloudio/uni-app"
const scroll = reactive({ scrolltop1: 0, scrolltop2: 0, scrolltop3: 0, act1: -1, act2: -1, act3: -1 });
const TreeData = ref([]);
const gysarr = ref([]);
const gysidnum = ref(-1);
const serverUrl = ref('');
const selt = ref(false);
const emit = defineEmits(['confirm'])
const typescroll = (e : number, i : number, v : object) => {
if (e == 1) {
@ -77,7 +97,14 @@
onMounted(()=>{
serverUrl.value = uni.getStorageSync('serverUrl') + '/sys/common/static/';
getMaterial();
GysList()
})
const GysList =()=>{
getGysList().then(res=>{
console.log(res)
gysarr.value = res.result
})
}
const num = ref(0)
const getTreelnum = ()=>{
let obj= {
@ -85,6 +112,7 @@
categoryId:scroll.act1>-1?TreeData.value[scroll.act1].categoryId:'',
typeId:scroll.act2>-1?TreeData.value[scroll.act1].children[scroll.act2].typeId:'',
medicationId:scroll.act3>-1?TreeData.value[scroll.act1].children[scroll.act2].children[scroll.act3].key:'',
suppliers:gysidnum.value>-1? gysarr.value[gysidnum.value].suppliers:''
}
getTreeDataWlnum(obj).then(res=>{
num.value = res.result.totalSize;
@ -101,6 +129,7 @@
categoryId:scroll.act1>-1?TreeData.value[scroll.act1].categoryId:'',
typeId:scroll.act2>-1?TreeData.value[scroll.act1].children[scroll.act2].typeId:'',
medicationId:scroll.act3>-1?TreeData.value[scroll.act1].children[scroll.act2].children[scroll.act3].key:'',
suppliers:gysidnum.value>-1? gysarr.value[gysidnum.value].suppliers:''
}
emit('confirm',obj)
}
@ -111,9 +140,112 @@
required: true,
},
})
watch(
()=>props.show,
()=>{
if(props.show==false){
selt.value = false
}
})
const qingkong=()=>{
if(gysidnum.value>-1){
gysidnum.value = -1;
getTreelnum()
}
}
</script>
<style scoped lang="less">
.gyss{
width: 100%;
height: 4vw;
display: flex;
align-items: center;
position: relative;
justify-content: space-between;
.hei0{
height: 0 !important;
}
.xuze{
width: 23vw;
height: calc(85vh - 22vw);
background: #fff;
border-radius: 1.6vw;
box-shadow: 0rpx 0rpx 1.3vw 0rpx rgba(163,167,182,0.16);
position: absolute;
top: 4vw;
right: 0;
z-index: 133;
.gysscrol{
width: 100%;
height: calc(85vh - 24vw);
.acts{
color: #0385FA !important;
image{
display: block;
}
}
view{
display: flex;
justify-content: space-between;
align-items: center;
font-weight: 400;
font-size: 1.5vw;
color: #666666;
margin-bottom: 1.2vw;
padding: 0 1vw;
&:nth-child(1){
margin-top: 0.9vw;
}
image{
width: 1vw !important;
height: 0.7vw !important;
display: none;
}
}
}
}
.lef{
width: 6.7vw;
letter-spacing: 2px;
font-weight: 400;
font-size: 1.5vw;
color: #333333;
}
.set{
width: 23vw;
height: 3.8vw;
padding: 0 1.7vw;
display: flex;
justify-content: space-between;
background: #F8F8FA;
border-radius: 1vw;
align-items: center;
image{
width: 1.6vw;
height: 1.6vw;
}
text{
font-weight: 300;
font-size: 1.4vw;
color: #999999;
display: block;
white-space: nowrap;
overflow: hidden;
width: 21vw;
height: 1.5vw;
line-height: 1.5vw;
text-overflow: ellipsis;
}
.n{
color: #000;
}
}
}
.unclass{
top: -86vh !important;
}
.ifclass{
width: 36vw;
height: 85vh;
@ -159,7 +291,7 @@
}
.scroltype {
width: 100%;
height: calc(85vh - 18vw);
height: calc(85vh - 22vw);
display: flex;
justify-content: space-around;
.scrl1{
@ -177,7 +309,7 @@
}
.scroll-Y {
width: 8.5vw;
height: calc(85vh - 18vw);
height: calc(85vh - 22vw);
view {
width: 100%;
@ -241,9 +373,14 @@
.titletop{
width: 100%;
height: 2.5vw;
font-weight: bold;
font-size: 1.8vw;
font-weight: 400;
font-size: 1.5vw;
color: #333333;
line-height: 2.5vw;
}
.guodu {
transition: .4s;
-webkit-transform-style: preserve-3d;
-webkit-overflow-scrolling: touch;
}
</style>

View File

@ -39,9 +39,9 @@
<text>2025-02-13 17:29:18</text>
</view>
<view>
<text>摘要:服务指令</text>
<text :class="i>5?'c':'l'">+50</text>
<text>库存96</text>
<text>摘要:服务指令</text>
</view>
</view>
</scroll-view>
@ -82,7 +82,7 @@
position: fixed;
right: 32vw;
top: 7vw;
padding: 1.5vw;
padding: 1.7vw;
z-index: 112;
.titletop{
width: 100%;
@ -99,7 +99,7 @@
.cgrk {
width: 100%;
height: 8.5vw;
height: 11vw;
background: rgba(236, 237, 239, 0.4);
border-radius: 1.6vw;
margin: 0.8vw auto 0;
@ -118,13 +118,13 @@
&:nth-child(2),
&:nth-child(3) {
font-weight: 400;
font-size: 1.1vw;
font-size: 1.4vw;
color: #888888;
}
&:nth-child(1) {
font-weight: bold;
font-size: 1.2vw;
font-size: 1.5vw;
color: #333333;
}
}
@ -141,13 +141,13 @@
text {
font-weight: 400;
font-size: 1.1vw;
font-size: 1.4vw;
color: #888888;
text-align: right;
&:nth-child(2) {
font-weight: bold;
font-size: 1.4vw;
font-size: 1.8vw;
color: #333333;
}
}
@ -172,7 +172,7 @@
text {
font-weight: 400;
font-size: 1.1vw;
font-size: 1.5vw;
color: #555555;
}
}

View File

@ -31,12 +31,12 @@
</view>
</scroll-view>
<view class="kjlt more guodu" :style="qb?'width:11.2vw':''">
<view @click="qb=!qb" class="righ0">
<view @click="qb=!qb;moredex=0" class="righ0">
{{!qb?'更多':'收起'}}
<image class="guodu" :style="qb?'transform: rotate(180deg);':''" src="/static/index/procurement/zjt.png" mode="aspectFill"></image>
</view>
<view class="guodu" :class="qb?'':'righ0'" @click="Invenshow = true">查看全部</view>
<view class="guodu" :class="qb?'':'righ0'">添加全部</view>
<view class="guodu" :class="qb?(moredex==1?'avt':''):'righ0'" @click="moredex=1;Invenshow=true">查看全部</view>
<view class="guodu" :class="qb?(moredex==2?'avt':''):'righ0'" @click="moredex=2">添加全部</view>
</view>
<view class="kaprght">
@ -74,7 +74,8 @@
</view>
<view class="listcard">
<carditem :InvoicingList="InvoicingList" @addcar="addcard" @addcartory="addcartory" @scrolltolower="scrolltolower" :status="status"></carditem>
<carditem :InvoicingList="InvoicingList" @addcartory="addcartory"
@scrolltolower="scrolltolower" :status="status" @crk="crk"></carditem>
</view>
<view class="fiedright">
<view @click="uni.navigateTo({ url:'/pages/procurement/materialcar' })">
@ -87,14 +88,12 @@
</view>
<!-- num -->
<view class="mengban" style="z-index: 119;" v-if="addflag" @click="qk"></view>
<calculator :show="addflag" @jjnum="jjnum" :caigouobj="caigouobj"
:translateNumber="caigouobj?.Limitnum" :doOnce="caigouobj?.Limitnum
" @colse="qk" @right="right"></calculator>
<calculator :show="addflag" @jjnum="jjnum" :caigouobj="caigouobj" @colse="qk" @right="right"></calculator>
<!-- 筛选 -->
<view class="mengban" v-if="ification" @click="qk"></view>
<classification @confirm="confirm" :show="ification"></classification>
<!-- more -->
<view class="mengban" v-if="Invenshow" @click="Invenshow = false"></view>
<view class="mengban" v-if="Invenshow" @click="Invenshow = false;moredex=0"></view>
<Inventory @addcartory="addcartory" :show="Invenshow" :InvoicingList="Material"
:status="statustory" @tolower="scrolltolower(1)"></Inventory>
@ -103,6 +102,9 @@
<view class="mengban" v-if="crkflag" @click="crkflag = false"></view>
<inboundoutbound :crk="crkflag"></inboundoutbound>
<view class="mengban" v-if="moredex==2" @click="moredex=0"></view>
<addall :show="moredex==2" @back="moredex=0" @config="config"></addall>
</view>
</template>
@ -116,13 +118,16 @@
import carditem from './components/carditem.vue'
import detail from './components/details.vue'
import inboundoutbound from './components/inboundoutbound.vue'
import addall from './components/addall.vue'
const qb = ref(false)
const addflag = ref(false)
const ification = ref(false)
const Invenshow = ref(false)
const detailsshow = ref(false)
const crkflag = ref(true)
const crkflag = ref(false)
const addalls = ref(false)
const moredex = ref(0)
const InvoicingList = ref([]);
const caigouobj = ref({})
const status = ref('loading')
@ -138,7 +143,8 @@
typeId: '',
medicationId: '',
wlParamInfo: '',
isWaring: 0
isWaring: 0,
suppliers:''
})
const warn = reactive({
nuId: uni.getStorageSync('nuId'),
@ -171,6 +177,12 @@
setout1.value = (res.result.total == Material.value.length ? false : true)
})
}
const config = ()=>{
warn.pageNo = 1;
Material.value = [];
getWaringMaterial();
moredex.value=0
}
const carnum = ref(0)
const shoppcar=()=>{
let c = {
@ -179,7 +191,6 @@
pageSize: 10
}
queryShoppingCartList(c).then(resr=>{
console.log(resr.result.total)
carnum.value = resr.result.total
})
}
@ -213,6 +224,7 @@
form.categoryId = e.categoryId;
form.typeId = e.typeId;
form.medicationId = e.medicationId;
form.suppliers = e.suppliers;
form.pageNo=1;
InvoicingList.value = [];
queryInvo();
@ -240,34 +252,27 @@
caigouobj.value = e;
addflag.value = true;
}
const addcar = (v:any,i:number)=>{
addflag.value = true;
}
const jjnum = (e:number) =>{
let n = Number(caigouobj.value.upperLimit)-Number(caigouobj.value.kcsl)
if(n==caigouobj.value.Limitnum&&e==1){return}
if(caigouobj.value.Limitnum==1&&e==-1){return}
caigouobj.value.Limitnum+=e;
}
const right = (n:number,nm:any) => {
let d = Number(caigouobj.value.upperLimit)-Number(caigouobj.value.kcsl)
const right = (n:number,nm:any,type:Object) => {
// let d = Number(caigouobj.value.upperLimit)-Number(caigouobj.value.kcsl)
if(d>=n){
caigouobj.value.Limitnum = n;
}else{
caigouobj.value.Limitnum = d;
}
if(n<1){
caigouobj.value.Limitnum = 1;
}
connfig(nm)
}
const addcard=(n:any,nm:any)=>{
caigouobj.value = n;
connfig(nm)
// if(d>=n){
// caigouobj.value.Limitnum = n;
// }else{
// caigouobj.value.Limitnum = d;
// }
// if(n<1){
// caigouobj.value.Limitnum = 1;
// }
connfig(nm,n,type)
}
const timers = ref(true)
const connfig = (nm:any) =>{
const connfig = (nm:any,num:Number,type:Object) =>{
if(timers.value==false){return}
if(caigouobj.value.izEnabled=='1'){
uni.showToast({
@ -279,11 +284,14 @@
timers.value=false;
let dt = {
nuId:form.nuId,
purchaseQuantity:caigouobj.value.Limitnum,
purchaseQuantity:num,
suppliersId:nm.id,
suppliersName:nm.name,
wlId:caigouobj.value.wlId,
kcsl:caigouobj.value.kcsl
kcsl:caigouobj.value.kcsl,
wlUnits:type.unit,
referenceUnitPrice:type.price,
dhbl:type.num
}
addShoppingCartList([dt]).then(res=>{
uni.showToast({
@ -338,7 +346,9 @@
lastTap.value = now
}
}
const crk=(v,i)=>{
crkflag.value = true
}
</script>
<style scoped lang="less">
@ -581,7 +591,7 @@
.righ0 {
right: 0 !important;
}
view {
writing-mode: vertical-rl;
align-items: center;
@ -594,13 +604,13 @@
top: 0;
border-radius: 1.1vw;
font-size: 1.4vw;
color: #888888;
background: #fff;
&:nth-child(1) {
letter-spacing: 6px;
padding-top: 2vw;
z-index: 5;
background: rgba(255, 255, 255, 1);
image {
width: 1.6vw;
height: 1.6vw;
@ -609,19 +619,19 @@
}
&:nth-child(2) {
background: rgba(85, 166, 249, 1);
color: #FFFFFF;
right: 4.5vw;
z-index: 3;
}
&:nth-child(3) {
color: #888888;
background: #fff;
right: 8.5vw;
z-index: 2;
}
}
.avt{
background: rgba(85, 166, 249, 1);
color: #FFFFFF;
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 694 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 442 B

View File

@ -574,7 +574,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
)
]);
}
const camera = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["styles", [_style_0]], ["__file", "D:/hldy_app_mini/pages/camera.nvue"]]);
const camera = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["styles", [_style_0]], ["__file", "D:/项目/hldy_app_mini/pages/camera.nvue"]]);
export {
camera as default
};

View File

@ -577,7 +577,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
)
]);
}
const fullcamera = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["styles", [_style_0]], ["__file", "D:/hldy_app_mini/pages/fullcamera.nvue"]]);
const fullcamera = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["styles", [_style_0]], ["__file", "D:/项目/hldy_app_mini/pages/fullcamera.nvue"]]);
export {
fullcamera as default
};