Commit 5e29ea9e authored by GuanHua's avatar GuanHua

update

parents 9a9253ad f0c89b87
/*
* @Author: LeeJiancong
* @Date: 2020-08-04 16:21:48
* @LastEditors: LeeJiancong
* @LastEditTime: 2020-10-12 13:37:53
*/
const router = {
path: '/enquiryOfferManager',
name: 'enquiryOfferManager',
key: 'enquiryOfferManager',
icon: 'SmileOutlined',
routes:[
//报价单查询
{
path: '/enquiryOfferManager/enquiryOffer/enquiryOfferSearch',
name: 'enquiryOfferSearch',
component: '@/pages/requisition/enquiryOffer/enquiryOfferSearch',
},
// 报价单查询详情
{
path: '/enquiryOfferManager/enquiryOffer/enquiryOfferDetail',
name: 'enquiryOfferDetail',
component: '@/pages/requisition/enquiryOffer/components/detail',
hideInMenu: true,
hidePageHeader: true
}
]
}
export default router
\ No newline at end of file
......@@ -2,7 +2,7 @@
* @Author: LeeJiancong
* @Date: 2020-08-04 15:47:40
* @LastEditors: LeeJiancong
* @LastEditTime: 2020-09-25 10:30:02
* @LastEditTime: 2020-10-12 11:25:06
*/
/**
......@@ -13,6 +13,7 @@ import calssPropertyRoute from './calssPropertyRoute' // 品类属性路由
import trademarkRoute from './brandRoute' // 品牌路由
import commodity from './commodityRoute' // 商品审核路由
import requisitionRoute from './requisitionRoute' //需求单
import enquiryOfferRoute from './enquiryOfferRoute' //报价单
import logisticsRoutes from './logisticsRoutes'
import memberAbility from './memberAbility'
import ruleSettingRoutes from './ruleSettingRoutes'
......@@ -26,6 +27,7 @@ const routeList = [
trademarkRoute,
commodity,
requisitionRoute,
enquiryOfferRoute,
logisticsRoutes,
memberAbility,
ruleSettingRoutes,
......
......@@ -18,4 +18,15 @@ export default {
// 'link-color': MAIN_COLOR,
// 'link-hover-color': MAIN_COLOR,
// 'link-active-color': MAIN_COLOR,
// Font-size
'@font-size-base': '12px',
'@font-size-lg': '14px',
'@font-size-sm': '12px',
// Layout
'@layout-header-height': '48px',
// PageHeader
// '@page-header-padding': '8px 24px', // 这里替换会出现前边拼接了 '6px 8px 24px'这样,所以直接改成修改样式好了
}
.head {
display: flex;
align-items: center;
font-size: 20px;
font-size: 18px;
font-weight: 500;
&-prefix {
......
......@@ -88,7 +88,7 @@
margin-bottom: 8px;
color: @text-color-secondary;
font-weight: normal;
font-size: 14px;
font-size: 12px;
line-height: 22px;
}
......
......@@ -11,7 +11,7 @@
.title {
margin-left: 16px;
font-size: 20px;
font-size: 18px;
color: #303133;
font-weight: 500;
}
......@@ -19,11 +19,11 @@
.back_btn {
color: #909399;
margin-left: 27px;
font-size: 16px;
font-size: 14px;
cursor: pointer;
&>span {
font-size: 14px;
font-size: 12px;
margin-left: 6px;
}
}
......
......@@ -9,7 +9,7 @@
&-title {
line-height: 24px;
padding-bottom: 0;
font-size: 16px;
font-size: 14px;
font-weight: 500;
color: rgba(23, 43, 77, 1);
}
......
......@@ -51,7 +51,7 @@ const RowStyleLayout = styled(props => <div {...props} />)`
font-size: 12px;
}
.card-checkbox-title {
font-size: 14px;
font-size: 12px;
color: #606266;
}
`
......
......@@ -5,7 +5,7 @@
background: #fff;
text-align: center;
line-height: 160px;
font-size: 20px;
font-size: 18px;
border-radius: 50%;
}
......@@ -39,12 +39,12 @@
align-items: center;
height: 32px;
color: rgba(0, 0, 0, 0.85);
font-size: 14px;
font-size: 12px;
&::before {
display: inline-block;
margin-right: 4px;
color: #ff4d4f;
font-size: 14px;
font-size: 12px;
font-family: SimSun, sans-serif;
line-height: 1;
content: '*';
......
......@@ -8,7 +8,7 @@
display: inline-block;
margin-left: 4px;
color: #ff4d4f;
font-size: 14px;
font-size: 12px;
font-family: SimSun, sans-serif;
line-height: 1;
content: '*';
......
.tag {
line-height: 22px;
padding: 0 8px;
font-size: 14px;
font-size: 12px;
font-weight: 400;
color: #00B37A;
background: #EBF7F2;
......
......@@ -5,7 +5,7 @@
align-items: center;
height: 54px;
background: #fff;
font-size: 18px;
font-size: 16px;
font-weight: 700;
color: @main-font-bold-color;
}
......
......@@ -5,20 +5,20 @@
list-style-type: decimal;
li{
color: #909399;
font-size: 14px;
font-size: 12px;
}
}
.step1Description{
h4{
height:22px;
font-size:14px;
font-size: 12px;
font-weight:500;
color:rgba(23,43,77,1);
line-height:22px;
}
p{
height:20px;
font-size:14px;
font-size: 12px;
font-weight:400;
color:rgba(107,119,140,1);
line-height:20px;
......
......@@ -210,19 +210,9 @@ ol {
#root {
.ant-pro-global-header {
height: 56px;
background: @header-global-nav-bg;
}
.ant-layout-header {
height: 56px;
line-height: 56px;
}
.ant-pro-global-header-trigger {
height: 56px;
}
.ant-pro-global-header-trigger:hover {
background: @header-global-nav-bg;
}
......@@ -369,7 +359,7 @@ ol {
.ant-tree .ant-tree-switcher .ant-tree-switcher-icon,
.ant-tree .ant-tree-switcher .ant-select-tree-switcher-icon {
font-size: 14px;
font-size: 12px;
}
.black-tabs {
......
export interface MemberType {
id: number;
typeName: string;
}
export interface BusinessType {
id: number;
typeName: string;
}
export interface UseType {
memberType: MemberType[];
businessType: BusinessType[];
}
export interface UserRegister {
useType: UseType;
}
export interface RuleConfiguration {
value: number;
label: string;
platformType: number;
}
export interface PayWayResponse {
payType: number;
value: number;
label: string;
}
export interface PayInitializeConfig {
payType: number;
ruleConfigurations: RuleConfiguration[];
payWayResponses: PayWayResponse[];
}
export interface PayPlatformPayConfig {
id: number;
way: string;
payType: number;
isPitchOn: number;
}
export interface PayConfig {
payInitializeConfig: PayInitializeConfig[];
payPlatformPayConfig: PayPlatformPayConfig[];
}
export interface CountryList {
name: string;
key: string;
icon: string;
}
export interface Children {
code: string;
}
export interface MenuList {
code: string;
children: Children[];
}
export interface Global {
logo: string;
countryList: CountryList[];
menuList: MenuList[];
}
export interface RootObject {
userRegister: UserRegister;
payConfig: PayConfig;
global: Global;
}
\ No newline at end of file
@import './mixins/layout.less';
#root {
.ant-pro-global-footer {
margin: 8px auto 32px auto;
}
.identityRadio{
display: flex;
flex-direction: column;
......
......@@ -42,9 +42,9 @@
justify-content: space-between;
background: #fff;
padding: 0 24px;
height: 64px;
line-height: 64px;
font-size: 20px;
height: 56px;
line-height: 56px;
font-size: 18px;
font-weight: bold;
color: #303133;
}
......@@ -63,9 +63,9 @@
display: flex;
justify-content: center;
align-items: center;
height: 56px;
height: 48px;
background: @header-global-nav-bg;
font-size: 18px;
font-size: 16px;
color: #fff;
}
......
......@@ -2,7 +2,7 @@
* @Author: LeeJiancong
* @Date: 2020-08-04 15:05:52
* @LastEditors: LeeJiancong
* @LastEditTime: 2020-09-25 14:01:53
* @LastEditTime: 2020-10-12 13:39:04
*/
import utils from '@/utils'
import menu from '../en-US/menu'
......@@ -85,8 +85,13 @@ export default {
'menu.requisitionManager.enquirySearch':'需求单查询',
'menu.requisitionManager.enquiryDetail':'需求单详情',
'menu.requisitionManager.aduitList':'需求单审核',
'menu.requisitionManager.aduitDetail':'需求单审核详情',
//报价单
'menu.enquiryOfferManager':'报价单管理',
'menu.enquiryOfferManager.enquiryOfferSearch':'报价单查询',
'menu.enquiryOfferManager.enquiryOfferDetail':'报价单详情',
//物流管理
'menu.logisticsManager': '物流管理',
'menu.logisticsManager.logisticsList': '物流单查询',
......
......@@ -69,7 +69,7 @@ const RowStyleLayout = styled(props => <div {...props} />)`
&-title {
line-height: 14px;
margin-bottom: 18px;
font-size: 14px;
font-size: 12px;
font-weight: 400;
color: #303133;
}
......@@ -84,7 +84,7 @@ const RowStyleLayout = styled(props => <div {...props} />)`
&-price {
line-height: 14px;
font-size: 14px;
font-size: 12px;
font-weight: 500;
color: #303133;
}
......
......@@ -69,7 +69,7 @@ const RowStyleLayout = styled(props => <div {...props} />)`
&-title {
line-height: 14px;
margin-bottom: 18px;
font-size: 14px;
font-size: 12px;
font-weight: 400;
color: #303133;
}
......@@ -84,7 +84,7 @@ const RowStyleLayout = styled(props => <div {...props} />)`
&-price {
line-height: 14px;
font-size: 14px;
font-size: 12px;
font-weight: 500;
color: #303133;
}
......
......@@ -18,7 +18,7 @@
&-name {
line-height: 14px;
margin-bottom: 13px;
font-size: 14px;
font-size: 12px;
font-weight: 400;
}
......
......@@ -5,7 +5,7 @@
line-height: 14px;
padding: 12px;
position: relative;
font-size: 14px;
font-size: 12px;
font-weight: 400;
color: #606266;
border-bottom: 1px solid #EEF0F3;
......
......@@ -5,20 +5,20 @@
list-style-type: decimal;
li{
color: #909399;
font-size: 14px;
font-size: 12px;
}
}
.step1Description{
h4{
height:22px;
font-size:14px;
font-size: 12px;
font-weight:500;
color:rgba(23,43,77,1);
line-height:22px;
}
p{
height:20px;
font-size:14px;
font-size: 12px;
font-weight:400;
color:rgba(107,119,140,1);
line-height:20px;
......
......@@ -9,7 +9,6 @@ import {
import { StandardTable } from 'god'
import { ColumnType } from 'antd/lib/table/interface'
import moment from 'moment'
// import styles from "./index.less"
import { PublicApi } from '@/services/api'
import EyePreview from '@/components/EyePreview'
......
......@@ -5,20 +5,20 @@
list-style-type: decimal;
li{
color: #909399;
font-size: 14px;
font-size: 12px;
}
}
.step1Description{
h4{
height:22px;
font-size:14px;
font-size: 12px;
font-weight:500;
color:rgba(23,43,77,1);
line-height:22px;
}
p{
height:20px;
font-size:14px;
font-size: 12px;
font-weight:400;
color:rgba(107,119,140,1);
line-height:20px;
......@@ -139,9 +139,14 @@
height:180px;
margin-left: 16px;
border:1px solid rgba(235,236,240,1);
position: relative;
img{
width: 100%;
height: 100%;
max-width: 100%;
max-height: 100%;
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
}
}
.videoItem{
......@@ -171,9 +176,14 @@
height:104px;
margin-right: 16px;
border:1px solid rgba(235,236,240,1);
position: relative;
.pic{
width: 100%;
height: 100%;
max-width: 100%;
max-height: 100%;
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
}
}
}
......
......@@ -11,10 +11,12 @@ import { Input, Select } from 'antd';
import { PublicApi } from '@/services/api';
import { useInitialValues } from '../hooks/useInitialValues';
import CustomUpload from '../components/WrapCustomUpload';
import useCustomValidator from '../hooks/useValidator'
const actions = createFormActions();
const AdvertisementInfo = () => {
useCustomValidator()
const { id, preview } = usePageStatus();
const initialValues = useInitialValues({id:id}, PublicApi.getManageContentAdvertGet);
const [submitLoading, setSubmitLoading ] = useState(false);
......
......@@ -34,7 +34,7 @@ const schema = {
"x-rules": [
{
"required": true,
"message": "最长20个字符,10个汉字"
"message": "最长60个字符,30个汉字"
},
{
limitByte: true, // 自定义校验规则
......@@ -70,6 +70,12 @@ const schema = {
title: '跳转链接',
type: 'string',
'x-component': 'Input',
"x-rules": [
{
limitByte: true, // 自定义校验规则
maxByte: 100,
}
]
},
imageUrl: {
type: "object",
......
......@@ -14,10 +14,12 @@ import { useInitialValues } from '../hooks/useInitialValues';
import CustomCheckbox from '../components/CustomCheckbox';
import BraftEditor from 'braft-editor';
import { setFormStatus } from '../utils/utils';
import useCustomValidator from '../hooks/useValidator'
const actions = createFormActions();
const AdvertisementInfo = () => {
useCustomValidator();
const { id, preview } = usePageStatus();
const initialValues: any = useInitialValues({id:id}, PublicApi.getManageContentNoticeGet);
const [submitLoading, setSubmitLoading ] = useState(false);
......
......@@ -23,7 +23,7 @@ const schema = {
"x-rules": [
{
"required": true,
"message": "最长20个字符,10个汉字"
"message": "最长60个字符,30个汉字"
},
{
limitByte: true, // 自定义校验规则
......
......@@ -6,6 +6,7 @@ import ReutrnEle from '@/components/ReturnEle';
import { usePageStatus } from '@/hooks/usePageStatus';
import { history, Prompt } from 'umi';
import { PublicApi } from '@/services/api';
import useCustomValidator from '../hooks/useValidator'
interface IOption {
value: number|string,
......@@ -41,9 +42,6 @@ const schema = {
name: 'name',
title: '栏目名称',
'x-component': 'Input',
'x-component-props': {
maxLength: 20
},
"required": true,
"x-rules": [
{
......@@ -89,6 +87,7 @@ const useInitialValues = (id) => {
}
const ColumnInfo = () => {
useCustomValidator();
const { id, preview } = usePageStatus();
const [ submitLoading, setSubmitLoading ] = useState(false);
const initialValues = useInitialValues(id);
......
import React from 'react';
import { Table } from 'antd';
const CustomTable = (props) => {
const { column, dataSource, ...rest } = props;
return (
<div>
<Table
column={column}
dataSource={dataSource}
{...rest}
></Table>
</div>
)
}
export default CustomTable;
\ No newline at end of file
import React from 'react';
import React, { useEffect } from 'react';
import {
SchemaForm,
registerVirtualBox
registerVirtualBox,
SchemaField,
registerValidationRules
} from '@formily/antd';
import { Row, Col } from 'antd';
// import { FormMegaLayout, Input } from '@formily/antd-components';
import { SchemaField } from "@formily/antd";
const renderCol = (schema) => {
const { flexcol = {}, } = schema && schema['x-component-props'] || {};
......@@ -17,7 +18,6 @@ const renderCol = (schema) => {
registerVirtualBox('CustomFlexRowLayout', (props) => {
const schemaProps = props;
console.log("CustomFlexRowLayout", schemaProps);
const childProperties = schemaProps.schema && schemaProps.schema.getOrderProperties() || [];
const { justify = "start", align = "top" } = schemaProps && schemaProps.props && schemaProps.props['x-component-props'] || {}
return (
......@@ -35,9 +35,7 @@ const FlexColumnLayoutStyle = {
}
registerVirtualBox('CustomFlexColumnLayout', (props) => {
const schemaProps = props;
console.log("CustomFlexColumnLayout", schemaProps);
const childProperties = schemaProps.schema && schemaProps.schema.getOrderProperties() || [];
console.log("childProperties", childProperties)
const { style } = schemaProps && schemaProps.props && schemaProps.props['x-component-props'] || {};
return (
......@@ -58,6 +56,7 @@ registerVirtualBox('CustomFlexColumnLayout', (props) => {
const FilterTable = (props) => {
const { actions, schema, components, ...rest } = props;
return (
<div>
<SchemaForm
......
import FilterTable from './FilterTable';
import CustomTable from './CustomTable';
import { SchemaFlexRowLayout, SchemaFlexColumnLayout } from './FlexLayout';
export {
FilterTable,
CustomTable,
SchemaFlexRowLayout,
SchemaFlexColumnLayout
}
\ No newline at end of file
......@@ -4,11 +4,11 @@
display: flex;
flex-direction: row;
justify-content: flex-start;
flex-wrap: nowrap;
flex-wrap: wrap;
.selectionItem {
height: 24px;
font-size: 14px;
// height: 24px;
font-size: 12px;
padding: 0px 7px;
margin: 0 16px 16px 0;
display: flex;
......@@ -37,20 +37,21 @@
.tags {
display: flex;
flex-direction: row;
flex-wrap: nowrap;
flex-wrap: wrap;
cursor: pointer;
user-select: none;
.tagItem {
height: 28px;
// height: 28px;
padding: 0 6px;
background: #F4F5F7;
border-radius: 4px;
font-size: 14px;
font-size: 12px;
color: #606266;
display: flex;
justify-content: center;
align-items: center;
margin-right: 16px;
margin-bottom: 16px;
}
}
}
\ No newline at end of file
......@@ -40,6 +40,7 @@ const Tags = (props) => {
const dataSource = props.props['x-component-props']['dataSource'] || [];
const selected = dataSource.filter((item) => tags.includes(item.value) )
return (
<div className={styles.tagContainer}>
<div className={styles.selection}>
......
import React, { useEffect, useState } from 'react';
import {
registerValidationRules
} from '@formily/antd';
const useCustomValidator = () => {
useEffect(() => {
//自定义校验规则
registerValidationRules({
limitByte: (value, desc, rules) => {
const { allowChineseTransform = true, maxByte } = desc;
let str = value;
let message = `不能超过${maxByte}个字符`
if (allowChineseTransform) {
str = str.replace(/[\u4E00-\u9FA5]/g, "AA");
message += `,或者${maxByte / 2}个汉字`
}
return str.length > maxByte ? message : "";
}
});
}, [])
}
export default useCustomValidator
......@@ -10,10 +10,12 @@ import { Input, Select } from 'antd';
import CustomUpload from '../components/WrapCustomUpload';
import { PublicApi } from '@/services/api';
import { useInitialValues } from '../hooks/useInitialValues';
import useCustomValidator from '../hooks/useValidator'
const actions = createFormActions();
const ImageInfo = () => {
useCustomValidator();
const { id, preview } = usePageStatus();
const initialValues: any = useInitialValues({id:id}, PublicApi.getManageContentImageGet);
const [submitLoading, setSubmitLoading ] = useState(false);
......
......@@ -27,7 +27,7 @@ const ImagesManagement = () => {
useEffect(() => {
const params = {
current: 1,
pageSize: 1
pageSize: 10
}
getTableDataSource(actions, params, getData);
}, [])
......@@ -43,7 +43,7 @@ const ImagesManagement = () => {
const postData = {
name: title || '',
current: 1,
pageSize: 1,
pageSize: 10,
...params,
}
getTableDataSource(actions, postData, getData);
......
......@@ -139,7 +139,7 @@ const schema = {
},
'x-component-props': {
showQuickJumper: true,
pageSize: 1,
pageSize: 10,
size: 'small'
}
}
......
import React, { useEffect, useState } from 'react';
import { SchemaForm,Submit, FormButtonGroup, Reset, createVirtualBox, createFormActions } from '@formily/antd';
import { Card, Select, Input, Checkbox, Grid, Button } from 'antd';
import { SchemaForm,Submit, FormButtonGroup, Reset, createFormActions, registerValidationRules } from '@formily/antd';
import { Card, Select, Input, Checkbox} from 'antd';
import { PageHeaderWrapper } from '@ant-design/pro-layout';
import ReutrnEle from '@/components/ReturnEle';
import { usePageStatus } from '@/hooks/usePageStatus';
......@@ -13,12 +13,14 @@ import { useInitialValues } from '../hooks/useInitialValues';
import { PublicApi } from '@/services/api';
import infomationInfoSchema from './schema/infomationInfoSchema';
import CustomUpload from '../components/WrapCustomUpload';
import useCustomValidator from '../hooks/useValidator'
const actions = createFormActions();
const { TextArea } = Input;
const InfomationInfo = () => {
useCustomValidator();
const { id, preview } = usePageStatus();
const [isTop, setIsTop] = useState(1);
const [labelIds, setLabelIds] = useState<number[]>([]);
......
......@@ -33,12 +33,18 @@ const schema = {
title: '标题',
'x-component': 'Input',
'x-component-props': {
placeholder: '30个字符,15个汉字'
},
"x-rules": {
"required": true,
"message": "最长30个字符,15个汉字"
placeholder: '最长30个汉字,60个字符',
},
"x-rules": [
{
"required": true,
"message": "请填写标题"
},
{
limitByte: true,
maxByte: 60
}
]
},
columnId: {
name: 'columnId',
......@@ -131,11 +137,18 @@ const schema = {
"x-component": 'TextArea',
"x-component-props": {
placeholder: "最长300个字符,150个汉字",
rows: 5,
},
"x-rules": {
"required": true,
"message": "最长300个字符,150个汉字"
},
"x-rules": [
{
"required": true,
"message": "最长300个字符,150个汉字"
},
{
limitByte: true,
maxByte: 300
}
],
},
contentLayout: {
'x-component': 'mega-layout',
......
......@@ -7,6 +7,7 @@ import { usePageStatus } from '@/hooks/usePageStatus';
import { history, Prompt } from 'umi';
import { useInitialValues } from '../hooks/useInitialValues';
import { PublicApi } from '@/services/api';
import useCustomValidator from '../hooks/useValidator'
const { TextArea } = Input;
const schema = {
......@@ -27,20 +28,32 @@ const schema = {
title: '标签名称',
'x-component': 'Input',
"required": true,
"x-rules": {
"required": true,
"message": "请填写标签名称"
},
"x-rules": [
{
"required": true,
"message": "请填写标签名称"
},
{
limitByte: true, // 自定义校验规则
maxByte: 20,
}
],
},
explain: {
name: 'explain',
title: '标签说明',
'x-component': 'TextArea',
"required": true,
"x-rules": {
"required": true,
"message": "请选择标签说明"
},
"x-rules": [
{
"required": true,
"message": "请选择标签说明"
},
{
limitByte: true, // 自定义校验规则
maxByte: 80,
}
],
},
}
}
......@@ -50,6 +63,7 @@ const schema = {
const TagInfo = () => {
useCustomValidator();
const { id, preview } = usePageStatus();
const [ submitLoading, setSubmitLoading ] = useState(false);
const initialValues = useInitialValues({id:id}, PublicApi.getManageContentLabelGet);
......
......@@ -2,9 +2,19 @@ import React, { Component } from 'react';
class Home extends Component {
render() {
return <div>
<h1>home页面</h1>
</div>;
return (
<div
style={{
margin: '-24px',
}}
>
<img
src="https://shushangyun01.oss-cn-shenzhen.aliyuncs.com/bc7f3a2385c0438bafcf1b74212cc7721601275065050.png"
width="100%"
height="auto"
/>
</div>
);
}
}
......
......@@ -13,7 +13,7 @@
&-title {
margin-bottom: 20px;
line-height: 24px;
font-size: 16px;
font-size: 14px;
font-weight: 500;
color: rgba(23, 43, 77, 1);
}
......@@ -50,7 +50,7 @@
&-title {
margin-bottom: 9px;
line-height: 22px;
font-size: 14px;
font-size: 12px;
font-weight: 400;
color: rgba(23, 43, 77, 1);
text-align: center;
......@@ -69,7 +69,7 @@
&-tag {
line-height: 22px;
padding: 0 6px;
font-size: 14px;
font-size: 12px;
font-weight: 400;
text-align: center;
border-radius: 4px;
......@@ -107,7 +107,7 @@
&-title {
line-height: 20px;
margin-bottom: 24px;
font-size: 14px;
font-size: 12px;
font-weight: 400;
color: rgba(107, 119, 140, 1);
}
......
.head {
display: flex;
align-items: center;
font-size: 20px;
font-size: 18px;
font-weight: 500;
&-prefix {
......
......@@ -39,7 +39,7 @@
.title {
margin-bottom: 20px;
line-height: 20px;
font-size: 14px;
font-size: 12px;
font-weight: 400;
color: rgba(107, 119, 140, 1);
......
.tag {
line-height: 22px;
padding: 0 8px;
font-size: 14px;
font-size: 12px;
font-weight: 400;
color: #00B37A;
background: #EBF7F2;
......
.headerTop {
display: flex;
align-items: center;
font-size: 20px;
font-size: 18px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
......@@ -28,7 +28,7 @@
background-color: #FFEBE6;
border-radius: 4px;
color: #E63F3B;
font-size: 14px;
font-size: 12px;
font-weight: 400;
text-align: center;
}
......@@ -47,7 +47,7 @@
display: flex;
width: calc(100% / 3);
margin-bottom: 17px;
font-size: 14px;
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #909399;
......
......@@ -71,7 +71,7 @@
line-height: 36px;
background: rgba(0, 0, 0, 0.65);
color: #ffffff;
font-size: 16px;
font-size: 14px;
text-align: center;
cursor: pointer;
}
......
......@@ -10,7 +10,7 @@
flex-grow: 1;
padding: 24px;
overflow: auto;
font-size: 14px;
font-size: 12px;
line-height: 1.5715;
}
......
......@@ -62,7 +62,7 @@
color: #ffffff;
text-align: center;
line-height: 24px;
font-size: 14px;
font-size: 12px;
background: #4279DF;
border-radius: 8px 0px 8px 0px;
z-index: 3;
......@@ -112,7 +112,7 @@
.template_info_content_text_wrap {
flex: 1;
font-size: 14px;
font-size: 12px;
line-height: 22px;
.template_info_content_text_line {
......@@ -141,7 +141,7 @@
border: 1px solid rgba(235, 236, 240, 1);
cursor: pointer;
color: #606266;
font-size: 14px;
font-size: 12px;
// margin-top: auto;
margin-left: auto;
......
......@@ -21,11 +21,11 @@
color: #909399;
padding-left: 12px;
font-size: 14px;
font-size: 12px;
&>label {
color: #303133;
font-size: 20px;
font-size: 18px;
margin-left: 4px;
}
}
......
......@@ -34,7 +34,7 @@
.loading_text {
margin-top: 16px;
font-size: 16px;
font-size: 14px;
font-weight: bold;
}
}
\ No newline at end of file
......@@ -17,7 +17,7 @@
.select-box, .animate-btn {
height: 24px;
font-family: PingFang-SC-Regular;
font-size: 14px;
font-size: 12px;
letter-spacing: 0.2px;
color: #555;
border-radius: 2px;
......
......@@ -38,13 +38,13 @@
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 14px;
font-size: 12px;
color: #303133;
}
&_price {
color: #D32F2F;
font-size: 14px;
font-size: 12px;
margin-top: 8px;
margin-bottom: 4px;
......
......@@ -6,7 +6,7 @@
padding: 8px;
border-bottom: 1px solid #F4F5F7;
color: #606266;
font-size: 14px;
font-size: 12px;
&::before {
position: absolute;
......
......@@ -23,13 +23,13 @@
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 14px;
font-size: 12px;
color: #303133;
}
&_price {
color: #D32F2F;
font-size: 14px;
font-size: 12px;
margin-top: 8px;
margin-bottom: 4px;
......
......@@ -25,13 +25,13 @@
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 14px;
font-size: 12px;
color: #303133;
}
&_price {
color: #D32F2F;
font-size: 14px;
font-size: 12px;
margin-top: 8px;
margin-bottom: 4px;
......
......@@ -8,7 +8,7 @@
.back_btn {
color: #909399;
margin-left: 27px;
font-size: 16px;
font-size: 14px;
margin-top: 40px;
cursor: pointer;
align-self: flex-start;
......@@ -35,7 +35,7 @@
color: #ffffff;
text-align: center;
line-height: 24px;
font-size: 14px;
font-size: 12px;
background: #4279DF;
border-radius: 8px 0px 8px 0px;
z-index: 3;
......
......@@ -82,5 +82,36 @@ export const enquirySearchexternalState2 = (text:any) => {
/****** *********************** 报价单 ************************** */
//内部
export const enquiryOfferSearchInteriorState = (text:any) => {
let component: ReactNode = null;
text === 1 ? component = <Badge status='default' text="新增报价单" />:
text === 2 ? component = <Badge color="#FFC400" text="审核报价单一级" />:
text === 3 ? component = <Badge color="#FFC400" text="审核报价单二级" />:
text === 4 ? component = <Badge status='processing' text="待提交报价单" />:
text === 5 ? component = <Badge status='success' text="完成" />:
text === 6 ? component = <Badge status='error' text="审核不通过" />:
component = <Badge status="default" text="取消报价单" />
return component;
}
//外部
export const enquiryOfferSearchexternalState = (text:any) => {
let component: ReactNode = null;
// text === 1 ? component = <Badge status='default' text="提交需求单" />:
// text === 2 ? component = <Badge color="#FFC400" text="审核需求单" />:
// text === 3 ? component = <Badge status='default' text="待提交报价单" />:
// text === 4 ? component = <Badge status='processing' text="确认报价单" />:
// text === 5 ? component = <Badge status='success' text="完成" />:
// text === 6 ? component = <Badge status='error' text="审核不通过" />:
// component = <Badge status="default" text="取消报价单" />
text === 1 ? component = <span style={statuStyle.default}>待提交需求单</span>:
text === 2 ? component = <span style={statuStyle.default}>审核需求单</span>:
text === 3 ? component = <span style={statuStyle.confirm}>待提交报价单</span>:
text === 4 ? component = <span style={statuStyle.confirm}>确认报价单</span>:
text === 5 ? component = <span style={statuStyle.success}>完成</span>:
text === 6 ? component = <span style={statuStyle.Error}>审核不通过</span>:
component = <span style={statuStyle.default}>取消报价单</span>
return component;
}
import React, { Component, useState, useEffect } from 'react';
import { Modal, Button, Form } from 'antd'
import {
SchemaForm, SchemaMarkupField as Field,
createFormActions,
FormEffectHooks
} from '@formily/antd'
import { Input, Radio, FormMegaLayout } from '@formily/antd-components'
import { PublicApi } from '@/services/api'
import {PATTERN_MAPS} from '@/constants/regExp'
export interface Params {
id: number | string;
type: number|string;//1是一级 2是二级
dialogVisible: boolean;
onCancel: Function;
onOK?: Function;
dontReceive?: boolean; //默认展示
}
const actions = createFormActions()
const { onFieldChange$ } = FormEffectHooks
const comfirmDialog: React.FC<Params> = (props) => {
console.log(props.dialogVisible)
const handleCancel = () => {
}
const handletOk = (values: any) => {
let value = { ...values }
value.id = props.id
console.log('value',value)
if(props.type == 1){
PublicApi.postOrderRequisitionFormAudit(value).then(res => {
if (res.code === 1000) {
props.onOK()
}
})
}else if(props.type == 2){
PublicApi.postOrderRequisitionFormAuditTwo(value).then(res => {
if (res.code === 1000) {
props.onOK()
}
})
}
}
useEffect(() => {
return () => {
}
}, [])
const useFormEffects = () => {
const { setFieldState } = createFormActions()
onFieldChange$('state').subscribe(({ value }) => {
setFieldState('cause', state => {
if (value == 1) {
state.visible = false
} else {
state.visible = true
}
})
})
}
return (
<>
<Modal
title='审核确认'
width={800}
visible={props.dialogVisible}
onOk={() => actions.submit()}
onCancel={() => props.onCancel()}
destroyOnClose
afterClose={() => actions.reset()}
okText='确定'
cancelText={`取消`}
>
<SchemaForm
layout="vertical"
labelCol={4}
components={{
Input, Radio: Radio.Group, TextArea: Input.TextArea
}}
actions={actions}
effects={() => useFormEffects()}
onSubmit={(values) => handletOk(values)}
initialValues={{
state: 1
}}
>
<Field
enum={
[
{ label: '审核通过', value: 1 },
{ label: '审核不通过', value: 0 }
]}
name='state'
required
x-component="Radio"
x-component-props={{
}}
/>
{props.dontReceive &&
<>
{/* <FormMegaLayout name='remarkOption' label='不接受原因' full required labelCol={2} labelAlign="top"> */}
<Field
title='审核不通过原因'
name="cause"
x-component="TextArea"
required
x-component-props={{
placeholder: '在此输入你的内容,最多60个汉字'
}}
x-rules ={{
max:60,
// maximum:10,//最大数值
message:'原因最多60个汉字'
}}
/>
</>
}
</SchemaForm>
</Modal>
</>
)
}
comfirmDialog.defaultProps = {
dontReceive: true
}
export default comfirmDialog
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
/*
* @Author: LeeJiancong
* @Date: 2020-08-24 11:39:11
* @LastEditors: LeeJiancong
* @Copyright: 1549414730@qq.com
* @LastEditTime: 2020-10-12 13:47:28
*/
/**
* @description: 组件描述:
* @param {type}
* @return {type}
*/
import React, { ReactNode, useRef, useState,useEffect } from 'react';
import { history } from 'umi';
import {
Button,
Card,
Space,
Row,
Col,
Dropdown,
Menu,
Popconfirm
} from 'antd';
import { PageHeaderWrapper } from '@ant-design/pro-layout';
import {
PlusOutlined,DownOutlined,DeleteOutlined
} from '@ant-design/icons';
import { StandardTable } from 'god';
import { ColumnType } from 'antd/lib/table/interface';
import {
IFormFilter,
IButtonFilter,
} from 'god/dist/src/standard-table/TableController';
import EyePreview from '@/components/EyePreview';
import StatusSwitch from '@/components/StatusSwitch';
import {interiorState,interiorStateTwo,
enquirySearchInteriorState,enquirySearchexternalState,enquiryOfferSearchexternalState} from '../../common/tableStatusList'
import statuStyle from '../../common/colorTag'
import NiceForm from '@/components/NiceForm';
import {timeRange} from '@/utils/index'
import {filterInteriorStateList,filterExternalStateList} from '../../common/tableStatusList'
import moment from 'moment'
import { createFormActions, FormEffectHooks } from '@formily/antd';
import {PageStatus} from '@/hooks/usePageStatus'
import { useStateFilterSearchLinkageEffect } from '@/formSchema/effects/useFilterSearch';
import {searchSelectGetSelectCategoryOptionEffect} from '../../effect/index'
import { FORM_FILTER_PATH } from '@/formSchema/const';
import { enquieryOfferSearchSchema } from '../../schema';
import { PublicApi } from '@/services/api';
import { values, action } from 'mobx';
export interface listParams{
type: number;
des?: string;
}
const formActions = createFormActions();
const List:React.FC<{listParams}> = (props) => {
const ref = useRef<any>({})
const [more, setmore] = useState(false)
const [selectRow, setSelectRow] = useState([])
const [selectedRowKeys, setSelectedRowKeys] = useState<Array<number>>([])
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
}
/**
* @description:
* @param {type} type: 1 需求发布 2报价 可以根据props.type处理
* @return {type}
*/
const handleToDetail= (type,id) => {
if(type === 1){
history.push(`/requisitionManager/aduit/enquirySearch/enquiryDetail?page_type=${4}&id=${id}`)
}else{
history.push(`/enquiryOfferManager/enquiryOffer/enquiryOfferDetail?page_type=${4}&id=${id}`)
}
}
const fetchData = async (params: any) => {
const res = await PublicApi.getOrderPlatformQuotationList(params);
return res.data
}
const columns : ColumnType<any>[] = [
{
title:'报价单号',
key:'quotationNo',
dataIndex:'quotationNo',
align:'center',
render: (text: any,records: any) => <EyePreview type="button" handleClick={() => {
handleToDetail(2,records.id)
}}>{text}</EyePreview>
},
{
title:'需求单号',
key:'requisitionFormNo',
dataIndex:'requisitionFormNo',
align:'center',
render: (text: any,records: any) => <EyePreview type="button" handleClick={() => {
handleToDetail(1,records.requisitionId)//需求单id
}}>{text}</EyePreview>
},
{
title:'报价单摘要',
key:'quotationSummary',
dataIndex:'quotationSummary',
align:'left'
},
{
title:'需求会员',
key:'demandMembers',
dataIndex:'demandMembers',
align:'left'
},
{
title:'报价会员',
key:'quotedMembers',
dataIndex:'quotedMembers',
align:'left'
},
{
title:'报价截至时间',
key:'quotationAsTime',
dataIndex:'quotationAsTime',
align:'center',
render:(text:any)=> format(text)
},
{
title:'单据时间',
key:'documentsTime',
dataIndex:'documentsTime',
align:'center',
render:(text:any)=> format(text)
},
{
title:'外部状态',
key:'externalState',
dataIndex:'externalState',
align:'center',
render: (text: any, reconds) =>
enquiryOfferSearchexternalState(text)
// {
// let component: ReactNode = null
// if (text == 3) {
// component = <><span style={statuStyle.warn}>审核不通过需求单</span></>
// }else if (text == 1) {
// component = <><span style={statuStyle.default}>待提交需求单</span></>
// }
// return component
// }
},
{
title:'内部状态',
key:'interiorState',
dataIndex:'interiorState',
align:'center',
render:(text:any) =>
enquirySearchInteriorState(text)
}
]
useEffect(()=> {
},[])
const toEdit = (id:number | string) => {
history.push(`/memberCenter/tranactionAbility/enquirySubmit/addEnquiry?id=${id}`)
}
/**
* @description: 删除
* @param {type}
* @return {type}
*/
const handleDelete = (arr:number[]| string[]) => {
PublicApi.postOrderRequisitionFormDeleteAll({ ids: arr }).then(res => {
ref.current.reload()
})
}
//提交审核
const handleSubmit = (id) => {
PublicApi.postOrderNewRequisitionFormAudit({ id: id }).then(res => {
ref.current.reload()
})
}
const handleSumbit = (values:any) => {
if(values.voucherTime){
values.startVoucherTime = timeRange(values.voucherTime).st
values.endVoucherTime = timeRange(values.voucherTime).et
delete values.voucherTime
}
console.log('values',values)
ref.current.reload(values)
}
const handleBatchDel = (e:any) => {
}
const rowSelection = {
selectedRowKeys: selectedRowKeys,
onChange: (selectedRowKeys: any, selectedRows: any) => {
setSelectRow(selectedRows);
setSelectedRowKeys(selectedRowKeys);
console.log(`selectedRowKeys: ${selectedRowKeys}`, 'selectedRows: ', selectedRows)
},
}
const controllerBtns = <Row>
<Col span={24}>
</Col>
</Row>
return (
<Card>
<StandardTable
currentRef={ref}
columns={columns}
tableProps={{rowKew:'id'}}
fetchTableData={(params: any) => fetchData(params)}
// rowSelection={rowSelection}
controlRender={
<NiceForm
actions={formActions}
onSubmit={values => handleSumbit(values)}
effects={($,actions) => {
useStateFilterSearchLinkageEffect($,actions,'quotationNo',FORM_FILTER_PATH)
FormEffectHooks.onFieldChange$('category').subscribe(state => {
searchSelectGetSelectCategoryOptionEffect(actions,'category')
})
}}
schema={enquieryOfferSearchSchema}
>
</NiceForm>
}
/>
</Card>
)
}
export default List
\ No newline at end of file
......@@ -407,4 +407,124 @@ export const dialogEqformSearch: ISchema = {
}
}
}
}
\ No newline at end of file
}
/**
* @description: 需求报价-报价查询
* @param {type}
* @return {type}
*/
export const enquieryOfferSearchSchema: ISchema = {
type:'object',
properties:{
megalayout:{
type:'object',
"x-component":'mega-layout',
properties:{
quotationNo:{
type:'string',
"x-component":"Search",
"x-mega-props":{
},
"x-component-props":{
placeholder:'搜索',
align: 'flex-left',
}
}
}
},
[FORM_FILTER_PATH]:{
type:'object',
"x-component":"flex-layout",
"x-component-props":{
rowStyle:{
justifyContent: 'flex-start',
flexWrap:'nowrap'
},
colStyle:{//改变间隔
marginRight: 20
}
},
properties:{
PRO_LAYOUT:{
type:'object',
"x-component":'mega-layout',
"x-mega-props":{
span: 5
},
"x-component-props":{
inline: true
},
properties:{
requisitionFormNo:{
type:'string',
"x-component-props":{
placeholder:'对应需求单号'
}
},
quotationSummary:{
type:'string',
"x-component-props":{
placeholder:'摘要'
}
},
demandMembers:{
type:'string',
"x-component-props":{
placeholder:'需求会员'
}
},
quotedMembers:{
type:'string',
"x-component-props":{
placeholder:'报价会员'
}
},
// category:{
// type:'string',
// 'x-component': 'CustomInputSearch',
// 'x-component-props': {
// placeholder: '商品品类',
// showSearch: true,
// showArrow: true,
// defaultActiveFirstOption: false,
// filterOption: false,
// notFoundContent: null,
// style: { width: '174px', lineHeight: '32px' },
// searchValue: null,
// dataoption: []
// }
// // "x-component-props":{
// // placeholder:'请选择品类'
// // },
// // enum:[]
// },
voucherTime:{
type:'string',
default: 0,
"x-component-props":{
placeholder:'请选择单据时间'
},
enum: TimeList
},
}
},
sumbit:{
"x-component":'Submit',
"x-mega-props":{
span: 1
},
"x-component-props":{
children:'查询'
}
}
}
}
}
}
......@@ -3,7 +3,7 @@
* @Date: 2020-08-06 19:07:53
* @LastEditors: LeeJiancong
* @Copyright: 1549414730@qq.com
* @LastEditTime: 2020-08-20 20:16:22
* @LastEditTime: 2020-09-30 16:30:06
*/
import React, { useEffect , useState,useRef } from 'react'
import {Card,Button,Modal} from 'antd'
......@@ -31,7 +31,7 @@ const payActions = createFormActions()
* @return {type}
*/
const fetchMemberList = async (params) => {
const res = await PublicApi.getMemberManagePayPage(params)
const res = await PublicApi.getPayApplyMemberList(params)
return res.data
}
......@@ -154,9 +154,13 @@ const PaySetting: React.FC<{}> = () => {
let {data} = res
console.log('结果',res.data)
payActions.setFieldValue('paymentPolicyName',data.paymentPolicyName)
data.paymentPolicyPayWayRequests.forEach((item,index) => {
data.paymentPolicyPayWayRequests.forEach((item:any,index) => {
payActions.setFieldValue(`id-${index}`,item.id)
payActions.setFieldValue(`ruleConfigurationId-${index}`,item.ruleConfigurationId)
payActions.setFieldValue(`payWayIds-${index}`,item.payWayIds)
// payActions.setFieldValue(`payWayIds-${index}`,item.payWayIds)
item.payWays.forEach((v) => {
payActions.setFieldValue(`payWayIds-${index}`,v.id)
})
})
payActions.setFieldValue('isSelected',data.isSelected )
}
......@@ -178,7 +182,7 @@ const PaySetting: React.FC<{}> = () => {
const formSearch: ISchema = {
type: 'object',
properties: {
name: {
memberName: {
type: 'string',
"x-component": 'Search',
"x-component-props": {
......@@ -190,15 +194,40 @@ const PaySetting: React.FC<{}> = () => {
// 整体表单提交
const handleSubmit = (values:any) => {
let baseList: any = GlobalConfig.payConfig.payInitializeConfig
console.log('values',values)
console.log('values:',values,'baseList:',baseList)
let list:any = []
baseList.forEach((item:any,index:number) => {
let payWayIds = `payWayIds-${index}`, ruleConfigurationId = `ruleConfigurationId-${index}`
let payWayIds = `payWayIds-${index}`, ruleConfigurationId = `ruleConfigurationId-${index}`,_id = `id-${index}`
let v = [values[payWayIds],item.payWayResponses.filter((v=> v.value == values[payWayIds])).map(v => v.label)]
let _payWays:any[] = []
if(v.length === 2){
let obj:any = {}
// if(v[0] &&v[0].length > 0){
v[0].forEach(item => {
obj.id = item
});
// }
// if(v[1] &&v[1].length > 0 ){
v[1].forEach(item => {
obj.way = item
});
// }
_payWays.push(obj)
}
list.push({
id: values[_id],
payType: item.payType,
['payWayIds']: values[payWayIds],
['payWays']: [..._payWays],
// ['payWayIds']: values[payWayIds],
// ['payWays']:{
// id: values[payWayIds],
// way: item.payWayResponses.filter((v=> v.value == values[payWayIds])).map(v => v.label)
// },
['ruleConfigurationId']:values[ruleConfigurationId]
})
});
let params:any = {
paymentPolicyName: values.paymentPolicyName,
......
......@@ -2,7 +2,7 @@
* @Author: LeeJiancong
* @Date: 2020-08-06 11:12:18
* @LastEditors: LeeJiancong
* @LastEditTime: 2020-08-21 15:08:14
* @LastEditTime: 2020-09-29 15:36:47
*/
import React, { useState, useEffect } from 'react'
import { ISchema } from '@formily/antd'
......@@ -36,6 +36,12 @@ export const strategyDetailTab = (props: any, usePageStatus: any) => {
required: true,
},
properties: {
[`id-${index}`]: {
type: 'string',
display: false,
'x-component-props': {
},
},
[`ruleConfigurationId-${index}`]: {
type: 'string',
enum: item.ruleConfigurations || [],
......
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