🎈 perf(客服咨询完成):
This commit is contained in:
parent
9e6cf1738f
commit
12e70ce8ae
@ -1,4 +1,4 @@
|
||||
// export const BASE_URL = CURRENT_BASE_URL
|
||||
export const BASE_URL = CURRENT_BASE_URL
|
||||
// export const BASE_URL = `http://192.168.0.75:50001/lymarket`
|
||||
// export const BASE_URL = `http://192.168.0.89:50001/lymarket`
|
||||
// export const BASE_URL = `http://10.0.0.5:50001/lymarket`
|
||||
@ -12,7 +12,7 @@
|
||||
// export const BASE_URL = `https://dev.zzfzyc.com/lymarket` // 开发环境
|
||||
// export const BASE_URL = `https://www.zzfzyc.com/lymarket` // 正式环境
|
||||
// export const BASE_URL = `http://192.168.1.5:40001/lymarket` // 王霞
|
||||
export const BASE_URL = `http://192.168.1.7:50002/lymarket` // 添
|
||||
// export const BASE_URL = `http://192.168.1.7:50002/lymarket` // 添
|
||||
// export const BASE_URL = `http://192.168.1.22:50002/lymarket` // 婷
|
||||
// export const BASE_URL = `http://192.168.1.42:50002/lymarket` // 杰
|
||||
|
||||
|
@ -1,28 +1,29 @@
|
||||
.swiper{
|
||||
height: 450px;
|
||||
.swiper {
|
||||
height: 450px;
|
||||
width: 100%;
|
||||
position: relative;
|
||||
.swiper_item {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
position: relative;
|
||||
.swiper_item{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
.image_item {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: block;
|
||||
border-radius: 20px 20px 0 0;
|
||||
}
|
||||
.image_item{
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
image{
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
.page{
|
||||
font-size: $font_size_min;
|
||||
padding: 5px 20px;
|
||||
background-color: rgba(0,0,0,0.3);
|
||||
color: #fff;
|
||||
border-radius: 50px;
|
||||
position: absolute;
|
||||
bottom: 20px;
|
||||
right: 20px;
|
||||
}
|
||||
}
|
||||
}
|
||||
.page {
|
||||
font-size: $font_size_min;
|
||||
padding: 5px 20px;
|
||||
background-color: rgba(0, 0, 0, 0.3);
|
||||
color: #fff;
|
||||
border-radius: 50px;
|
||||
position: absolute;
|
||||
bottom: 20px;
|
||||
right: 20px;
|
||||
}
|
||||
}
|
||||
|
@ -3,11 +3,12 @@
|
||||
background-color: $color_bg_one;
|
||||
padding: 20px 20px 100px 20px;
|
||||
.product_header {
|
||||
padding: 0 20px;
|
||||
padding: 20px 20px 0 20px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
height: 163.57px;
|
||||
background-color: #fff;
|
||||
box-sizing: border-box;
|
||||
border-radius: 20px;
|
||||
.title {
|
||||
flex: 1;
|
||||
.name {
|
||||
@ -30,8 +31,9 @@
|
||||
text-align: center;
|
||||
color: $color_font_three;
|
||||
position: relative;
|
||||
margin-left: 10px;
|
||||
.text {
|
||||
margin-top: 10px;
|
||||
margin-top: 5px;
|
||||
font-size: $font_size_medium;
|
||||
}
|
||||
}
|
||||
@ -45,6 +47,7 @@
|
||||
}
|
||||
.miconfont {
|
||||
font-size: 45px;
|
||||
color: #333333;
|
||||
}
|
||||
.collected {
|
||||
color: #ffc300;
|
||||
@ -57,7 +60,7 @@
|
||||
border-radius: 16px;
|
||||
.title {
|
||||
font-size: $font_size;
|
||||
font-weight: 700;
|
||||
font-weight: 500;
|
||||
color: $color_font_one;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
@ -88,7 +91,10 @@
|
||||
padding: 30px 20px 0;
|
||||
color: $color_font_one;
|
||||
font-size: $font_size_medium;
|
||||
border-radius: 20px;
|
||||
.title {
|
||||
color: rgba(0, 0, 0, 0.8);
|
||||
font-weight: 500;
|
||||
}
|
||||
.list {
|
||||
margin-top: 30px;
|
||||
@ -147,7 +153,10 @@
|
||||
background-color: #fff;
|
||||
padding-bottom: constant(safe-area-inset-bottom);
|
||||
padding-bottom: env(safe-area-inset-bottom);
|
||||
|
||||
.icon_btn {
|
||||
display: flex;
|
||||
padding: 0 20px 0 50px;
|
||||
}
|
||||
.buy_cart {
|
||||
width: 150px;
|
||||
color: $color_font_three;
|
||||
@ -155,9 +164,11 @@
|
||||
position: relative;
|
||||
.text {
|
||||
font-size: $font_size_min;
|
||||
color: #333333;
|
||||
}
|
||||
.miconfont {
|
||||
font-size: 50px;
|
||||
color: #333333;
|
||||
}
|
||||
.product_num {
|
||||
position: absolute;
|
||||
@ -176,11 +187,13 @@
|
||||
}
|
||||
.customer_service {
|
||||
text-align: center;
|
||||
position: relative;
|
||||
.miconfont {
|
||||
font-size: 50px;
|
||||
}
|
||||
.text {
|
||||
font-size: $font_size_min;
|
||||
color: #333333;
|
||||
}
|
||||
}
|
||||
.buy_btn {
|
||||
@ -193,12 +206,15 @@
|
||||
font-size: $font_size;
|
||||
color: #fff;
|
||||
position: relative;
|
||||
.phoneBtn {
|
||||
background-color: rgba(0, 0, 0, 0);
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.wxBtn {
|
||||
// background-color: rgba(0, 0, 0, 0);
|
||||
opacity: 0;
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
}
|
||||
|
@ -92,6 +92,12 @@ export default (props: Params) => {
|
||||
// `
|
||||
const html = ``
|
||||
|
||||
const shareImg = useMemo(() => {
|
||||
let data = productInfo.texture_url ? productInfo.texture_url.toString().split(',') : []
|
||||
let str = data.length > 0 ? data[0] : '/mall/share_img_01.png'
|
||||
return formatImgUrl(str, '!w400')
|
||||
}, [productInfo])
|
||||
|
||||
const { setSortCode, userInfo: userObj } = useUserInfo()
|
||||
//详情页获取分享短码
|
||||
const { ShareDetail } = SHARE_SCENE
|
||||
@ -102,7 +108,7 @@ export default (props: Params) => {
|
||||
type: ShareDetail.value,
|
||||
product_id: parseInt(params.id),
|
||||
})
|
||||
const img = formatImgUrl(productInfo.texture_url || '/mall/share_img_01.png', '!w400')
|
||||
const img = formatImgUrl(shareImg, '!w400')
|
||||
setSortCode({ ...userObj.sort_code, shareShortDetail: { title: productName as string, code: resDetail.md5_key, img: img } })
|
||||
}
|
||||
|
||||
@ -177,20 +183,20 @@ export default (props: Params) => {
|
||||
{productInfo.code && <View className={styles.name}>{productName}</View>}
|
||||
<View className={styles.des}>{productInfo.describe}</View>
|
||||
</View>
|
||||
<View className={styles.share}>
|
||||
<View className={classnames('iconfont icon-fenxiang', styles.miconfont)}></View>
|
||||
<View className={styles.text}>分享</View>
|
||||
<Button open-type='share' className={styles.shareBtn}></Button>
|
||||
</View>
|
||||
<View className={styles.collect} onClick={openCollection}>
|
||||
<View
|
||||
className={classnames(
|
||||
`iconfont ${collectStatus ? 'icon-shoucang-pressed' : 'icon-shoucang'}`,
|
||||
`iconfont ${collectStatus ? 'icon-shoucangchenggong' : 'icon-dianjishoucang'}`,
|
||||
styles.miconfont,
|
||||
collectStatus && styles.collected,
|
||||
)}></View>
|
||||
<View className={styles.text}>收藏</View>
|
||||
</View>
|
||||
<View className={styles.share}>
|
||||
<View className={classnames('iconfont icon-fenxiangshangpin', styles.miconfont)}></View>
|
||||
<View className={styles.text}>分享</View>
|
||||
<Button open-type='share' className={styles.shareBtn}></Button>
|
||||
</View>
|
||||
</View>
|
||||
<View className={styles.des_data}>
|
||||
<View className={styles.title}>商品参数</View>
|
||||
@ -237,10 +243,19 @@ export default (props: Params) => {
|
||||
<RichText nodes={html}></RichText>
|
||||
</View>
|
||||
<View className={styles.product_buy}>
|
||||
<View>
|
||||
<View className={styles.icon_btn}>
|
||||
<View className={styles.customer_service}>
|
||||
<View className={classnames('iconfont icon-kefu', styles.miconfont)}></View>
|
||||
<View className={styles.text}>客服</View>
|
||||
<View className={styles.text}>
|
||||
客服
|
||||
<Button
|
||||
className={styles.wxBtn}
|
||||
openType='contact'
|
||||
sendMessageImg={shareImg}
|
||||
sendMessageTitle={productName}
|
||||
showMessageCard={true}
|
||||
sendMessagePath={`pages/details/index?id=${productInfo.id}`}></Button>
|
||||
</View>
|
||||
</View>
|
||||
<View className={styles.buy_cart} onClick={() => setShowCart(true)}>
|
||||
<View className={classnames('iconfont icon-gouwuche', styles.miconfont)}></View>
|
||||
@ -251,7 +266,7 @@ export default (props: Params) => {
|
||||
|
||||
{(!userInfo.adminUserInfo?.is_authorize_phone && (
|
||||
<View className={styles.buy_btn}>
|
||||
<Button className={styles.phoneBtn} open-type='getPhoneNumber' onGetPhoneNumber={(e) => placeOrder('to_phone', e)}></Button>
|
||||
<Button className={styles.wxBtn} open-type='getPhoneNumber' onGetPhoneNumber={(e) => placeOrder('to_phone', e)}></Button>
|
||||
选购商品
|
||||
</View>
|
||||
)) || (
|
||||
|
@ -341,16 +341,7 @@ const Main = memo(() => {
|
||||
<View className={styles['card-main-list-content-item-right']}>
|
||||
<Text className='iconfont icon-a-moreback'></Text>
|
||||
</View>
|
||||
{item.type === 'customer' && (
|
||||
<Button
|
||||
openType='contact'
|
||||
// sendMessageTitle='有个靓仔要询货:0770# 21S全棉平纹'
|
||||
// showMessageCard={true}
|
||||
// sendMessageImg='https://test.cdn.zzfzyc.com/mall/no_img.png'
|
||||
// sendMessagePath='/pages/details/index?id=21'
|
||||
// onContact={(e) => console.log('ee:::', e)}
|
||||
className={styles.customer}></Button>
|
||||
)}
|
||||
{item.type === 'customer' && <Button openType='contact' className={styles.customer}></Button>}
|
||||
</View>
|
||||
)
|
||||
})}
|
||||
|
@ -1,158 +1,161 @@
|
||||
|
||||
import { alert, goLink, isEmptyObject, retrieval } from "@/common/common";
|
||||
import Popup from "@/components/popup";
|
||||
import { Button, Image, Picker, Text, Textarea, View } from "@tarojs/components"
|
||||
import Taro, { chooseMedia } from "@tarojs/taro";
|
||||
import { realNameUpdateApi, companyTypeApi, portraitUpdateApi } from "@/api/user";
|
||||
import { companyDetailApi, companyUpdateApi } from "@/api/company"
|
||||
import { memo, useCallback, useEffect, useMemo, useRef, useState } from "react"
|
||||
import "./index.scss"
|
||||
import ModifyModal from "./components/ModifyModal";
|
||||
import useLogin from "@/use/useLogin";
|
||||
import { useSelector } from "@/reducers/hooks";
|
||||
import useUploadCDNImg from "@/use/useUploadImage";
|
||||
import { IMG_CND_Prefix } from "@/common/constant";
|
||||
import useUserInfo from "@/use/useUserInfo";
|
||||
import { alert, goLink, isEmptyObject, retrieval } from '@/common/common'
|
||||
import Popup from '@/components/popup'
|
||||
import { Button, Image, Picker, Text, Textarea, View } from '@tarojs/components'
|
||||
import Taro, { chooseMedia } from '@tarojs/taro'
|
||||
import { realNameUpdateApi, companyTypeApi, portraitUpdateApi } from '@/api/user'
|
||||
import { companyDetailApi, companyUpdateApi } from '@/api/company'
|
||||
import { memo, useCallback, useEffect, useMemo, useRef, useState } from 'react'
|
||||
import './index.scss'
|
||||
import ModifyModal from './components/ModifyModal'
|
||||
import useLogin from '@/use/useLogin'
|
||||
import { useSelector } from '@/reducers/hooks'
|
||||
import useUploadCDNImg from '@/use/useUploadImage'
|
||||
import { IMG_CND_Prefix } from '@/common/constant'
|
||||
import useUserInfo from '@/use/useUserInfo'
|
||||
|
||||
export default () => {
|
||||
const { getPhoneNumber, getAdminUserInfo } = useLogin();
|
||||
const { adminUserInfo } = useSelector(state => state.userInfo);
|
||||
const { getPhoneNumber, getAdminUserInfo } = useLogin()
|
||||
const { adminUserInfo } = useSelector((state) => state.userInfo)
|
||||
// 用户信息
|
||||
useEffect(() => {
|
||||
setFormData({
|
||||
...formData,
|
||||
...adminUserInfo as any,
|
||||
});
|
||||
}, [adminUserInfo]);
|
||||
...(adminUserInfo as any),
|
||||
})
|
||||
}, [adminUserInfo])
|
||||
useEffect(() => {
|
||||
setFormData({
|
||||
...adminUserInfo as any,
|
||||
company_type_index: 0
|
||||
});
|
||||
getCompanyTypeData();
|
||||
...(adminUserInfo as any),
|
||||
company_type_index: 0,
|
||||
})
|
||||
getCompanyTypeData()
|
||||
}, [])
|
||||
// 表单数据
|
||||
const [formData, setFormData] = useState<typeof adminUserInfo>(adminUserInfo);
|
||||
const [formData, setFormData] = useState<typeof adminUserInfo>(adminUserInfo)
|
||||
// 昵称修改保存
|
||||
const { fetchData: realNameUpdateFetch } = realNameUpdateApi();
|
||||
const { fetchData: realNameUpdateFetch } = realNameUpdateApi()
|
||||
const rules = {
|
||||
text: [{
|
||||
message: "请输入"
|
||||
}]
|
||||
text: [
|
||||
{
|
||||
message: '请输入',
|
||||
},
|
||||
],
|
||||
}
|
||||
const { fetchData: saveFetch } = companyUpdateApi();
|
||||
const { fetchData: getCompanyFetch } = companyDetailApi();
|
||||
const { fetchData: saveFetch } = companyUpdateApi()
|
||||
const { fetchData: getCompanyFetch } = companyDetailApi()
|
||||
const handleTextareaSave = async (text, type) => {
|
||||
retrieval({ text }, rules).then(async () => {
|
||||
let result;
|
||||
if (type == "Ickname") {
|
||||
result = await realNameUpdateFetch({ real_name: text });
|
||||
} else {
|
||||
const params = await getCompanyFetch();
|
||||
result = await saveFetch({
|
||||
...params.data,
|
||||
company_name: text
|
||||
});
|
||||
}
|
||||
if (result.success) {
|
||||
getAdminUserInfo();
|
||||
(ModifyIcknameEl.current as any).setModalShow(false);
|
||||
(ModifyCompanyNameEl.current as any).setModalShow(false)
|
||||
alert.success("保存成功");
|
||||
} else {
|
||||
alert.none(result.msg);
|
||||
}
|
||||
}).catch(message => {
|
||||
alert.none(message);
|
||||
})
|
||||
retrieval({ text }, rules)
|
||||
.then(async () => {
|
||||
let result
|
||||
if (type == 'Ickname') {
|
||||
result = await realNameUpdateFetch({ real_name: text })
|
||||
} else {
|
||||
const params = await getCompanyFetch()
|
||||
result = await saveFetch({
|
||||
...params.data,
|
||||
company_name: text,
|
||||
})
|
||||
}
|
||||
if (result.success) {
|
||||
getAdminUserInfo()
|
||||
;(ModifyIcknameEl.current as any).setModalShow(false)
|
||||
;(ModifyCompanyNameEl.current as any).setModalShow(false)
|
||||
alert.success('保存成功')
|
||||
} else {
|
||||
alert.none(result.msg)
|
||||
}
|
||||
})
|
||||
.catch((message) => {
|
||||
alert.none(message)
|
||||
})
|
||||
}
|
||||
// Taro.eventCenter.on('message:detail', (message) => console.log(message))
|
||||
// 面面跳转
|
||||
const onNavigate = (url: string) => {
|
||||
goLink(url);
|
||||
goLink(url)
|
||||
}
|
||||
// 肖像编辑
|
||||
const { fetchData: portraitUpdateFetch } = portraitUpdateApi();
|
||||
const { getWxPhoto } = useUploadCDNImg();
|
||||
const { fetchData: portraitUpdateFetch } = portraitUpdateApi()
|
||||
const { getWxPhoto } = useUploadCDNImg()
|
||||
const handleSelectRortrait = () => {
|
||||
Taro.showModal({
|
||||
title: "提示",
|
||||
content: "是否确定更改头像?",
|
||||
title: '提示',
|
||||
content: '是否确定更改头像?',
|
||||
showCancel: true,
|
||||
async success(ev) {
|
||||
if (ev.confirm) {
|
||||
let result = await getWxPhoto('mall');
|
||||
let result = await getWxPhoto('mall')
|
||||
const portraitUpdateResult = await portraitUpdateFetch({
|
||||
avatar_url: IMG_CND_Prefix + (result as any).url
|
||||
});
|
||||
avatar_url: IMG_CND_Prefix + (result as any).url,
|
||||
})
|
||||
if (portraitUpdateResult.success) {
|
||||
getAdminUserInfo();
|
||||
alert.success("保存成功");
|
||||
getAdminUserInfo()
|
||||
alert.success('保存成功')
|
||||
} else {
|
||||
alert.none(portraitUpdateResult.msg);
|
||||
alert.none(portraitUpdateResult.msg)
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
})
|
||||
}
|
||||
const mGetPhoneNumber = (ev) => {
|
||||
if (ev.detail?.code) {
|
||||
getPhoneNumber(ev.detail.code);
|
||||
getPhoneNumber(ev.detail.code)
|
||||
} else {
|
||||
alert.none("绑定失败!");
|
||||
alert.none('绑定失败!')
|
||||
}
|
||||
}
|
||||
const ModifyIcknameEl = useRef(null);
|
||||
const ModifyCompanyNameEl = useRef(null);
|
||||
const ModifyIcknameEl = useRef(null)
|
||||
const ModifyCompanyNameEl = useRef(null)
|
||||
// 获取企业类型
|
||||
const { fetchData: companyTypeFetch, state: companyTypeData } = companyTypeApi();
|
||||
const { fetchData: companyTypeFetch, state: companyTypeData } = companyTypeApi()
|
||||
const getCompanyTypeData = async () => {
|
||||
const reuslt = await companyTypeFetch();
|
||||
const reuslt = await companyTypeFetch()
|
||||
if (reuslt.success) {
|
||||
reuslt.data?.list?.every((item, index) => {
|
||||
if (item.id == (adminUserInfo as any).purchaser_type) {
|
||||
setFormData({
|
||||
...adminUserInfo as any,
|
||||
company_type_index: index
|
||||
});
|
||||
return false;
|
||||
...(adminUserInfo as any),
|
||||
company_type_index: index,
|
||||
})
|
||||
return false
|
||||
}
|
||||
return true;
|
||||
return true
|
||||
})
|
||||
}
|
||||
}
|
||||
// 修改企业类型
|
||||
const handleCompanyType = async (ev) => {
|
||||
const { value } = ev.detail;
|
||||
const item = companyTypeData.data.list && companyTypeData.data.list[value];
|
||||
const { value } = ev.detail
|
||||
const item = companyTypeData.data.list && companyTypeData.data.list[value]
|
||||
if (item) {
|
||||
if(item.id == 0) return alert.error('请选择类型')
|
||||
const params = await getCompanyFetch();
|
||||
if (item.id == 0) return alert.error('请选择类型')
|
||||
const params = await getCompanyFetch()
|
||||
const result = await saveFetch({
|
||||
...params.data,
|
||||
purchaser_type: item.id
|
||||
});
|
||||
purchaser_type: item.id,
|
||||
})
|
||||
if (result.success) {
|
||||
getAdminUserInfo();
|
||||
alert.success("保存成功")
|
||||
getAdminUserInfo()
|
||||
alert.success('保存成功')
|
||||
} else {
|
||||
alert.none(result.msg);
|
||||
alert.none(result.msg)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const {removeToken, removeSessionKey, removeUserInfo} = useUserInfo()
|
||||
const { removeToken, removeSessionKey, removeUserInfo } = useUserInfo()
|
||||
const outLogin = () => {
|
||||
removeToken()
|
||||
removeSessionKey()
|
||||
removeUserInfo()
|
||||
goLink('/pages/index/index',{}, 'switchTab')
|
||||
goLink('/pages/index/index', {}, 'switchTab')
|
||||
}
|
||||
|
||||
const comanyTypeDataFormat = useMemo(() => {
|
||||
if(companyTypeData.data.list) {
|
||||
return companyTypeData.data.list?.map(item => {
|
||||
if(item.id == 0) item.name = '--请选择类型--'
|
||||
if (companyTypeData.data.list) {
|
||||
return companyTypeData.data.list?.map((item) => {
|
||||
if (item.id == 0) item.name = '--请选择类型--'
|
||||
return item
|
||||
})
|
||||
} else {
|
||||
@ -161,42 +164,69 @@ export default () => {
|
||||
}, [companyTypeData])
|
||||
|
||||
return (
|
||||
<View className="user-edit">
|
||||
<View onClick={handleSelectRortrait} className="user-edit-portrait">
|
||||
<View className='user-edit'>
|
||||
<View onClick={handleSelectRortrait} className='user-edit-portrait'>
|
||||
<Image src={(formData as any)?.avatar_url} />
|
||||
<View>点击编辑头像</View>
|
||||
</View>
|
||||
<View className="user-edit-content">
|
||||
<View className="user-edit-content-title"><Text /> 个人资料</View>
|
||||
<UserEditList onClick={() => (ModifyIcknameEl.current as any).setModalShow(true)} data={(formData as any)?.user_name} label="昵称" placeholder="请输入" icon="" />
|
||||
<UserEditList label="手机号" placeholder="去绑定" icon="">
|
||||
{((formData as any)?.phone) ? <View className="user-edit-content-phone">
|
||||
<View>{(formData as any)?.phone}</View>
|
||||
<Text>已绑定</Text>
|
||||
</View> :
|
||||
<Button className="user-edit-content-bindphone" openType="getPhoneNumber" onGetPhoneNumber={mGetPhoneNumber}>去绑定</Button>
|
||||
}
|
||||
<View className='user-edit-content'>
|
||||
<View className='user-edit-content-title'>
|
||||
<Text /> 个人资料
|
||||
</View>
|
||||
<UserEditList
|
||||
onClick={() => (ModifyIcknameEl.current as any).setModalShow(true)}
|
||||
data={(formData as any)?.user_name}
|
||||
label='昵称'
|
||||
placeholder='请输入'
|
||||
icon=''
|
||||
/>
|
||||
<UserEditList label='手机号' placeholder='去绑定' icon=''>
|
||||
{(formData as any)?.phone ? (
|
||||
<View className='user-edit-content-phone'>
|
||||
<View>{(formData as any)?.phone}</View>
|
||||
<Text>已绑定</Text>
|
||||
</View>
|
||||
) : (
|
||||
<Button className='user-edit-content-bindphone' openType='getPhoneNumber' onGetPhoneNumber={mGetPhoneNumber}>
|
||||
去绑定
|
||||
</Button>
|
||||
)}
|
||||
</UserEditList>
|
||||
</View>
|
||||
<View className="user-edit-content">
|
||||
<View className="user-edit-content-title"><Text /> 组织资料</View>
|
||||
<UserEditList onClick={() => (ModifyCompanyNameEl.current as any).setModalShow(true)} data={(formData as any)?.company_name} label="组织名称" placeholder="待绑定" icon="" />
|
||||
<UserEditList label="组织类型" placeholder="完善公司/组织信息" icon="">
|
||||
<View className='user-edit-content'>
|
||||
<View className='user-edit-content-title'>
|
||||
<Text /> 组织资料
|
||||
</View>
|
||||
<UserEditList
|
||||
onClick={() => (ModifyCompanyNameEl.current as any).setModalShow(true)}
|
||||
data={(formData as any)?.company_name}
|
||||
label='组织名称'
|
||||
placeholder='待绑定'
|
||||
icon=''
|
||||
/>
|
||||
{/* <UserEditList label="组织类型" placeholder="完善公司/组织信息" icon="">
|
||||
<Picker mode="selector" range={comanyTypeDataFormat as any} rangeKey="name" value={(formData as any)?.purchaser_type} onChange={handleCompanyType}>
|
||||
{formData?.purchaser_type_name}
|
||||
</Picker>
|
||||
</UserEditList>
|
||||
<UserEditList label="我的认证" placeholder="待绑定" icon="" useIcon="true">
|
||||
<View className={`user-edit-content-company ${(formData as any)?.authentication_status == 4 && "user-edit-content-company-adopt"}`}>
|
||||
<Text className="iconfont " /> {(formData as any)?.authentication_status == 4 ? "已认证" : "未认证"}
|
||||
</UserEditList> */}
|
||||
<UserEditList label='我的认证' placeholder='待绑定' icon='' useIcon='true'>
|
||||
<View className={`user-edit-content-company ${(formData as any)?.authentication_status == 4 && 'user-edit-content-company-adopt'}`}>
|
||||
<Text className='iconfont ' /> {(formData as any)?.authentication_status == 4 ? '已认证' : '未认证'}
|
||||
</View>
|
||||
</UserEditList>
|
||||
<UserEditList label="创建人" data={(formData as any)?.founder_user_name} placeholder="完善公司/组织信息" icon="" useIcon="true" />
|
||||
<UserEditList label='创建人' data={(formData as any)?.founder_user_name} placeholder='完善公司/组织信息' icon='' useIcon='true' />
|
||||
</View>
|
||||
<Button hoverClass="none" className="user-edit-logout" onClick={outLogin}>退出当前账号</Button>
|
||||
<Button hoverClass='none' className='user-edit-logout' onClick={outLogin}>
|
||||
退出当前账号
|
||||
</Button>
|
||||
|
||||
<ModifyModal title="修改昵称" ref={ModifyIcknameEl} value={(formData as any)?.user_name} save={(value) => handleTextareaSave(value, "Ickname")} />
|
||||
<ModifyModal title="修改名称" ref={ModifyCompanyNameEl} value={(formData as any)?.company_name} save={(value) => handleTextareaSave(value, "companyName")} />
|
||||
<ModifyModal title='修改昵称' ref={ModifyIcknameEl} value={(formData as any)?.user_name} save={(value) => handleTextareaSave(value, 'Ickname')} />
|
||||
<ModifyModal
|
||||
title='修改名称'
|
||||
ref={ModifyCompanyNameEl}
|
||||
value={(formData as any)?.company_name}
|
||||
save={(value) => handleTextareaSave(value, 'companyName')}
|
||||
/>
|
||||
</View>
|
||||
)
|
||||
}
|
||||
@ -204,22 +234,11 @@ export default () => {
|
||||
// 列表
|
||||
const UserEditList = memo((props: any) => {
|
||||
return (
|
||||
<View onClick={props.onClick} className="user-edit-list">
|
||||
<View className="user-edit-list-left">
|
||||
{props.label}
|
||||
</View>
|
||||
<View className="user-edit-list-right">
|
||||
<View>
|
||||
{
|
||||
props.children ? props.children :
|
||||
props.data ? props.data :
|
||||
<View className="user-edit-list-right-placeholder">{props.placeholder}</View>
|
||||
}
|
||||
</View>
|
||||
{
|
||||
!props.useIcon &&
|
||||
<Text className="iconfont icon-a-moreback"></Text>
|
||||
}
|
||||
<View onClick={props.onClick} className='user-edit-list'>
|
||||
<View className='user-edit-list-left'>{props.label}</View>
|
||||
<View className='user-edit-list-right'>
|
||||
<View>{props.children ? props.children : props.data ? props.data : <View className='user-edit-list-right-placeholder'>{props.placeholder}</View>}</View>
|
||||
{!props.useIcon && <Text className='iconfont icon-a-moreback'></Text>}
|
||||
</View>
|
||||
</View>
|
||||
)
|
||||
|
@ -267,9 +267,9 @@
|
||||
content: '\e62f';
|
||||
}
|
||||
|
||||
.icon-daifahuo:before {
|
||||
content: '\e629';
|
||||
}
|
||||
// .icon-daifahuo:before {
|
||||
// content: '\e629';
|
||||
// }
|
||||
|
||||
.icon-daishouhuo:before {
|
||||
content: '\e62a';
|
||||
@ -279,70 +279,10 @@
|
||||
content: '\e62b';
|
||||
}
|
||||
|
||||
.icon-daipeibu:before {
|
||||
content: '\e62c';
|
||||
}
|
||||
// .icon-daipeibu:before {
|
||||
// content: '\e62c';
|
||||
// }
|
||||
|
||||
.icon-daifukuan:before {
|
||||
content: '\e62d';
|
||||
}
|
||||
|
||||
.icon-shezhi:before {
|
||||
content: '\e630';
|
||||
}
|
||||
|
||||
.icon-tishi:before {
|
||||
content: '\e631';
|
||||
}
|
||||
|
||||
.icon-erweima:before {
|
||||
content: '\e632';
|
||||
}
|
||||
|
||||
.icon-dianjishoucang:before {
|
||||
content: '\e633';
|
||||
}
|
||||
|
||||
.icon-gouwuche:before {
|
||||
content: '\e634';
|
||||
}
|
||||
|
||||
.icon-shoucangchenggong:before {
|
||||
content: '\e635';
|
||||
}
|
||||
|
||||
.icon-fenxiangshangpin:before {
|
||||
content: '\e636';
|
||||
}
|
||||
|
||||
.icon-kefu:before {
|
||||
content: '\e637';
|
||||
}
|
||||
|
||||
.icon-xinzenganniu:before {
|
||||
content: '\e62e';
|
||||
}
|
||||
|
||||
.icon-jianshaoanniu:before {
|
||||
content: '\e62f';
|
||||
}
|
||||
|
||||
.icon-daifahuo:before {
|
||||
content: '\e629';
|
||||
}
|
||||
|
||||
.icon-daishouhuo:before {
|
||||
content: '\e62a';
|
||||
}
|
||||
|
||||
.icon-tuikuan-shouhou:before {
|
||||
content: '\e62b';
|
||||
}
|
||||
|
||||
.icon-daipeibu:before {
|
||||
content: '\e62c';
|
||||
}
|
||||
|
||||
.icon-daifukuan:before {
|
||||
content: '\e62d';
|
||||
}
|
||||
// .icon-daifukuan:before {
|
||||
// content: '\e62d';
|
||||
// }
|
||||
|
Loading…
x
Reference in New Issue
Block a user