master
toesbieya 6 years ago
parent aed701c2ec
commit 8cb4d32cd9
  1. 4
      vue/src/assets/styles/variables.scss
  2. 2
      vue/src/components/Skeleton/index.vue
  3. 2
      vue/src/config/index.js
  4. 42
      vue/src/directive/ripple/style.sass
  5. 4
      vue/src/utils/file.js
  6. 8
      vue/src/views/purchase/inbound/components/EditDialog.vue
  7. 4
      vue/src/views/sell/order/components/EditDialog.vue
  8. 12
      vue/src/views/sell/outbound/components/EditDialog.vue

@ -20,8 +20,8 @@ $--color-gray: #9E9E9E;
$--color-blue-gray: #607D8B;
//覆盖element颜色
$--color-primary: $--color-blue;
$--color-success: $--color-green;
$--color-primary: #1890ff;
$--color-success: #21BA45;
$--color-warning: $--color-deep-orange;
$--color-danger: $--color-red;
$--color-info: $--color-teal;

@ -32,7 +32,7 @@
(animation !== 'none' ? ` q-skeleton--anim-${animation}` : '') +
(square === true ? ' q-skeleton--square' : '') +
(bordered === true ? ' q-skeleton--bordered' : '') +
(className !== undefined ? ' '+className : '')
(className !== undefined ? ' ' + className : '')
return h(tag, {
staticClass: 'q-skeleton',

@ -31,5 +31,5 @@ module.exports = {
attachmentPrefix: 'https://static.toesbieya.cn/',
//省市地区json数据请求地址
regionDataUrl:'/static/json/region-pca.json'
regionDataUrl: '/static/json/region-pca.json'
}

@ -1,29 +1,29 @@
.q-ripple
position: absolute
top: 0
left: 0
width: 100%
height: 100%
color: inherit
border-radius: inherit
z-index: 0
pointer-events: none
overflow: hidden
contain: strict
&__inner
position: absolute
top: 0
left: 0
opacity: 0
width: 100%
height: 100%
color: inherit
border-radius: 50%
background: currentColor
border-radius: inherit
z-index: 0
pointer-events: none
will-change: transform, opacity
overflow: hidden
contain: strict
&__inner
position: absolute
top: 0
left: 0
opacity: 0
color: inherit
border-radius: 50%
background: currentColor
pointer-events: none
will-change: transform, opacity
&--enter
transition: transform .225s cubic-bezier(.4, 0, .2, 1), opacity .1s cubic-bezier(.4, 0, .2, 1)
&--enter
transition: transform .225s cubic-bezier(.4, 0, .2, 1), opacity .1s cubic-bezier(.4, 0, .2, 1)
&--leave
transition: opacity .25s cubic-bezier(.4, 0, .2, 1)
&--leave
transition: opacity .25s cubic-bezier(.4, 0, .2, 1)

@ -1,5 +1,5 @@
import request from '@/config/request'
import {attachmentUploadUrl,attachmentPrefix} from '@/config'
import {attachmentUploadUrl, attachmentPrefix} from '@/config'
import {isEmpty, timeFormat} from "@/utils"
const baseUrl = '/file'
@ -47,6 +47,6 @@ export function upload(blob, filename = '快照.png') {
//自动补全附件链接前缀
export function autoCompleteUrl(url) {
if (isEmpty(url)) return ''
if (['http','https'].some(i=>url.startsWith(i))) return url
if (['http', 'https'].some(i => url.startsWith(i))) return url
return attachmentPrefix + url
}

@ -64,7 +64,7 @@
v-model="row.num"
:min="0"
size="small"
@change="changeInboundNum($event,row)"
@change="(nv,ov)=>changeInboundNum(nv,ov,row)"
/>
<span v-else>{{row.num}}</span>
</template>
@ -128,10 +128,10 @@
num: i.remain_num
}))
},
changeInboundNum(v, row) {
changeInboundNum(nv, ov, row) {
let parentSub = this.parentSubList.find(i => i.cid === row.cid)
if (!parentSub || v > parentSub.remain_num) {
return elAlert(`${row.cname}的入库数量超出采购数量`, () => row.num = parentSub.remain_num)
if (!parentSub || nv > parentSub.remain_num) {
return elAlert(`${row.cname}的入库数量超出采购数量`, () => row.num = ov)
}
},
validate() {

@ -126,7 +126,7 @@
customer_name: null,
finish: 0,
ftime: null,
total:0
total: 0
},
rules: {
customer_name: [{required: true, message: '客户不能为空', trigger: 'change'}]
@ -174,7 +174,7 @@
if (isEmpty(sub.price)) return `${index + 1}个商品单价不能为空`
if (sub.num < 0 || !isInteger(sub.num)) return `${index}个商品数量有误`
if (sub.price <= 0 || !isInteger(sub.price)) return `${index}个商品单价有误`
this.form.total=plus(this.form.total,mul(sub.num, sub.price))
this.form.total = plus(this.form.total, mul(sub.num, sub.price))
index++
}
return null

@ -69,7 +69,7 @@
v-model="d.row.num"
:min="0"
size="small"
@change="changeOutboundNum($event,d.row,row)"
@change="(nv,ov)=>changeOutboundNum(nv,ov,d.row,row)"
/>
<span v-else>{{d.row.num}}</span>
</template>
@ -208,9 +208,9 @@
return sum
}
},
changeOutboundNum(v, row, displayTableRow) {
if (v > row.max_num) {
return elAlert(`${row.cname}的出库数量超出库存数量`, () => row.num = row.max_num)
changeOutboundNum(nv, ov, row, displayTableRow) {
if (nv > row.max_num) {
return elAlert(`${row.cname}的出库数量超出库存数量`, () => row.num = ov)
}
let outboundNum = displayTableRow.data.map(i => i.num)
@ -219,10 +219,10 @@
if (!outboundNum) return
if (outboundNum > displayTableRow.remain_num) {
let correctNum = sub(displayTableRow.remain_num, sub(outboundNum, v))
let correctNum = sub(displayTableRow.remain_num, sub(outboundNum, nv))
if (correctNum < 0) correctNum = 0
else if (correctNum > row.max_num) correctNum = row.max_num
return elAlert(`${displayTableRow.cname}的出库数量超出销售数量`, () => row.num = correctNum)
return elAlert(`${displayTableRow.cname}的出库数量超出销售数量`, () => row.num = ov)
}
},
validate() {

Loading…
Cancel
Save