Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica.cloud.web-education-admin
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
提交
打开侧边栏
com.pica.cloud.education.frontend
pica.cloud.web-education-admin
提交
e0ef2c11
提交
e0ef2c11
编写于
2月 22, 2022
作者:
shuang.zhou
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
新增商品页改造
上级
11195270
变更
5
展开全部
隐藏空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
19330 行增加
和
6481 行删除
+19330
-6481
package-lock.json
package-lock.json
+12490
-120
index.js
src/utils/goods/index.js
+19
-0
create-good.vue
src/views/goods/create-good.vue
+65
-6
forms.js
src/views/goods/forms.js
+3
-1
yarn.lock
yarn.lock
+6753
-6354
未找到文件。
package-lock.json
浏览文件 @
e0ef2c11
此差异已折叠。
点击以展开。
src/utils/goods/index.js
浏览文件 @
e0ef2c11
...
@@ -142,5 +142,24 @@ export const getBusinessCategory = () => {
...
@@ -142,5 +142,24 @@ export const getBusinessCategory = () => {
});
});
};
};
export
const
getContractList
=
(
projectId
)
=>
{
return
fetch
({
headers
,
url
:
getBaseUrl
(
`store/contract/options/queryByProjectId/
${
projectId
}
`
),
method
:
"get"
,
description
:
"查询合同"
,
});
};
export
const
getCooperationProjectList
=
()
=>
{
return
fetch
({
headers
,
url
:
getBaseUrl
(
`store/cooperation/project/options/query`
),
method
:
"get"
,
description
:
"查询合作项目"
,
});
};
src/views/goods/create-good.vue
浏览文件 @
e0ef2c11
...
@@ -140,6 +140,37 @@
...
@@ -140,6 +140,37 @@
></el-option>
></el-option>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<!-- 新增项目合同名称 -->
<el-form-item
label=
"项目名称"
prop=
"cooperationProjectId"
>
<el-select
v-model=
"formData3.cooperationProjectId"
placeholder=
"请选择"
size=
"small"
:disabled=
"isEdit && isProject"
@
change=
"getContract"
filterable
>
<el-option
v-for=
"(item,index) in cooperationProjectList"
:key=
"item.projectName+'-'+index"
:label=
"item.projectName"
:value=
"item.cooperationProjectId"
></el-option>
</el-select>
</el-form-item>
<el-form-item
label=
"合同名称"
prop=
"contractId"
>
<el-select
v-model=
"formData3.contractId"
placeholder=
"请选择"
size=
"small"
:disabled=
"isEdit && isContract"
>
<el-option
v-for=
"(item,index) in contractList"
:key=
"item.contractName+'-'+index"
:label=
"item.contractName"
:value=
"item.contractId"
></el-option>
</el-select>
</el-form-item>
<el-form-item
label=
"是否支持售后"
prop=
"expressLimitFlag"
v-if=
"storeType
<
3
"
>
<el-form-item
label=
"是否支持售后"
prop=
"expressLimitFlag"
v-if=
"storeType
<
3
"
>
...
@@ -870,7 +901,7 @@
...
@@ -870,7 +901,7 @@
import
{
openLoading
,
closeLoading
,
signFigures
}
from
"../../utils/utils"
;
import
{
openLoading
,
closeLoading
,
signFigures
}
from
"../../utils/utils"
;
import
{
isEmptyUtils
}
from
"@/utils/index"
;
import
{
isEmptyUtils
}
from
"@/utils/index"
;
import
{
doUpload
,
getFilePath
,
createFilePath
}
from
"../../utils/qiniu-util"
;
import
{
doUpload
,
getFilePath
,
createFilePath
}
from
"../../utils/qiniu-util"
;
import
{
updateGoods
,
updateStock
,
dosageAll
,
getDeparts
,
getGoodsList
,
getGoodDetails
,
updateGoodsV2
,
getHospitalInfoByStoreId
,
getCheckPackageIdList
,
getTypeCodeList
,
getBusinessCategory
}
from
'@/utils/goods'
;
import
{
updateGoods
,
updateStock
,
dosageAll
,
getDeparts
,
getGoodsList
,
getGoodDetails
,
updateGoodsV2
,
getHospitalInfoByStoreId
,
getCheckPackageIdList
,
getTypeCodeList
,
getBusinessCategory
,
getContractList
,
getCooperationProjectList
}
from
'@/utils/goods'
;
import
{
getStoreAdressRepot
}
from
"@/utils/shop"
;
import
{
getStoreAdressRepot
}
from
"@/utils/shop"
;
import
Cropper
from
'@/components/common/cropper.vue'
import
Cropper
from
'@/components/common/cropper.vue'
import
{
originRules1
,
originRules2
,
originRules
,
originRules3
}
from
'./rules'
;
import
{
originRules1
,
originRules2
,
originRules
,
originRules3
}
from
'./rules'
;
...
@@ -1014,6 +1045,10 @@
...
@@ -1014,6 +1045,10 @@
businessCategoryList
:[],
businessCategoryList
:[],
sumFile
:
0
,
sumFile
:
0
,
uploadProgress
:
0
,
// 上传视频进度条
uploadProgress
:
0
,
// 上传视频进度条
cooperationProjectList
:
[],
// 合作项目
contractList
:
[],
// 合同
isProject
:
false
,
// 是否选择合作项目
isContract
:
false
,
// 是否选择合同
}
}
},
},
computed
:
{
computed
:
{
...
@@ -1047,6 +1082,8 @@
...
@@ -1047,6 +1082,8 @@
this
.
getTypeCodeList
();
this
.
getTypeCodeList
();
this
.
getBusinessCategory
();
this
.
getBusinessCategory
();
this
.
getLever
(
0
,
1
)
this
.
getLever
(
0
,
1
)
this
.
getCooperationProjectList
();
this
.
getContractList
();
dosageAll
().
then
((
res
)
=>
{
dosageAll
().
then
((
res
)
=>
{
this
.
doseAll
=
res
.
data
this
.
doseAll
=
res
.
data
if
(
!
this
.
doseAll
)
{
if
(
!
this
.
doseAll
)
{
...
@@ -1078,6 +1115,25 @@
...
@@ -1078,6 +1115,25 @@
}
}
},
},
methods
:
{
methods
:
{
// 获取合同
getContractList
(
projectId
)
{
getContractList
(
projectId
||
0
).
then
(
res
=>
{
if
(
res
.
code
==
'000000'
)
{
this
.
contractList
=
res
.
data
;
}
})
},
// 获取合作项目
getCooperationProjectList
()
{
getCooperationProjectList
().
then
(
res
=>
{
if
(
res
.
code
==
'000000'
)
{
this
.
cooperationProjectList
=
res
.
data
;
}
})
},
getContract
(
projectId
)
{
this
.
getContractList
(
projectId
);
},
// 获取业务类型
// 获取业务类型
getBusinessCategory
(){
getBusinessCategory
(){
getBusinessCategory
().
then
((
res
)
=>
{
getBusinessCategory
().
then
((
res
)
=>
{
...
@@ -1135,12 +1191,13 @@
...
@@ -1135,12 +1191,13 @@
};
};
const
{
goodsInfo
,
medicalService
,
buyLimitDtoList
,
hasRepoFlag
}
=
res
.
data
;
const
{
goodsInfo
,
medicalService
,
buyLimitDtoList
,
hasRepoFlag
}
=
res
.
data
;
const
{
goodsName
,
goodsDescription
,
goodsType
,
businessCategoryId
,
expressLimitFlag
,
goodsHeaderImages
=
[],
goodsVideoList
=
[]
}
=
goodsInfo
;
const
{
goodsName
,
goodsDescription
,
goodsType
,
businessCategoryId
,
expressLimitFlag
,
goodsHeaderImages
=
[],
goodsVideoList
=
[],
contractId
,
cooperationProjectId
}
=
goodsInfo
;
this
.
isProject
=
cooperationProjectId
;
this
.
isContract
=
contractId
;
this
.
formData
=
{...
this
.
formData
,
...
goodsInfo
};
this
.
formData
=
{...
this
.
formData
,
...
goodsInfo
};
this
.
formData2
=
medicalService
;
this
.
formData2
=
medicalService
;
this
.
formData
=
{
...
this
.
formData
,
...
this
.
formData2
};
this
.
formData
=
{
...
this
.
formData
,
...
this
.
formData2
};
this
.
formData3
=
{
goodsName
,
goodsDescription
,
goodsHeaderImages
,
goodsVideoList
,
goodsType
,
businessCategoryId
,
expressLimitFlag
};
this
.
formData3
=
{
goodsName
,
goodsDescription
,
goodsHeaderImages
,
goodsVideoList
,
goodsType
,
businessCategoryId
,
expressLimitFlag
,
cooperationProjectId
,
contractId
};
this
.
buyLimitDtoList
=
buyLimitDtoList
;
this
.
buyLimitDtoList
=
buyLimitDtoList
;
this
.
hasRepoFlag
=
hasRepoFlag
;
this
.
hasRepoFlag
=
hasRepoFlag
;
this
.
$set
(
this
.
formData2
,
'suitableArr'
,
this
.
formData
.
suitable
.
split
(
','
));
this
.
$set
(
this
.
formData2
,
'suitableArr'
,
this
.
formData
.
suitable
.
split
(
','
));
...
@@ -1192,12 +1249,14 @@
...
@@ -1192,12 +1249,14 @@
});
});
}
}
const
{
goodsList
,
hasRepoFlag
}
=
res
.
data
;
const
{
goodsList
,
hasRepoFlag
}
=
res
.
data
;
const
{
goodsName
,
goodsDescription
,
goodsType
,
businessCategoryId
,
expressLimitFlag
,
goodsHeaderImages
=
[],
goodsVideoList
=
[]
}
=
goodsList
[
0
];
const
{
goodsName
,
goodsDescription
,
goodsType
,
businessCategoryId
,
expressLimitFlag
,
goodsHeaderImages
=
[],
goodsVideoList
=
[]
,
contractId
,
cooperationProjectId
}
=
goodsList
[
0
];
const
goodDet
=
goodsList
[
0
];
const
goodDet
=
goodsList
[
0
];
goodDet
.
otc1
=
goodDet
.
otc
?
'1'
:
'0'
;
goodDet
.
otc1
=
goodDet
.
otc
?
'1'
:
'0'
;
this
.
isProject
=
cooperationProjectId
;
this
.
isContract
=
contractId
;
this
.
formData1
=
goodDet
;
this
.
formData1
=
goodDet
;
this
.
formData
=
goodDet
;
this
.
formData
=
goodDet
;
this
.
formData3
=
{
goodsName
,
goodsDescription
,
goodsHeaderImages
,
goodsVideoList
,
goodsType
,
businessCategoryId
,
expressLimitFlag
};
this
.
formData3
=
{
goodsName
,
goodsDescription
,
goodsHeaderImages
,
goodsVideoList
,
goodsType
,
businessCategoryId
,
expressLimitFlag
,
contractId
,
cooperationProjectId
};
this
.
hasRepoFlag
=
hasRepoFlag
;
this
.
hasRepoFlag
=
hasRepoFlag
;
this
.
buyLimitDtoList
=
this
.
formData
.
buyLimitDtoList
;
this
.
buyLimitDtoList
=
this
.
formData
.
buyLimitDtoList
;
this
.
formData
.
optPrice
=
this
.
formData
.
costPrice
/
100
;
this
.
formData
.
optPrice
=
this
.
formData
.
costPrice
/
100
;
...
...
src/views/goods/forms.js
浏览文件 @
e0ef2c11
...
@@ -76,8 +76,10 @@ const form3 = {
...
@@ -76,8 +76,10 @@ const form3 = {
goodsHeaderImages
:
[],
goodsHeaderImages
:
[],
goodsVideoList
:
[],
goodsVideoList
:
[],
goodsType
:
""
,
goodsType
:
""
,
businessCategoryId
:
""
,
businessCategoryId
:
""
,
expressLimitFlag
:
0
,
//是否支持退货退款
expressLimitFlag
:
0
,
//是否支持退货退款
cooperationProjectId
:
''
,
// 合作项目id
contractId
:
''
,
// 合同id
};
};
...
...
yarn.lock
浏览文件 @
e0ef2c11
此差异已折叠。
点击以展开。
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录