Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica.cloud.web-education-admin
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
提交
打开侧边栏
com.pica.cloud.education.frontend
pica.cloud.web-education-admin
提交
d29b3210
提交
d29b3210
编写于
9月 06, 2024
作者:
zhongyao.qiao
浏览文件
操作
浏览文件
下载
差异文件
Merge remote-tracking branch 'origin/release' into feature/qiao
上级
3ba9c2c3
ccbc4196
变更
2
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
74 行增加
和
28 行删除
+74
-28
create-good-new.scss
src/views/goods/create-good-new.scss
+5
-1
create-good-new.vue
src/views/goods/create-good-new.vue
+69
-27
未找到文件。
src/views/goods/create-good-new.scss
浏览文件 @
d29b3210
...
@@ -113,7 +113,7 @@
...
@@ -113,7 +113,7 @@
}
}
.backTip
{
.backTip
{
font-size
:
12px
;
font-size
:
12px
;
color
:
red
;
color
:
#f56c6c
;
cursor
:
pointer
;
cursor
:
pointer
;
}
}
.ad-back
{
.ad-back
{
...
@@ -349,4 +349,8 @@
...
@@ -349,4 +349,8 @@
height
:
100%
;
height
:
100%
;
}
}
}
}
.tips
{
color
:
#f56c6c
;
}
}
}
src/views/goods/create-good-new.vue
浏览文件 @
d29b3210
...
@@ -388,7 +388,7 @@
...
@@ -388,7 +388,7 @@
<div
class=
"part-tit"
>
销售信息
</div>
<div
class=
"part-tit"
>
销售信息
</div>
<div
class=
"inline"
>
<div
class=
"inline"
>
<el-form-item
label=
"销售方式"
prop=
"saleType"
>
<el-form-item
label=
"销售方式"
prop=
"saleType"
>
<el-radio-group
v-model=
"formData.saleType"
size=
"small"
>
<el-radio-group
@
change=
"handleSaleTypeChange"
v-model=
"formData.saleType"
size=
"small"
>
<el-radio
:label=
"1"
>
零售
</el-radio>
<el-radio
:label=
"1"
>
零售
</el-radio>
<el-radio
:label=
"2"
:disabled=
"commissionFlag == 1"
<el-radio
:label=
"2"
:disabled=
"commissionFlag == 1"
>
批发
</el-radio
>
批发
</el-radio
...
@@ -500,7 +500,7 @@
...
@@ -500,7 +500,7 @@
class
=
"required-label"
class
=
"required-label"
>
>
<
el
-
col
:
span
=
"20"
>
<
el
-
col
:
span
=
"20"
>
<
div
class
=
"stock-com"
style
=
"width: 5
0
0px; display: flex"
>
<
div
class
=
"stock-com"
style
=
"width: 5
5
0px; display: flex"
>
<
el
-
input
-
number
<
el
-
input
-
number
class
=
"stock-com"
class
=
"stock-com"
@
input
=
"$forceUpdate()"
@
input
=
"$forceUpdate()"
...
@@ -535,15 +535,14 @@
...
@@ -535,15 +535,14 @@
<
/el-col
>
<
/el-col
>
<
/el-form-item
>
<
/el-form-item
>
<
/div
>
<
/div
>
<
div
class
=
"inline"
>
<
div
class
=
"inline"
v
-
if
=
"formData.saleType == 1"
>
<
el
-
form
-
item
<
el
-
form
-
item
label
=
"单次购买上限"
label
=
"单次购买上限"
prop
=
"mostCount"
prop
=
"mostCount"
class
=
"required-label"
class
=
"required-label"
>
>
<
el
-
col
:
span
=
"20"
style
=
"width: 300%"
>
<
el
-
col
:
span
=
"20"
style
=
"width: 300%"
>
<
div
class
=
"stock-com"
style
=
"width: 5
0
0px; display: flex"
>
<
div
class
=
"stock-com"
style
=
"width: 5
5
0px; display: flex"
>
<
el
-
input
-
number
<
el
-
input
-
number
class
=
"stock-com"
class
=
"stock-com"
@
input
=
"$forceUpdate()"
@
input
=
"$forceUpdate()"
...
@@ -553,9 +552,10 @@
...
@@ -553,9 +552,10 @@
:
min
=
"-1"
:
min
=
"-1"
:
max
=
"9999"
:
max
=
"9999"
><
/el-input-number
>
><
/el-input-number
>
<
span
class
=
"word-num"
style
=
"margin-left: 10px"
<
span
class
=
"word-num"
style
=
"margin-left: 10px"
>
>
数值为
-
1
时,代表单次购买上限已无限制
(
最高
9999
件哦
)
<
/spa
n
数值为
-
1
时,代表单次购买上限已无限制
(
最高
9999
件哦
)
>
<
span
v
-
if
=
"formData.saleType == 2"
class
=
"tips"
>
(
仅
CRM
生效
)
<
/span
>
<
/span
>
<
/div
>
<
/div
>
<
p
class
=
"error-message"
v
-
if
=
"formData.mostCount === 0"
>
<
p
class
=
"error-message"
v
-
if
=
"formData.mostCount === 0"
>
单次购买上限不能为
0
单次购买上限不能为
0
...
@@ -596,7 +596,7 @@
...
@@ -596,7 +596,7 @@
class
=
"required-label"
class
=
"required-label"
>
>
<
el
-
col
:
span
=
"20"
>
<
el
-
col
:
span
=
"20"
>
<
div
class
=
"stock-com"
style
=
"width: 5
0
0px; display: flex"
>
<
div
class
=
"stock-com"
style
=
"width: 5
5
0px; display: flex"
>
<
el
-
input
-
number
<
el
-
input
-
number
class
=
"stock-com"
class
=
"stock-com"
@
input
=
"$forceUpdate()"
@
input
=
"$forceUpdate()"
...
@@ -632,8 +632,8 @@
...
@@ -632,8 +632,8 @@
<
/p
>
<
/p
>
<
/el-form-item
>
<
/el-form-item
>
<
/div
>
<
/div
>
<
div
class
=
"basic-item-icon"
v
-
if
=
"formData.saleType == 1"
>
<
div
class
=
"basic-item-icon"
>
<
div
class
=
"part-tit"
>
限购条件
<
/div
>
<
div
class
=
"part-tit"
>
限购条件
<
span
v
-
if
=
"formData.saleType == 2"
class
=
"tips"
>
(仅
CRM
生效)
<
/span><
/
div
>
<
div
v
-
for
=
"(item, index) in buyLimitDtoList"
:
key
=
"index"
>
<
div
v
-
for
=
"(item, index) in buyLimitDtoList"
:
key
=
"index"
>
<
el
-
form
-
item
label
=
"限制条件"
>
<
el
-
form
-
item
label
=
"限制条件"
>
<
el
-
button
@
click
=
"delLimit(index)"
type
=
"text"
size
=
"small"
<
el
-
button
@
click
=
"delLimit(index)"
type
=
"text"
size
=
"small"
...
@@ -647,8 +647,10 @@
...
@@ -647,8 +647,10 @@
size
=
"small"
size
=
"small"
@
change
=
"changeLimitUserType(item, index)"
@
change
=
"changeLimitUserType(item, index)"
>
>
<
el
-
radio
:
label
=
"1"
>
开单人
<
/el-radio
>
<!--
<
el
-
radio
:
label
=
1
>
开单人
<
/el-radio
>
<
el
-
radio
:
label
=
"2"
>
患者
<
/el-radio
>
<
el
-
radio
:
label
=
2
>
患者
<
/el-radio
>
<
el
-
radio
:
label
=
3
>
单个机构
<
/el-radio> --
>
<
el
-
radio
v
-
for
=
"(i, idx) in userTypeList"
:
label
=
"i.value"
:
key
=
"idx"
>
{{
i
.
label
}}
<
/el-radio
>
<
/el-radio-group
>
<
/el-radio-group
>
<
/el-col
>
<
/el-col
>
<
/el-form-item
>
<
/el-form-item
>
...
@@ -1102,6 +1104,25 @@ export default {
...
@@ -1102,6 +1104,25 @@ export default {
}
;
}
;
}
,
}
,
computed
:
{
computed
:
{
userTypeList
()
{
const
wholesale
=
[
{
label
:
'开单人'
,
value
:
1
}
,
{
label
:
'患者'
,
value
:
2
}
]
const
retail
=
[
{
label
:
'单个机构'
,
value
:
3
}
]
return
this
.
formData
.
saleType
===
1
?
wholesale
:
retail
;
}
,
mCommonName
()
{
mCommonName
()
{
return
[
4
,
5
].
includes
(
this
.
formData1
.
medicalCategoryId
)
return
[
4
,
5
].
includes
(
this
.
formData1
.
medicalCategoryId
)
?
"产品名称"
?
"产品名称"
...
@@ -1173,6 +1194,10 @@ export default {
...
@@ -1173,6 +1194,10 @@ export default {
radioChange
(
val
)
{
radioChange
(
val
)
{
this
.
formData
.
expressLimitFlag
=
val
;
this
.
formData
.
expressLimitFlag
=
val
;
}
,
}
,
handleSaleTypeChange
(
val
)
{
console
.
log
(
'handleSaleTypeChange'
,
val
)
this
.
buyLimitDtoList
=
[];
}
,
getArr
(
arr
)
{
getArr
(
arr
)
{
if
(
arr
.
length
>
0
)
{
if
(
arr
.
length
>
0
)
{
let
newoodsList
=
[];
let
newoodsList
=
[];
...
@@ -2065,25 +2090,34 @@ export default {
...
@@ -2065,25 +2090,34 @@ export default {
}
);
}
);
return
;
return
;
}
}
const
commonItem
=
{
days
:
0
,
daysType
:
1
,
limitCount
:
0
,
}
if
(
this
.
buyLimitDtoList
==
null
||
this
.
buyLimitDtoList
.
length
==
0
)
{
if
(
this
.
buyLimitDtoList
==
null
||
this
.
buyLimitDtoList
.
length
==
0
)
{
this
.
buyLimitDtoList
.
push
({
this
.
buyLimitDtoList
.
push
({
days
:
0
,
...
commonItem
,
daysType
:
1
,
limitUserType
:
this
.
formData
.
saleType
===
1
?
1
:
3
,
limitCount
:
0
,
limitUserType
:
1
,
}
);
}
);
return
;
return
;
}
}
if
(
this
.
buyLimitDtoList
.
length
<
2
)
{
if
(
this
.
buyLimitDtoList
.
length
<
2
)
{
if
(
this
.
formData
.
saleType
===
2
)
{
this
.
buyLimitDtoList
.
push
({
...
commonItem
,
limitUserType
:
3
,
}
);
return
}
let
limitUserType
=
1
;
let
limitUserType
=
1
;
if
(
this
.
buyLimitDtoList
[
0
].
limitUserType
==
1
)
{
if
(
this
.
buyLimitDtoList
[
0
].
limitUserType
==
1
)
{
limitUserType
=
2
;
limitUserType
=
2
;
}
}
this
.
buyLimitDtoList
.
push
({
this
.
buyLimitDtoList
.
push
({
days
:
0
,
...
commonItem
,
daysType
:
1
,
limitCount
:
0
,
limitUserType
:
limitUserType
,
limitUserType
:
limitUserType
,
}
);
}
);
}
}
...
@@ -2093,23 +2127,31 @@ export default {
...
@@ -2093,23 +2127,31 @@ export default {
this
.
buyLimitDtoList
.
splice
(
index
,
1
);
this
.
buyLimitDtoList
.
splice
(
index
,
1
);
}
,
}
,
changeLimitUserType
(
item
,
index
)
{
changeLimitUserType
(
item
,
index
)
{
if
(
item
.
limitUserType
==
1
)
{
if
(
item
.
limitUserType
==
=
1
)
{
if
(
this
.
buyLimitDtoList
.
length
==
2
&&
index
==
0
)
{
if
(
this
.
buyLimitDtoList
.
length
==
=
2
&&
index
=
==
0
)
{
this
.
buyLimitDtoList
[
1
].
limitUserType
=
2
;
this
.
buyLimitDtoList
[
1
].
limitUserType
=
2
;
}
else
if
(
this
.
buyLimitDtoList
.
length
==
2
&&
index
==
1
)
{
}
else
if
(
this
.
buyLimitDtoList
.
length
==
=
2
&&
index
=
==
1
)
{
this
.
buyLimitDtoList
[
0
].
limitUserType
=
2
;
this
.
buyLimitDtoList
[
0
].
limitUserType
=
2
;
}
}
}
else
{
}
if
(
this
.
buyLimitDtoList
.
length
==
2
&&
index
==
0
)
{
if
(
item
.
limitUserType
===
2
)
{
if
(
this
.
buyLimitDtoList
.
length
===
2
&&
index
===
0
)
{
this
.
buyLimitDtoList
[
1
].
limitUserType
=
1
;
this
.
buyLimitDtoList
[
1
].
limitUserType
=
1
;
}
else
if
(
this
.
buyLimitDtoList
.
length
==
2
&&
index
==
1
)
{
}
else
if
(
this
.
buyLimitDtoList
.
length
==
=
2
&&
index
=
==
1
)
{
this
.
buyLimitDtoList
[
0
].
limitUserType
=
1
;
this
.
buyLimitDtoList
[
0
].
limitUserType
=
1
;
}
}
}
}
if
(
item
.
limitUserType
===
3
)
{
if
(
this
.
buyLimitDtoList
.
length
===
2
&&
index
===
0
)
{
this
.
buyLimitDtoList
[
1
].
limitUserType
=
3
;
}
else
if
(
this
.
buyLimitDtoList
.
length
==
2
&&
index
==
1
)
{
this
.
buyLimitDtoList
[
0
].
limitUserType
=
3
;
}
}
}
,
}
,
checkCount
()
{
checkCount
()
{
let
flag
=
true
;
let
flag
=
true
;
if
(
this
.
formData
.
saleType
==
1
&&
this
.
formData
.
mostCount
==
0
)
{
if
(
this
.
formData
.
mostCount
==
0
)
{
flag
=
false
;
flag
=
false
;
this
.
$message
({
this
.
$message
({
message
:
"单次购买上限不能为0"
,
message
:
"单次购买上限不能为0"
,
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录