Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-app-operator-master
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lanbaoming
jiedao-app-operator-master
Commits
c9e6a2cf
Commit
c9e6a2cf
authored
Oct 28, 2024
by
xiamw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
src/views/ecw/product/index.vue
parent
39da2846
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
149 additions
and
12 deletions
+149
-12
index.vue
src/views/ecw/product/index.vue
+149
-12
No files found.
src/views/ecw/product/index.vue
View file @
c9e6a2cf
...
...
@@ -29,13 +29,31 @@
/>
</el-form-item>
<el-form-item
:label=
"$t('商品名称')"
prop=
"titleZh"
>
<
!--
<
el-form-item
:label=
"$t('商品名称')"
prop=
"titleZh"
>
<el-input
v-model=
"queryParams.titleZh"
:placeholder=
"$t('请输入商品名称')"
clearable
@
keyup.enter.native=
"handleQuery"
/>
</el-form-item>
-->
<el-form-item
:label=
"$t('商品名称')"
prop=
"titleZh"
>
<el-input
v-model.trim=
"titleZhParam.value"
:placeholder=
"$t('请输入商品名称')"
clearable
@
keyup.enter.native=
"handleQuery"
>
<template
slot=
"prepend"
>
<dict-selector
:type=
"DICT_TYPE.ORDER_QUERY_NO_FIELD"
defaultable
v-model=
"titleZhParam.key"
class=
"w-50"
/>
</
template
>
</el-input>
</el-form-item>
<el-form-item
:label=
"$t('商品类型')"
prop=
"attrId"
>
...
...
@@ -72,18 +90,71 @@
</el-select>
</el-form-item>
<!--
<el-form-item
:label=
"$t('审核状态')"
prop=
"auditStatus"
>
<el-form-item
:label=
"$t('商品材质')"
prop=
"materialTypes"
>
<dict-selector
multiple
clearable
v-model=
"queryParams.materialTypes"
:type=
"DICT_TYPE.ECW_PRODUCT_MATERIAL"
></dict-selector>
</el-form-item>
<el-form-item
:label=
"$t('审核状态')"
prop=
"auditStatus"
>
<el-select
v-model=
"queryParams.auditStatus"
:placeholder=
"$t('选择审核状态')"
clearable
>
<el-option
v-for=
"auditStatusItem in auditStatusDictDatas"
:key=
"auditStatusItem.id"
:label=
"auditStatusItem.label"
:value=
"auditStatusItem.value"
/>
</el-select>
</el-form-item>
<el-form-item
:label=
"$t('包装要求')"
prop=
"packaging"
>
<dict-selector
clearable
v-model=
"queryParams.packaging"
:type=
"DICT_TYPE.ECW_PACKAGING_TYPE"
></dict-selector>
</el-form-item>
<!--
<el-form-item :label="$t('上架状态')" prop="status">
<el-select v-model="queryParams.status" :placeholder="$t('选择上架状态')" clearable>
<el-option v-for="statusItem in statusDictDatas" :key="statusItem.id" :label="statusItem.value == CommonStatusEnum.ENABLE ? '已上架' : '已下架'" :value="statusItem.value" />
</el-select>
</el-form-item> -->
<el-form-item
:label=
"$t('创建时间')"
>
<el-date-picker
v-model=
"dateRangeCreateTime"
type=
"datetimerange"
:start-placeholder=
"$t('开始日期')"
value-format=
"yyyy-MM-dd HH:mm:ss"
:end-placeholder=
"$t('结束日期')"
>
</el-date-picker>
</el-form-item>
<!-- <el-form-item :label="$t('创建时间')" v-show="showSearch">
<el-date-picker
type="datetimerange"
clearable
v-model="dateRangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
range-separator="-"
:start-placeholder="$t('开始日期')"
:end-placeholder="$t('结束日期')"
/>
</el-form-item> -->
<el-form-item
:label=
"$t('创建人')"
prop=
"creator"
>
<el-input
v-model.trim=
"queryParams.creator"
:placeholder=
"$t('请输入创建人')"
clearable
@
keyup.enter.native=
"handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button
type=
"primary"
icon=
"el-icon-search"
@
click=
"handleQuery"
>
{{
$t("搜索")
...
...
@@ -159,12 +230,25 @@
/>
<el-table-column
:label=
"$t('中文标题')"
align=
"center"
prop=
"titleZh"
/>
<el-table-column
:label=
"$t('英文标题')"
align=
"center"
prop=
"titleEn"
/>
<el-table-column
:label=
"$t('商品
属
性')"
align=
"center"
prop=
"attrId"
>
<el-table-column
:label=
"$t('商品
特
性')"
align=
"center"
prop=
"attrId"
>
<
template
slot-scope=
"scope"
>
<span>
{{
getAttrName
(
scope
.
row
.
attrId
)
}}
</span>
</
template
>
</el-table-column>
<!--商品特性-->
<el-table-column
:label=
"$t('商品材质')"
align=
"center"
prop=
"materialType"
>
<
template
slot-scope=
"scope"
>
<span>
{{
getMaterialTypeName
(
scope
.
row
.
materialType
)
}}
</span>
</
template
>
</el-table-column>
<el-table-column
:label=
"$t('包装要求')"
align=
"center"
prop=
"packaging"
>
<
template
slot-scope=
"scope"
>
<span>
{{
getPackagingName
(
scope
.
row
.
packaging
)
}}
</span>
</
template
>
</el-table-column>
<!---->
<el-table-column
:label=
"$t('商品图片')"
align=
"center"
prop=
"attrId"
>
<
template
slot-scope=
"scope"
>
<el-image
...
...
@@ -178,7 +262,7 @@
<el-table-column
prop=
"auditStatus"
align=
"center"
:label=
"$t('
是否审核
')"
:label=
"$t('
审核状态
')"
width=
"120"
>
<
template
slot-scope=
"scope"
>
...
...
@@ -197,12 +281,12 @@
</el-table-column>
<el-table-column
:label=
"$t('
添加
人')"
:label=
"$t('
创建
人')"
align=
"center"
prop=
"creatorName"
/>
<el-table-column
:label=
"$t('
添加
时间')"
align=
"center"
>
<el-table-column
:label=
"$t('
创建
时间')"
align=
"center"
>
<
template
slot-scope=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
createTime
)
}}
</span>
</
template
>
...
...
@@ -342,7 +426,7 @@
<image-upload
v-model=
"form.imgs"
/>
</el-form-item>
<el-form-item
prop=
"auditStatus"
:label=
"$t('
是否审核
')"
>
<el-form-item
prop=
"auditStatus"
:label=
"$t('
审核状态
')"
>
<
template
slot-scope=
"scope"
>
<el-select
v-model=
"form.auditStatus"
>
<el-option
...
...
@@ -608,6 +692,12 @@ export default {
auditStatus
:
null
,
status
:
null
,
},
// 编号搜索条件
titleZhParam
:
{
key
:
"
titleZhKey
"
,
value
:
""
,
},
// 表单参数
form
:
{},
formCopy
:
{},
...
...
@@ -651,9 +741,10 @@ export default {
CommonStatusEnum
:
CommonStatusEnum
,
AuditStatusEnum
:
AuditStatusEnum
,
statusDictDatas
:
getDictDatas
(
DICT_TYPE
.
COMMON_STATUS
),
statusDictDatas
:
getDictDatas
(
DICT_TYPE
.
COMMON_STATUS
),
auditStatusDictDatas
:
getDictDatas
(
DICT_TYPE
.
AUDIT_STATUS
),
materialList
:
getDictDatas
(
DICT_TYPE
.
ECW_PRODUCT_MATERIAL
),
packagingList
:
getDictDatas
(
DICT_TYPE
.
ECW_PACKAGING_TYPE
),
packagingList
:
getDictDatas
(
DICT_TYPE
.
ECW_PACKA
A
GING_TYPE
),
locationList
:
getDictDatas
(
DICT_TYPE
.
ECW_CONTAINER_LOCATION
),
preferentialList
:
[],
exceptionProductId
:
0
,
//新增商品异常传的id
...
...
@@ -689,6 +780,32 @@ export default {
return
productAttrArray
.
join
(
"
,
"
);
};
},
getPackagingName
()
{
return
(
packagingId
)
=>
{
for
(
let
index
in
this
.
packagingList
)
{
let
typeItem
=
this
.
packagingList
[
index
];
if
(
typeItem
.
id
==
packagingId
)
{
return
this
.
$l
(
typeItem
,
"
title
"
);
}
}
};
},
getMaterialTypeName
()
{
return
(
materialTypeId
)
=>
{
for
(
let
index
in
this
.
materialList
)
{
let
typeItem
=
this
.
materialList
[
index
];
if
(
typeItem
.
id
==
materialTypeId
)
{
return
this
.
$l
(
typeItem
,
"
title
"
);
}
}
};
},
firstImg
()
{
return
(
imgString
)
=>
{
if
(
!
imgString
||
imgString
==
""
)
return
imgString
;
...
...
@@ -844,10 +961,21 @@ export default {
/** 查询列表 */
getList
()
{
this
.
loading
=
true
;
if
(
this
.
titleZhParam
.
value
)
{
this
.
queryParams
[
this
.
titleZhParam
.
key
]
=
this
.
titleZhParam
.
value
;
}
// 处理查询参数
let
params
=
{
...
this
.
queryParams
};
params
.
filter
=
false
;
this
.
addBeginAndEndTime
(
params
,
this
.
dateRangeCreateTime
,
"
createTime
"
);
// this.addBeginAndEndTime(params, this.dateRangeCreateTime, "createTime");
this
.
addBeginAndEndTime
(
params
,
this
.
dateRangeCreateTime
,
"
createTime
"
,
false
);
// 执行查询
params
.
status
=
0
;
getProductPage
(
params
).
then
((
response
)
=>
{
...
...
@@ -891,7 +1019,10 @@ export default {
/** 重置按钮操作 */
resetQuery
()
{
this
.
dateRangeCreateTime
=
[];
this
.
resetForm
(
"
queryForm
"
);
this
.
titleZhParam
.
value
=
""
;
this
.
queryParams
.
materialTypes
=
[];
this
.
handleQuery
();
},
/** 新增按钮操作 */
...
...
@@ -1018,7 +1149,13 @@ export default {
let
params
=
{
...
this
.
queryParams
};
params
.
pageNo
=
undefined
;
params
.
pageSize
=
undefined
;
this
.
addBeginAndEndTime
(
params
,
this
.
dateRangeCreateTime
,
"
createTime
"
);
//this.addBeginAndEndTime(params, this.dateRangeCreateTime, "createTime");
this
.
addBeginAndEndTime
(
params
,
this
.
dateRangeCreateTime
,
"
createTime
"
,
false
);
// 执行导出
this
.
$modal
.
confirm
(
this
.
$t
(
"
是否确认导出所有商品数据项?
"
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment