优化落地页兑换码/白名单/优惠券目录结构,抽离公用组件

This commit is contained in:
Apple 2022-09-21 14:18:31 +08:00
parent 49b2d3f6ad
commit e732ba67c9
29 changed files with 68 additions and 84 deletions

View File

@ -2,7 +2,7 @@ import React from 'react';
import { ImageUpload, ColorPicker, Notify, RadioGroup, RadioButton, Tooltip, Icon } from 'zent'; import { ImageUpload, ColorPicker, Notify, RadioGroup, RadioButton, Tooltip, Icon } from 'zent';
import "@/assets/comm.css" import "@/assets/comm.css"
import Form from "@/components/form/main" import Form from "@/components/form/main"
import CouponWangeditor from '@/pages/exchangepage/edittemplate/couponwangeditor.js' import CouponWangeditor from './couponwangeditor.js'
import FormItem from "@/components/form-item/main" import FormItem from "@/components/form-item/main"
import _ from "lodash"; import _ from "lodash";
import { uploadImg, handelResponse, addTheme, putMyTheme, putTheme, putSystemTemplate, addSystemTemplate } from "@/assets/api.js" import { uploadImg, handelResponse, addTheme, putMyTheme, putTheme, putSystemTemplate, addSystemTemplate } from "@/assets/api.js"

View File

@ -2,7 +2,7 @@ import { handelResponse, uploadImg } from "@/assets/api.js";
import "@/assets/comm.css"; import "@/assets/comm.css";
import FormItem from "@/components/form-item/main"; import FormItem from "@/components/form-item/main";
import Form from "@/components/form/main"; import Form from "@/components/form/main";
import CouponWangeditor from '@/pages/exchangepage/edittemplate/couponwangeditor.js'; import CouponWangeditor from '../../couponwangeditor';
import React from 'react'; import React from 'react';
import { ColorPicker, Icon, ImageUpload, Notify, RadioButton, RadioGroup, Tooltip } from 'zent'; import { ColorPicker, Icon, ImageUpload, Notify, RadioButton, RadioGroup, Tooltip } from 'zent';
import Backpicture from './backPicture.js'; import Backpicture from './backPicture.js';

View File

@ -28,8 +28,7 @@ export default class Searchbar extends React.Component {
}) })
let config = JSON.parse(sessionStorage.getItem('editorConfig')); let config = JSON.parse(sessionStorage.getItem('editorConfig'));
if (config && config.coupon && config.coupon.product_list) { if (config && config.coupon && config.coupon.product_list) {
let { shape, textAlign, borderColor, placeholder } = config.coupon.product_list.search; this.setState({...config.coupon.product_list.search});
this.setState({ shape, textAlign, borderColor, placeholder });
} }
} }
//形状 //形状

View File

@ -2,10 +2,10 @@ import { handelResponse, uploadImg } from "@/assets/api.js";
import FormItem from "@/components/form-item/main"; import FormItem from "@/components/form-item/main";
import Form from "@/components/form/main"; import Form from "@/components/form/main";
import Ipt from "@/components/input/main"; import Ipt from "@/components/input/main";
import CouponWangeditor from '@/pages/exchangepage/edittemplate/couponwangeditor.js'; import CouponWangeditor from './couponwangeditor.js';
import React from 'react'; import React from 'react';
import { ColorPicker, ImageUpload, Notify, RadioButton, RadioGroup } from 'zent'; import { ColorPicker, ImageUpload, Notify, RadioButton, RadioGroup } from 'zent';
import "../../../edittemplate/goodstemplate.less"; import "../goodstemplate.less";
export default class couponLandpage extends React.Component { export default class couponLandpage extends React.Component {
constructor(props) { constructor(props) {
super(props) super(props)

View File

@ -1,11 +1,11 @@
import React from 'react'; import React from 'react';
import { ImageUpload, ColorPicker, Notify, RadioGroup, RadioButton, Tooltip, Icon } from 'zent'; import { ImageUpload, ColorPicker, Notify, RadioGroup, RadioButton, Tooltip, Icon } from 'zent';
import "./main.less" import "../main.less"
import "../../../assets/comm.css" import "@/assets/comm.css"
import Form from "../../../components/form/main" import Form from "@/components/form/main"
import Wangeditor from './wangeditorCom.js' import Wangeditor from './wangeditorCom.js'
import FormItem from "../../../components/form-item/main" import FormItem from "@/components/form-item/main"
import { uploadImg, handelResponse, addTheme, putMyTheme, putTheme, putSystemTemplate, addSystemTemplate } from "../../../assets/api.js" import { uploadImg, handelResponse} from "@/assets/api.js"
export default class edittemplate extends React.Component { export default class edittemplate extends React.Component {
constructor(props) { constructor(props) {
super(props) super(props)

View File

@ -1,7 +1,7 @@
import React from 'react'; import React from 'react';
import "./main.less" import "../main.less"
import "../../../assets/comm.css" import "@/assets/comm.css"
import './goodstemplate.less' import '../goodstemplate.less'
export default class edittemplate extends React.Component{ export default class edittemplate extends React.Component{
constructor(props){ constructor(props){
super(props) super(props)

View File

@ -1,10 +1,10 @@
import React from 'react'; import React from 'react';
import { ColorPicker, ImageUpload, Tooltip, Notify, RadioGroup, RadioButton, Icon } from 'zent'; import { ColorPicker, ImageUpload, Tooltip, Notify, RadioGroup, RadioButton, Icon } from 'zent';
import "./main.less" import "../main.less"
import "../../../assets/comm.css" import "@/assets/comm.css"
import Form from "../../../components/form/main" import Form from "@/components/form/main"
import FormItem from "../../../components/form-item/main" import FormItem from "@/components/form-item/main"
import { uploadImg, handelResponse } from "../../../assets/api.js" import { uploadImg, handelResponse } from "@/assets/api.js"
import Wangeditor from './wangeditorCom.js' import Wangeditor from './wangeditorCom.js'
export default class edittemplate extends React.Component { export default class edittemplate extends React.Component {
constructor(props) { constructor(props) {

View File

@ -1,13 +1,13 @@
import React from 'react'; import React from 'react';
import { Button, Select, ImageUpload, ColorPicker, NumberInput } from 'zent'; import { Button, Select, ImageUpload, ColorPicker, NumberInput } from 'zent';
import "./main.less" import "../main.less"
import "../../../assets/comm.css" import "@/assets/comm.css"
import "./goodstemplate.less" import "../goodstemplate.less"
import { Notify, RadioGroup, RadioButton } from 'zent'; import { Notify, RadioGroup, RadioButton } from 'zent';
import Ipt from "../../../components/input/main" import Ipt from "@/components/input/main"
import Form from "../../../components/form/main" import Form from "@/components/form/main"
import FormItem from "../../../components/form-item/main" import FormItem from "@/components/form-item/main"
import { uploadImg, handelResponse, getThemeType } from "../../../assets/api.js" import { uploadImg, handelResponse, getThemeType } from "@/assets/api.js"
import Wangeditor from './wangeditorCom.js' import Wangeditor from './wangeditorCom.js'
export default class edittemplate extends React.Component { export default class edittemplate extends React.Component {
constructor(props) { constructor(props) {

View File

@ -6,9 +6,9 @@ import "../../../assets/comm.css"
import './goodstemplate.less' import './goodstemplate.less'
import SearchBarView from './couponConfig/searchBar' //商品详情搜索栏 import SearchBarView from './couponCard/couponConfig/searchBar' //商品详情搜索栏
import BottomBarView from './couponConfig/bottomBar' //底部栏 import BottomBarView from './couponCard/couponConfig/bottomBar' //底部栏
import {Sweetalert} from 'zent' import {Sweetalert} from 'zent'

View File

@ -1,29 +1,29 @@
import React from 'react'
import './main.less'
import '../../../assets/comm.css'
import {Notify,BlockLoading,Button,RadioGroup,RadioButton} from 'zent'
import {uploadImg,handelResponse,addTheme,putMyTheme, putTheme,putSystemTemplate,addSystemTemplate} from '../../../assets/api.js'
import Bus from '@/assets/eventBus.js' import Bus from '@/assets/eventBus.js'
import PreviewEffect from '../previewEffect/main'
import html2canvas from 'html2canvas' import html2canvas from 'html2canvas'
import Goodstemplate from './goodstemplate'
import Detailstemplate from './detailstemplate'
import Descteplate from './goodsdesc'
import LandingForm from './landingPage' //落地页表单
import GoodsForm from './goodsPage' //商品页表单
import DetailsPage from './detailsPage' //商品详情form页面
import WhiteLand from './whiteLand' //白名单落地页
import Whitegoods from './whitegoods' //白名单商品页面
import Whitedetails from './whitedetails' //白名单详情页
import Reduce from './reduce' //商品详情页立减金
import ReduceConfig from './reduceConfig' //商品详情立减金页面
// 优惠券
import CouponLandingForm from '../couponTemplate/landingPage/config/main' //优惠券落地页表单
import CouponGoodsListForm from '../couponTemplate/goodsPage/config/main' //优惠券商品列表页
import CouponGoodsDetailForm from './couponconfig' //优惠券商品详情页
import CouponReduceDetailForm from './couponReduceDetail' //优惠券立减金详情页
import CouponComLib from '../couponTemplate/goodsPage/componentLib/main' //优惠券组件库
import _ from 'lodash' import _ from 'lodash'
import React from 'react'
import { BlockLoading, Button, Notify, RadioButton, RadioGroup } from 'zent'
import { addSystemTemplate, addTheme, handelResponse, putMyTheme, putSystemTemplate, putTheme, uploadImg } from '../../../assets/api.js'
import '../../../assets/comm.css'
import PreviewEffect from '../previewEffect/main'
import CouponGoodsDetailForm from './couponCard/couponconfig'; //优惠券商品详情页
import CouponReduceDetailForm from './couponCard/couponReduceDetail'; //优惠券立减金详情页
// 优惠券
import CouponLandingForm from './couponCard/landPage'; //优惠券落地页表单
import CouponComLib from './couponCard/goodsPage/componentLib/main'; //优惠券组件库
import CouponGoodsListForm from './couponCard/goodsPage/config/main'; //优惠券商品列表页
import DetailsPage from './exchange/detailsPage'; //商品详情form页面
import Detailstemplate from './exchange/detailstemplate'
import Descteplate from './goodsdesc'
import GoodsForm from './exchange/goodsPage'; //商品页表单
import Goodstemplate from './goodstemplate'
import LandingForm from './exchange/landingPage'; //落地页表单
import './main.less'
import Reduce from './reduce'; //商品详情页立减金
import ReduceConfig from './reduceConfig'; //商品详情立减金页面
import Whitedetails from './whiteList/whitedetails'; //白名单详情页
import Whitegoods from './whiteList/whitegoods'; //白名单商品页面
import WhiteLand from './whiteList/whiteLand'; //白名单落地页
//落地页 //落地页
let model = { let model = {
title: '落地页标题', title: '落地页标题',

View File

@ -18,7 +18,7 @@ export default class edittemplate extends React.Component{
<img src={'https://lsxdemall.oss-cn-beijing.aliyuncs.com/MarketingSystem/img/backprepageBtn.png'} className="preBtn"/> <img src={'https://lsxdemall.oss-cn-beijing.aliyuncs.com/MarketingSystem/img/backprepageBtn.png'} className="preBtn"/>
<img src="https://lsxdemall.oss-cn-beijing.aliyuncs.com/MarketingSystem/img/coupon/reduce_pic.png" alt="" className="reduce-pic"/> <img src="https://lsxdemall.oss-cn-beijing.aliyuncs.com/MarketingSystem/img/coupon/reduce_pic.png" alt="" className="reduce-pic"/>
{ {
[2,4].includes(this.props.templateType)? [4,8].includes(this.props.templateType)?
<div className="dflexaj payBtn-view"> <div className="dflexaj payBtn-view">
<div className="coupon-price"> <div className="coupon-price">
<p>0.00</p> <p>0.00</p>

View File

@ -2,8 +2,6 @@ import React from 'react';
import { ColorPicker} from 'zent'; import { ColorPicker} from 'zent';
import "./main.less" import "./main.less"
import "../../../assets/comm.css" import "../../../assets/comm.css"
import Form from "../../../components/form/main"
import FormItem from "../../../components/form-item/main"
export default class edittemplate extends React.Component { export default class edittemplate extends React.Component {
constructor(props) { constructor(props) {
super(props) super(props)
@ -36,19 +34,6 @@ export default class edittemplate extends React.Component {
return ( return (
<div style={{ width: "92%", "margin": "0 auto", "overflow": "auto", "maxHeight": "100%" }}> <div style={{ width: "92%", "margin": "0 auto", "overflow": "auto", "maxHeight": "100%" }}>
<p style={{textAlign:'center'}}>暂未开放</p> <p style={{textAlign:'center'}}>暂未开放</p>
{/* <Form model={this.state.model} ref="form1">
<div style={{ fontWeight: 'bold', marginBottom: '20px' }}>样式</div>
<FormItem labelname="字体颜色:" prop="button_color" id="button_color" labelwidth="80px">
<div className="colorItembg dfleac" >
<ColorPicker disabled className="setbgColor" color={this.state.model.font_color} onChange={this.handleChange} />
</div>
</FormItem>
<FormItem labelname="背景颜色:" prop="font_color" id="font_color" labelwidth="80px">
<div className="colorItemfont dfleac">
<ColorPicker className="setbgColor" color={this.state.model.button_color} onChange={this.handleChange1} disabled />
</div>
</FormItem>
</Form> */}
</div> </div>
) )
} }

View File

@ -1,12 +1,12 @@
import React from 'react'; import React from 'react';
import { ImageUpload, ColorPicker, Notify, RadioGroup, RadioButton } from 'zent'; import { ImageUpload, ColorPicker, Notify, RadioGroup, RadioButton } from 'zent';
import "./main.less" import "../main.less"
import "../../../assets/comm.css" import "@/assets/comm.css"
import "./goodstemplate.less" import "../goodstemplate.less"
import Ipt from "../../../components/input/main" import Ipt from "@/components/input/main"
import Form from "../../../components/form/main" import Form from "@/components/form/main"
import FormItem from "../../../components/form-item/main" import FormItem from "@/components/form-item/main"
import { uploadImg, handelResponse, getThemeType } from "../../../assets/api.js" import { uploadImg, handelResponse, getThemeType } from "@/assets/api.js"
import Wangeditor from './whitewangeditor.js' import Wangeditor from './whitewangeditor.js'
export default class edittemplate extends React.Component { export default class edittemplate extends React.Component {
constructor(props) { constructor(props) {

View File

@ -1,11 +1,11 @@
import React from 'react'; import React from 'react';
import {ImageUpload, ColorPicker, Notify, RadioGroup, RadioButton, Tooltip, Icon } from 'zent'; import {ImageUpload, ColorPicker, Notify, RadioGroup, RadioButton, Tooltip, Icon } from 'zent';
import "./main.less" import "../main.less"
import "../../../assets/comm.css" import "@/assets/comm.css"
import Form from "../../../components/form/main" import Form from "@/components/form/main"
import Wangeditor from './whitewangeditor.js' import Wangeditor from './whitewangeditor.js'
import FormItem from "../../../components/form-item/main" import FormItem from "@/components/form-item/main"
import { uploadImg, handelResponse, addTheme, putMyTheme, putTheme, putSystemTemplate, addSystemTemplate } from "../../../assets/api.js" import { uploadImg, handelResponse} from "@/assets/api.js"
export default class edittemplate extends React.Component { export default class edittemplate extends React.Component {
constructor(props) { constructor(props) {
super(props) super(props)

View File

@ -1,10 +1,10 @@
import React from 'react'; import React from 'react';
import { ColorPicker,ImageUpload,Tooltip,Notify ,RadioGroup,RadioButton,Icon} from 'zent'; import { ColorPicker,ImageUpload,Tooltip,Notify ,RadioGroup,RadioButton,Icon} from 'zent';
import "./main.less" import "../main.less"
import "../../../assets/comm.css" import "@/assets/comm.css"
import Form from "../../../components/form/main" import Form from "@/components/form/main"
import FormItem from "../../../components/form-item/main" import FormItem from "@/components/form-item/main"
import {uploadImg,handelResponse} from "../../../assets/api.js" import {uploadImg,handelResponse} from "@/assets/api.js"
import Wangeditor from './whitewangeditor.js' import Wangeditor from './whitewangeditor.js'
export default class edittemplate extends React.Component{ export default class edittemplate extends React.Component{
constructor(props){ constructor(props){