Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录
切换导航
S
shop-new
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
王天霸
shop-new
Commits
bb11853a
提交
bb11853a
authored
6月 10, 2021
作者:
huaxinzhu
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
详情
上级
282c70aa
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
383 行增加
和
28 行删除
+383
-28
order.js
src/api/module/order.js
+18
-0
goodsinfomation.vue
src/views/system/goods/add/components/goodsinfomation.vue
+107
-9
index.vue
src/views/system/goods/offsale/index.vue
+1
-2
index.vue
src/views/system/order/index.vue
+257
-17
没有找到文件。
src/api/module/order.js
浏览文件 @
bb11853a
...
...
@@ -69,3 +69,21 @@ export function delOrder(ids) {
data
:{
ids
:
ids
}
})
}
// 订单导出
export
function
exportOrder
(
query
)
{
return
request
({
url
:
'/system/order/batchDeliveryGoodsOut'
,
method
:
'get'
,
params
:
query
})
}
// 批量发货
export
function
deliveryOrder
(
data
)
{
return
request
({
url
:
'/system/order/batchDeliveryGoods'
,
method
:
'post'
,
data
:
data
})
}
src/views/system/goods/add/components/goodsinfomation.vue
浏览文件 @
bb11853a
...
...
@@ -127,8 +127,17 @@
<el-checkbox
v-for=
"item in tags"
:label=
"item.id"
true-label
:key=
"item.id"
:disabled=
"item.isdc"
@
change=
"serviceSingleChange(item.id)"
>
{{
item
.
tag
}}
</el-checkbox>
</el-checkbox-group>
</el-form-item>
<el-form-item
label=
"详情描述"
style=
"height:580px; margin-bottom: 0;"
prop=
"description"
>
<quill-editor
ref=
"myTextEditor"
v-model=
"content"
:options=
"editorOption"
@
change=
"onEditorChange"
style=
"height:500px;"
></quill-editor>
<el-form-item
label=
"详情描述"
style=
"height:550px;"
prop=
"description"
v-loading=
"quillUpdateImg"
>
<el-upload
class=
"avatar-uploader2"
action=
"#"
:http-request=
"uploadSectionFile"
name=
"file"
:show-file-list=
"false"
:file-list=
"ruleFormdialogImageUrl"
:before-upload=
"beforeUploadEdit"
>
</el-upload>
<quill-editor
ref=
"myTextEditor"
v-model=
"content"
:options=
"editorOption"
@
change=
"onEditorChange"
style=
"height:500px;margin-top:-30px;"
></quill-editor>
</el-form-item>
<el-form-item
style=
"margin-bottom: 0;"
>
<el-button
@
click=
"resetGoodsInfForm('ruleForm')"
>
重 置
</el-button>
...
...
@@ -138,12 +147,29 @@
</
template
>
<
script
>
// 工具栏配置
const
toolbarOptions
=
[
[
'bold'
,
'italic'
,
'underline'
,
'strike'
],
// toggled buttons
[
'blockquote'
,
'code-block'
],
[{
'header'
:
1
},
{
'header'
:
2
}],
// custom button values
[{
'list'
:
'ordered'
},
{
'list'
:
'bullet'
}],
[{
'script'
:
'sub'
},
{
'script'
:
'super'
}],
// superscript/subscript
[{
'indent'
:
'-1'
},
{
'indent'
:
'+1'
}],
// outdent/indent
[{
'direction'
:
'rtl'
}],
// text direction
// [{'size': ['small', false, 'large', 'huge']}], // custom dropdown
// [{'header': [1, 2, 3, 4, 5, 6, false]}],
// [{'color': []}, {'background': []}], // dropdown with defaults from theme
// [{'font': []}],
// [{'align': []}],
[
'image'
,
'video'
],
[
'clean'
]
// remove formatting button
]
import
{
GetCategory
,
GetFreight
GetFreight
,
UploadImg
}
from
'@/api/module/goods'
import
{
getBrandsInf
}
from
'@/api/module/brand/brand'
export
default
{
name
:
'goods'
,
props
:
{
...
...
@@ -173,9 +199,9 @@
value
:
'id'
,
},
content
:
''
,
editorOption
:
{
placeholder
:
'编辑内容'
},
//
editorOption: {
//
placeholder: '编辑内容'
//
},
brandOtions
:
[],
serviceagsTags
:
[],
ruleForm
:
{
...
...
@@ -220,7 +246,29 @@
},
// 运费模板列表
freightList
:
[],
options1
:
[]
options1
:
[],
/*8888888888888*/
editorOption
:
{
placeholder
:
''
,
theme
:
'snow'
,
// or 'bubble'
modules
:
{
toolbar
:
{
container
:
toolbarOptions
,
// 工具栏
handlers
:
{
'image'
:
function
(
value
)
{
if
(
value
)
{
// 触发input框选择图片文件
document
.
querySelector
(
'.avatar-uploader2 input'
).
click
()
}
else
{
this
.
quill
.
format
(
'image'
,
false
);
}
}
}
}
}
},
quillUpdateImg
:
false
,
ruleFormdialogImageUrl
:[]
}
},
components
:
{},
...
...
@@ -246,7 +294,7 @@
deep
:
true
},
infomationdatas
(
curVal
,
oldVal
)
{
//
console.log("商品信息子组件:",curVal);
console
.
log
(
"商品信息子组件:"
,
curVal
);
if
(
curVal
)
{
this
.
ruleForm
=
curVal
;
if
(
curVal
.
freightId
==
0
)
{
...
...
@@ -277,6 +325,56 @@
this
.
getBrands
();
},
methods
:
{
/*************************/
// 上传图片前
beforeUploadEdit
(
res
,
file
)
{
// 显示loading动画
this
.
quillUpdateImg
=
true
},
// 上传图片成功
uploadSectionFile
(
param
)
{
this
.
quillUpdateImg
=
true
;
this
.
getBase64
(
param
.
file
).
then
((
res
)
=>
{
let
result
=
res
.
split
(
","
);
this
.
Base64img
=
result
[
1
];
let
data
=
{
"image"
:
this
.
Base64img
}
UploadImg
(
data
).
then
(
res
=>
{
if
(
res
&&
res
.
data
.
code
==
1
)
{
this
.
ruleFormdialogImageUrl
.
push
({
'url'
:
res
.
data
.
data
.
imageUrl
});
this
.
$message
({
message
:
'上传成功'
,
type
:
'success'
});
// 获取富文本组件实例
let
quill
=
this
.
$refs
.
myTextEditor
.
quill
;
let
length
=
quill
.
getSelection
().
index
;
// 插入图片 res.data.url为服务器返回的图片地址
quill
.
insertEmbed
(
length
,
'image'
,
res
.
data
.
data
.
imageUrl
)
// 调整光标到最后
quill
.
setSelection
(
length
+
1
)
}
else
{
this
.
$message
({
message
:
'上传失败,请重新上传'
,
type
:
'error'
});
}
this
.
quillUpdateImg
=
false
;
})
});
/*-----*/
},
// 图片转换为 base64
getBase64
(
file
)
{
return
new
Promise
(
function
(
resolve
,
reject
)
{
let
reader
=
new
FileReader
();
let
imgResult
=
""
;
reader
.
readAsDataURL
(
file
);
reader
.
onload
=
function
()
{
imgResult
=
reader
.
result
;
};
reader
.
onerror
=
function
(
error
)
{
reject
(
error
);
};
reader
.
onloadend
=
function
()
{
resolve
(
imgResult
);
};
});
},
/*************************/
// 服务标签 中,7天退换和不可退换只能2选一
serviceSingleChange
(
id
)
{
let
index4
=
this
.
serviceagsTags
.
indexOf
(
4
);
...
...
src/views/system/goods/offsale/index.vue
浏览文件 @
bb11853a
...
...
@@ -71,14 +71,13 @@
<el-button
size=
"mini"
type=
"text"
icon=
"el-icon-edit"
@
click=
"handleUpdate(scope.row)"
>
编辑
</el-button>
<el-divider
direction=
"vertical"
></el-divider>
<el-button
size=
"mini"
type=
"text"
icon=
"el-icon-delete"
@
click=
"handleDelete(scope.row)"
>
删除
</el-button>
...
...
src/views/system/order/index.vue
浏览文件 @
bb11853a
差异被折叠。
点击展开。
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论