Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
lumastoreapp
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xieyishang
lumastoreapp
Commits
1cb7f09e
Commit
1cb7f09e
authored
Jun 11, 2020
by
石家欣
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sjx
parent
364d6703
Changes
7
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
254 additions
and
148 deletions
+254
-148
manifest.json
manifest.json
+3
-3
pages.json
pages.json
+1
-1
pages/CardSend/CardSend.vue
pages/CardSend/CardSend.vue
+1
-1
pages/edit/product/addshop.vue
pages/edit/product/addshop.vue
+10
-9
pages/edit/shop/shop.vue
pages/edit/shop/shop.vue
+162
-131
pages/setup/setup.vue
pages/setup/setup.vue
+3
-3
utils/richText.js
utils/richText.js
+74
-0
No files found.
manifest.json
View file @
1cb7f09e
...
...
@@ -3,8 +3,8 @@
//
"appid"
:
"__UNI__FC9419E"
,
"appid"
:
"__UNI__1EA80F1"
,
//这个是
web
的
"description"
:
""
,
"versionName"
:
"1.0.
57
"
,
"versionCode"
:
1
57
,
"versionName"
:
"1.0.
60
"
,
"versionCode"
:
1
60
,
"transformPx"
:
false
,
/*
5
+App特有相关
*/
"app-plus"
:
{
...
...
@@ -148,7 +148,7 @@
}
}
},
"compilerVersion"
:
3
"compilerVersion"
:
2
},
/*
快应用特有相关
*/
"quickapp"
:
{},
...
...
pages.json
View file @
1cb7f09e
...
...
@@ -53,7 +53,7 @@
,{
"path"
:
"pages/edit/shop/shop"
,
"style"
:
{
"navigationBarTitleText"
:
"商家信息
编辑
"
"navigationBarTitleText"
:
"商家信息"
}
}
...
...
pages/CardSend/CardSend.vue
View file @
1cb7f09e
...
...
@@ -41,7 +41,7 @@
<view
class=
"inputitem flex"
>
<view
class=
"names"
>
发放数量
</view>
<input
type=
"number"
placeholder=
"请填写
满多少元可以使用
"
v-model=
"parameter.count"
class=
"inputs"
placeholder-class=
"plclass"
>
<input
type=
"number"
placeholder=
"请填写
发放的数量
"
v-model=
"parameter.count"
class=
"inputs"
placeholder-class=
"plclass"
>
</view>
</view>
<!-- 第一块结束 -->
...
...
pages/edit/product/addshop.vue
View file @
1cb7f09e
...
...
@@ -286,7 +286,7 @@
// console.info(this.goodsCate[i].children[j],"111111");
let
itemtwo
=
this
.
goodsCate
[
i
].
children
[
j
];
if
(
itemtwo
.
cate_id
==
this
.
canform
.
cate_id
){
console
.
info
(
"
111这个才是
"
,
itemtwo
);
//
console.info("111这个才是",itemtwo);
this
.
datachind
=
itemone
;
//二级赋值
this
.
cate_name
=
this
.
goodsCate
[
i
].
value
;
//一级名称
...
...
@@ -375,12 +375,12 @@
},
//富文本处理完毕 事件 获取最后的html 数据 子组件调用的
editOk
(
e
){
//2.xxxx
console
.
info
(
"
col
"
,
e
.
html
);
//
console.info("col",e.html);
//调用完毕 调用 create_goods
let
htaltag
=
e
.
html
let
newStr
=
htaltag
.
replace
(
new
RegExp
(
/
\"
/g
),
""
);
console
.
log
(
newStr
);
//
console.log(newStr);
this
.
canform
.
details
=
newStr
;
//e.html
this
.
create_goods
();
...
...
@@ -419,15 +419,16 @@
})
console
.
info
(
this
.
canform
,
"
canform
"
);
//
console.info(this.canform,"canform");
// return false;
//添加
if
(
this
.
canform
.
price
<
this
.
canform
.
mall_price
){
console
.
log
(
this
.
canform
.
mall_price
)
console
.
log
(
this
.
canform
.
price
)
if
(
parseFloat
(
this
.
canform
.
price
)
<
parseFloat
(
this
.
canform
.
mall_price
)){
this
.
$api
.
msg
(
'
商城价格不能大于市场价格
'
);
this
.
issubmit
=
true
;
return
;
}
let
res
=
await
addEditGoods
(
this
.
canform
)
...
...
@@ -457,12 +458,12 @@
},
//多选 勾选 列表
checkboxChange
(
e
){
console
.
log
(
e
);
//
console.log(e);
this
.
selchildList
=
e
.
detail
.
value
;
},
// 改变下拉选项 一级的
bindPickerChange
(
event
)
{
console
.
info
(
event
.
detail
.
value
);
//
console.info(event.detail.value);
this
.
parent_name
=
""
;
this
.
canform
.
cate_id
=
""
;
this
.
cate_name
=
this
.
goodsCate
[
event
.
detail
.
value
].
value
;
...
...
@@ -471,7 +472,7 @@
},
//二级分类选中后处理
bindPickerss
(
event
)
{
console
.
log
(
event
.
detail
.
value
);
//
console.log(event.detail.value);
this
.
parent_name
=
this
.
datachind
[
event
.
detail
.
value
].
value
;
this
.
canform
.
cate_id
=
this
.
datachind
[
event
.
detail
.
value
].
cate_id
;
//分类id
},
...
...
pages/edit/shop/shop.vue
View file @
1cb7f09e
This diff is collapsed.
Click to expand it.
pages/setup/setup.vue
View file @
1cb7f09e
...
...
@@ -4,7 +4,7 @@
<view
class=
"container"
>
<navigator
url=
"/pages/edit/shop/shop"
class=
"list-cell b-b m-t"
hover-class=
"cell-hover"
:hover-stay-time=
"50"
>
<text
class=
"cell-tit"
>
门店
编辑
</text>
<text
class=
"cell-tit"
>
门店
信息
</text>
<image
class=
"jiantousi"
src=
"/static/news/jiantousi.png"
mode=
""
></image>
</navigator>
<navigator
url=
"/pages/edit/Qualifications/Qualifications"
class=
"list-cell b-b"
hover-class=
"cell-hover"
:hover-stay-time=
"50"
>
...
...
@@ -37,10 +37,10 @@
<text
class=
"cell-tit"
>
切换门店
</text>
<image
class=
"jiantousi"
src=
"/static/news/jiantousi.png"
mode=
""
></image>
</navigator>
<view
class=
"list-cell b-b"
@
tap=
"oneTodeleteStore"
hover-class=
"cell-hover"
>
<
!--
<
view
class=
"list-cell b-b"
@
tap=
"oneTodeleteStore"
hover-class=
"cell-hover"
>
<text
class=
"cell-tit"
>
关闭店铺
</text>
<image
class=
"jiantousi"
src=
"/static/news/jiantousi.png"
mode=
""
></image>
</view>
</view>
-->
<navigator
url=
"/pages/setPassword/setPassword?is_pay=0"
class=
"list-cell b-b"
hover-class=
"cell-hover"
:hover-stay-time=
"50"
>
<text
class=
"cell-tit"
>
修改登录密码
</text>
<image
class=
"jiantousi"
src=
"/static/news/jiantousi.png"
mode=
""
></image>
...
...
utils/richText.js
0 → 100644
View file @
1cb7f09e
/*
graceUI rich-text 加强工具
link : graceui.hcoder.net
author : 5213606@qq.com 深海
*/
// 正则变量
var
graceRichTextReg
;
// 批量替换的样式 [ 根据项目需求自行设置 ]
var
GRT
=
[
// div 样式
[
'
div
'
,
"
line-height:2em;
"
],
// h1 样式
[
'
h1
'
,
"
font-size:3em; line-height:1.5em;
"
],
// h2 样式
[
'
h2
'
,
"
font-size:2em; line-height:1.8em;
"
],
// h3 样式
[
'
h3
'
,
"
font-size:1.6em; line-height:2em;
"
],
// h4 样式
[
'
h4
'
,
"
font-size:1.2em; line-height:2em;
"
],
// h5 样式
[
'
h5
'
,
"
font-size:1em; line-height:2em;
"
],
// h6 样式
[
'
h6
'
,
"
font-size:0.9em; line-height:2em;
"
],
// p 样式
[
'
p
'
,
"
font-size:1em; line-height:2em;
"
],
// b 样式
[
'
b
'
,
"
font-size:1em; line-height:2em;
"
],
// strong 样式
[
'
strong
'
,
"
font-size:1em; line-height:2em;
"
],
// code 样式
[
'
code
'
,
"
font-size:1em; line-height:1.2em; background:#F6F7F8; padding:8px 2%; width:96%;
"
],
// img 样式
[
'
img
'
,
"
width:100%; margin:8px 0;
"
],
// blockquote
[
'
blockquote
'
,
"
font-size:1em; border-left:3px solid #D1D1D1; line-height:2em; border-radius:5px; background:#F6F7F8; padding:8px 2%;
"
],
// li 样式
[
'
ul
'
,
"
padding:5px 0; list-style:none; padding:0; margin:0;
"
],
[
'
li
'
,
"
line-height:1.5em; padding:5px 0; list-style:none; padding:0; margin:0; margin-top:10px;
"
],
// table
[
'
table
'
,
"
width:100%; border-left:1px solid #F2F3F4; border-top:1px solid #F2F3F4;
"
],
[
'
th
'
,
"
border-right:1px solid #F2F3F4; border-bottom:1px solid #F2F3F4;
"
],
[
'
td
'
,
"
border-right:1px solid #F2F3F4; border-bottom:1px solid #F2F3F4; padding-left:5px;
"
]
];
module
.
exports
=
{
format
:
function
(
html
){
html
=
html
.
replace
(
/<pre.*pre>
?
/gi
s
,
function
(
word
){
word
=
word
.
replace
(
/
[\n]
/gi
,
'
<br />
'
);
word
=
word
.
replace
(
/ /gi
,
'
<span style="padding-left:2em;"></span>
'
);
return
word
.
replace
(
/
[\t]
/gi
,
'
<span style="padding-left:2em;"></span>
'
);
});
html
=
html
.
replace
(
/<pre/gi
,
'
<p style="font-size:1em; margin:12px 0; line-height:1.2em; background:#F6F7F8; border-radius:5px; padding:8px 4%; width:92%;"
'
);
html
=
html
.
replace
(
/<
\/
pre/gi
,
"
</p
"
);
for
(
let
i
=
0
;
i
<
GRT
.
length
;
i
++
){
graceRichTextReg
=
new
RegExp
(
'
<
'
+
GRT
[
i
][
0
]
+
'
>|<
'
+
GRT
[
i
][
0
]
+
'
(.*?)>
'
,
'
gi
'
);
html
=
html
.
replace
(
graceRichTextReg
,
function
(
word
){
// 分析 dom 上是否带有 style=""
if
(
word
.
indexOf
(
'
style=
'
)
!=
-
1
){
var
regIn
=
new
RegExp
(
'
<
'
+
GRT
[
i
][
0
]
+
'
(.*?)style="(.*?)"(.*?)(/?)>
'
,
'
gi
'
);
return
word
.
replace
(
regIn
,
'
<
'
+
GRT
[
i
][
0
]
+
'
$1style="$2
'
+
GRT
[
i
][
1
]
+
'
"$3$4>
'
);
}
else
{
var
regIn
=
new
RegExp
(
'
<
'
+
GRT
[
i
][
0
]
+
'
(.*?)(/?)>
'
,
'
gi
'
);
return
word
.
replace
(
regIn
,
'
<
'
+
GRT
[
i
][
0
]
+
'
$1 style="
'
+
GRT
[
i
][
1
]
+
'
$2">
'
);
}
});
}
return
html
;
}
}
\ No newline at end of file
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