Commit 692ce8ea authored by 前端-钟卫鹏's avatar 前端-钟卫鹏

Merge branch 'dev' into test

parents a88682d7 cf6eff75
...@@ -88,7 +88,7 @@ ...@@ -88,7 +88,7 @@
"chalk": "^4.1.0", "chalk": "^4.1.0",
"clone": "^2.1.2", "clone": "^2.1.2",
"connect-history-api-fallback": "^1.6.0", "connect-history-api-fallback": "^1.6.0",
"cross-env": "^7.0.2", "cross-env": "^7.0.3",
"events": "^3.2.0", "events": "^3.2.0",
"express": "^4.17.1", "express": "^4.17.1",
"fs-extra": "^9.0.1", "fs-extra": "^9.0.1",
......
...@@ -69,6 +69,7 @@ const NumberRange = (props) => { ...@@ -69,6 +69,7 @@ const NumberRange = (props) => {
borderLeft: 0, borderLeft: 0,
borderRight: 0, borderRight: 0,
pointerEvents: 'none', pointerEvents: 'none',
background: '#fff',
}} }}
placeholder="~" placeholder="~"
disabled disabled
......
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
// } // }
// } // }
.advertisementSpace { .advertisementSpace {
width: 386px; margin-bottom: 16px;
height: 217px; height: 217px;
.img { .img {
width: 100%; width: 100%;
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
padding: 24px; padding: 24px;
background-color: #fff; background-color: #fff;
border-radius: 8px; border-radius: 8px;
height: 361px;
.header { .header {
display: flex; display: flex;
flex-direction: row; flex-direction: row;
...@@ -25,6 +26,10 @@ ...@@ -25,6 +26,10 @@
display: flex; display: flex;
flex-direction: row; flex-direction: row;
align-items: center; align-items: center;
&:last-of-type {
margin-bottom: 0px;
}
.date { .date {
margin-right: 16px; margin-right: 16px;
padding: 2px 6px; padding: 2px 6px;
...@@ -42,6 +47,13 @@ ...@@ -42,6 +47,13 @@
} }
.content { .content {
cursor: pointer; cursor: pointer;
text-overflow: -o-ellipsis-lastline;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2;
line-clamp: 2;
-webkit-box-orient: vertical;
} }
} }
} }
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
background-color: #fff; background-color: #fff;
padding: 24px; padding: 24px;
border-radius: 8px; border-radius: 8px;
height: 235px;
.header { .header {
.title { .title {
......
.userGuaid { .grid_container {
margin-bottom: 24px; display: grid;
} }
.ability {
.main { margin-top: 16px;
// display: flex; }
// flex-direction: row; .controller {
.mainSide {
// flex: 1;
// display: flex;
// flex-direction: column;
.ability {
margin-top: 24px;
}
}
.rightSide {
.actions {
display: flex;
}
.announce {
margin-top: 24px;
}
.controller {
background-color: @main-color; background-color: @main-color;
height: 48px; height: 48px;
display: flex; display: flex;
...@@ -43,6 +23,78 @@ ...@@ -43,6 +23,78 @@
.text { .text {
margin-left: 8px; margin-left: 8px;
} }
}
.advertise {
margin-top: 16px;
}
@media (min-width: 1600px) {
.grid_container {
// display: grid;
// grid-template-columns: 75% 25%;
// grid-template-columns: repeat(24, 1fr);
// grid-auto-flow: column dense;
// grid-column-gap: 16px;
.top {
display: grid;
grid-template-columns: repeat(24, 1fr);
grid-column-gap: 16px;
grid-row-gap: 16px;
.userCenter {
grid-column-start: 1;
grid-column-end: 19;
grid-row-start: 1;
}
.actions {
grid-column-start: 19;
grid-column-end: 25;
grid-row-start: 1;
}
.announce {
grid-column-start: 19;
grid-column-end: 25;
margin-top: -200px;
}
.recentVisit {
grid-column-start: 19;
grid-column-end: 25;
}
}
}
.bottom {
display: grid;
grid-template-columns: repeat(24, 1fr);
grid-column-gap: 16px;
grid-row-gap: 16px;
.otherCenter {
grid-column-start: 1;
grid-column-end: 19;
grid-row-start: 1;
margin-top: -425px;
}
.anyQuestion {
grid-column-start: 19;
grid-column-end: 25;
margin-top: 16px;
}
.advertise {
grid-column-start: 19;
grid-column-end: 25;
} }
} }
} }
@media (max-width: 1599px) {
.userCenter {
margin: 16px 0;
}
.recentVisit {
margin-top: 16px;
}
}
...@@ -57,12 +57,35 @@ const Home: React.FC<{}> = () => { ...@@ -57,12 +57,35 @@ const Home: React.FC<{}> = () => {
<div className={styles.userGuaid} style={{display: visible ? 'none': 'none'}}> <div className={styles.userGuaid} style={{display: visible ? 'none': 'none'}}>
<UseGuaid/> <UseGuaid/>
</div> </div>
<div className={styles.main}> <div className={styles.grid_container}>
<Row gutter={[16,16]}> <div className={styles.top}>
<Col className={styles.mainSide} sm={24} md={24} lg={24} xl={16} xxl={18}> <div className={styles.actions}>
<div> <Row gutter={24}>
<Col span={12}>
<CustomWorkBench
handleChangeOrder={handleChangeOrder}
layouts={layout}
/></Col>
<Col span={12}>
<div className={styles.controller} onClick={() => setVisible((state) => !state)}>
<CompassFilled className={styles.icon} />
<span className={styles.text}>使用向导</span>
</div>
</Col>
</Row>
</div>
<div className={styles.userCenter}>
<UserCenter /> <UserCenter />
</div> </div>
<div className={styles.announce}>
<LatestAnnounce />
</div>
<div className={styles.recentVisit}>
<RecentVisit />
</div>
</div>
<div className={styles.bottom}>
<div className={styles.otherCenter}>
{ {
layout.map((item) => { layout.map((item) => {
const RenderComponent = ComponentSelect[item.name] const RenderComponent = ComponentSelect[item.name]
...@@ -80,36 +103,16 @@ const Home: React.FC<{}> = () => { ...@@ -80,36 +103,16 @@ const Home: React.FC<{}> = () => {
) )
}) })
} }
</Col>
<Col className={styles.rightSide} sm={24} md={24} lg={24} xl={8} xxl={6}>
<Row gutter={24}>
<Col span={12}>
<CustomWorkBench
handleChangeOrder={handleChangeOrder}
layouts={layout}
/></Col>
<Col span={12}>
<div className={styles.controller} onClick={() => setVisible((state) => !state)}>
<CompassFilled className={styles.icon} />
<span className={styles.text}>使用向导</span>
</div>
</Col>
</Row>
<div className={styles.announce}>
<LatestAnnounce />
</div>
<div className={styles.announce}>
<RecentVisit />
</div> </div>
<div className={styles.announce}> <div className={styles.anyQuestion}>
<AnyQuestion /> <AnyQuestion />
</div> </div>
<div className={styles.announce}> <div className={styles.advertise}>
<AdvertisementContainer /> <AdvertisementContainer />
</div> </div>
</Col>
</Row>
</div> </div>
</div>
</> </>
</PageHeaderWrapper> </PageHeaderWrapper>
) )
......
...@@ -364,13 +364,13 @@ const PurchaseOrder: React.FC<PurchaseOrderPropsType> = (props) => { ...@@ -364,13 +364,13 @@ const PurchaseOrder: React.FC<PurchaseOrderPropsType> = (props) => {
idList = [...idList, ...item.checkedList] idList = [...idList, ...item.checkedList]
} }
if (idList.length <= 0) { if (idList.length <= 0) {
message.info("请选择要移动的商品") message.info("请选择要删除的商品")
return false return false
} }
Modal.confirm({ Modal.confirm({
centered: true, centered: true,
className: styles.mallComfirm, className: styles.mallComfirm,
content: `是否从进货单中除选中的商品?`, content: `是否从进货单中除选中的商品?`,
onOk: () => { onOk: () => {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
PublicApi.postSearchShopPurchaseDeletePurchase({ idList: idList }).then(res => { PublicApi.postSearchShopPurchaseDeletePurchase({ idList: idList }).then(res => {
...@@ -393,16 +393,21 @@ const PurchaseOrder: React.FC<PurchaseOrderPropsType> = (props) => { ...@@ -393,16 +393,21 @@ const PurchaseOrder: React.FC<PurchaseOrderPropsType> = (props) => {
* @param ids * @param ids
*/ */
const deleteListItems = (ids: number[]) => { const deleteListItems = (ids: number[]) => {
console.log(ids, "ids")
const newOrderList = JSON.parse(JSON.stringify(orderList)) const newOrderList = JSON.parse(JSON.stringify(orderList))
const result = [] const result = []
for (const item of newOrderList) { for (const item of newOrderList) {
const newItem = item const newItem = item
newItem.checkedList = newItem.checkedList.filter(checkItem => !ids.includes(checkItem))
newItem.orderList = newItem.orderList.filter(orderItem => !ids.includes(orderItem.id)) newItem.orderList = newItem.orderList.filter(orderItem => !ids.includes(orderItem.id))
if (newItem.orderList.length > 0) { if (newItem.orderList.length > 0) {
result.push(newItem) result.push(newItem)
} }
} }
setOrderList(result) setOrderList(result)
if(result.every(resItem => resItem.checkedList.length === 0)){
setIndeterminate(false)
}
} }
/** /**
...@@ -750,7 +755,7 @@ const PurchaseOrder: React.FC<PurchaseOrderPropsType> = (props) => { ...@@ -750,7 +755,7 @@ const PurchaseOrder: React.FC<PurchaseOrderPropsType> = (props) => {
<Checkbox <Checkbox
value={item.id} value={item.id}
className="common_checkbox" className="common_checkbox"
indeterminate={!!item.checkedList.length && item.checkedList.length < item.defaultCheckedList.length} indeterminate={!!item.checkedList.length && item.checkedList.length < item.defaultCheckedList.length && item.checkedList.length > 0}
onChange={(e) => onCheckChildAllChange(e, item.id)} onChange={(e) => onCheckChildAllChange(e, item.id)}
></Checkbox> ></Checkbox>
<label>{item.shopname}</label> <label>{item.shopname}</label>
......
...@@ -173,7 +173,7 @@ const AccountDetail: React.FC<{}> = () => { ...@@ -173,7 +173,7 @@ const AccountDetail: React.FC<{}> = () => {
</div> </div>
</div> </div>
<div className={styles['repayment-right']}> <div className={styles['repayment-right']}>
<Button ghost onClick={handleSubmitApply} loading={btnLoading}>提交</Button> <Button ghost onClick={handleSubmitApply} loading={btnLoading} disabled={bankDetail ? false: true}>提交</Button>
</div> </div>
</div> </div>
</Col> </Col>
......
...@@ -12,11 +12,12 @@ const addressSchema: ISchema = { ...@@ -12,11 +12,12 @@ const addressSchema: ISchema = {
labelAlign: 'left', labelAlign: 'left',
labelCol: 4, labelCol: 4,
wrapperCol: 20, wrapperCol: 20,
full: true full: true,
}, },
properties: { properties: {
type: { type: {
type: 'radio', type: 'radio',
required: true,
title: '开具类型', title: '开具类型',
enum: [ enum: [
{ {
...@@ -29,12 +30,6 @@ const addressSchema: ISchema = { ...@@ -29,12 +30,6 @@ const addressSchema: ISchema = {
} }
], ],
default: 1, default: 1,
"x-rules": [
{
required: true,
message: '请选择开具类型'
},
],
"x-linkages": [ "x-linkages": [
{ {
type: 'value:visible', type: 'value:visible',
...@@ -45,6 +40,7 @@ const addressSchema: ISchema = { ...@@ -45,6 +40,7 @@ const addressSchema: ISchema = {
}, },
kind: { kind: {
type: 'radio', type: 'radio',
required: true,
title: '发票种类', title: '发票种类',
enum: [ enum: [
{ {
...@@ -57,39 +53,35 @@ const addressSchema: ISchema = { ...@@ -57,39 +53,35 @@ const addressSchema: ISchema = {
} }
], ],
default: 1, default: 1,
"x-rules": [
{
required: true,
message: '请选择开具类型'
}
]
}, },
invoiceTitle: { invoiceTitle: {
type: 'string', type: 'string',
required: true,
title: '发票抬头', title: '发票抬头',
"x-rules": [ "x-rules": [
{ {
required: true,
message: '请输入发票抬头'
},
{
limitByte: true, limitByte: true,
maxByte: 40 maxByte: 40
}, },
{
required: true,
message: '请输入发票抬头'
}
] ]
}, },
taxNo: { taxNo: {
type: 'string', type: 'string',
required: true,
title: '纳税号', title: '纳税号',
"x-rules": [ "x-rules": [
{ {
required: true,
message: '请输入纳税号'
},
{
limitByte: true, limitByte: true,
maxByte: 20 maxByte: 20
}, },
{
required: true,
message: '请输入纳税号'
}
] ]
}, },
bankOfDeposit: { bankOfDeposit: {
......
...@@ -138,7 +138,12 @@ const ProductModalTable:React.FC<ProductModalTableProps> = (props) => { ...@@ -138,7 +138,12 @@ const ProductModalTable:React.FC<ProductModalTableProps> = (props) => {
const handleConfirmProduct = async () => { const handleConfirmProduct = async () => {
// 判断所选择的商品是否属于同一个工作流 // 判断所选择的商品是否属于同一个工作流
const res = await PublicApi.postOrderIsWorkFlow({memberId: rowSelectionCtl.selectRow[0].memberId, productIds: rowSelectionCtl.selectedRowKeys}, { ctlType: 'none' }) const res = await PublicApi.postOrderIsWorkFlow({
memberId: rowSelectionCtl.selectRow[0].memberId,
memberRoleId: rowSelectionCtl.selectRow[0].memberRoleId,
productIds: rowSelectionCtl.selectedRowKeys,
orderModel: schemaAction.getFieldValue('orderModel')
}, { ctlType: 'none' })
if (res.code === 1000) { if (res.code === 1000) {
const productData = schemaAction.getFieldValue('orderProductRequests') const productData = schemaAction.getFieldValue('orderProductRequests')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment