Commit af0705b6 authored by 皮倩雯's avatar 皮倩雯

fix: '网站配置新增SaaS配置'

parent 92a4242a
Pipeline #54897 waiting for manual action with stages
...@@ -216,8 +216,9 @@ const AddModal = props => { ...@@ -216,8 +216,9 @@ const AddModal = props => {
break; break;
case '图片': case '图片':
case '可预览图片': case '可预览图片':
data[0].Preset = pramData.picture ? '拍照相册' : ''; data[0].Config = pramData.picture ? '拍照相册' : '';
data[0].ValidationRule = pramData.must ? 'required' : ''; // data[0].Preset = pramData.picture ? '拍照相册' : '';
// data[0].ValidationRule = pramData.must ? 'required' : '';
break; break;
case '平铺值选择器': case '平铺值选择器':
case '搜索选择器': case '搜索选择器':
...@@ -432,8 +433,9 @@ const AddModal = props => { ...@@ -432,8 +433,9 @@ const AddModal = props => {
break; break;
case '图片': case '图片':
case '可预览图片': case '可预览图片':
res[0].data.root.Preset === '拍照相册' ? (picture = true) : (picture = false); res[0].data.root.Config === '拍照相册' ? (picture = true) : (picture = false);
res[0].data.root.ValidationRule === 'required' ? (must = true) : (must = false); // res[0].data.root.Preset === '拍照相册' ? (picture = true) : (picture = false);
// res[0].data.root.ValidationRule === 'required' ? (must = true) : (must = false);
break; break;
case '编码': case '编码':
let code = res[0].data.root.Config.split('.'); let code = res[0].data.root.Config.split('.');
...@@ -1042,8 +1044,9 @@ const AddModal = props => { ...@@ -1042,8 +1044,9 @@ const AddModal = props => {
break; break;
case '图片': case '图片':
case '可预览图片': case '可预览图片':
aa.Preset === '拍照相册' ? (picture = true) : (picture = false); aa.Config === '拍照相册' ? (picture = true) : (picture = false);
aa.ValidationRule === 'required' ? (must = true) : (must = false); // aa.Preset === '拍照相册' ? (picture = true) : (picture = false);
// aa.ValidationRule === 'required' ? (must = true) : (must = false);
break; break;
case '编码': case '编码':
let code = aa.Config.split('.'); let code = aa.Config.split('.');
...@@ -1289,8 +1292,9 @@ const AddModal = props => { ...@@ -1289,8 +1292,9 @@ const AddModal = props => {
break; break;
case '图片': case '图片':
case '可预览图片': case '可预览图片':
res[0].data.root.Preset === '拍照相册' ? (picture = true) : (picture = false); res[0].data.root.Config === '拍照相册' ? (picture = true) : (picture = false);
res[0].data.root.ValidationRule === 'required' ? (must = true) : (must = false); // res[0].data.root.Preset === '拍照相册' ? (picture = true) : (picture = false);
// res[0].data.root.ValidationRule === 'required' ? (must = true) : (must = false);
break; break;
case '编码': case '编码':
let code = res[0].data.root.Config.split('.'); let code = res[0].data.root.Config.split('.');
...@@ -1526,8 +1530,9 @@ const AddModal = props => { ...@@ -1526,8 +1530,9 @@ const AddModal = props => {
break; break;
case '图片': case '图片':
case '可预览图片': case '可预览图片':
data[0].Preset = pramData.picture ? '拍照相册' : ''; data[0].Config = pramData.picture ? '拍照相册' : '';
data[0].ValidationRule = pramData.must ? 'required' : ''; // data[0].Preset = pramData.picture ? '拍照相册' : '';
// data[0].ValidationRule = pramData.must ? 'required' : '';
break; break;
case '平铺值选择器': case '平铺值选择器':
case '搜索选择器': case '搜索选择器':
...@@ -2108,7 +2113,7 @@ const AddModal = props => { ...@@ -2108,7 +2113,7 @@ const AddModal = props => {
</> </>
); );
case '图片': case '图片':
// case '可预览图片': case '可预览图片':
return ( return (
<Item name="ReadOnly" label="选项" labelCol={{ span: 4 }}> <Item name="ReadOnly" label="选项" labelCol={{ span: 4 }}>
<div> <div>
...@@ -2118,12 +2123,12 @@ const AddModal = props => { ...@@ -2118,12 +2123,12 @@ const AddModal = props => {
> >
允许从相册选取 允许从相册选取
</Checkbox> </Checkbox>
<Checkbox {/* <Checkbox
checked={pramData.must} checked={pramData.must}
onChange={e => onChangeReady(e, 'must')} onChange={e => onChangeReady(e, 'must')}
> >
必填字段 必填字段
</Checkbox> </Checkbox> */}
</div> </div>
</Item> </Item>
); );
...@@ -2144,7 +2149,7 @@ const AddModal = props => { ...@@ -2144,7 +2149,7 @@ const AddModal = props => {
<Item <Item
label="字段名" label="字段名"
name="fieldName" name="fieldName"
labelCol={{ span: 8 }} labelCol={{ span: 9 }}
rules={[{ required: true, message: '请输入表名' }]} rules={[{ required: true, message: '请输入表名' }]}
> >
<Input placeholder="请输入字段名" /> <Input placeholder="请输入字段名" />
...@@ -2170,7 +2175,7 @@ const AddModal = props => { ...@@ -2170,7 +2175,7 @@ const AddModal = props => {
<Item <Item
label="字段名" label="字段名"
name="fieldName" name="fieldName"
labelCol={{ span: 8 }} labelCol={{ span: 7 }}
rules={[{ required: true, message: '请输入表名' }]} rules={[{ required: true, message: '请输入表名' }]}
> >
<Input placeholder="请输入字段名" /> <Input placeholder="请输入字段名" />
...@@ -2512,49 +2517,51 @@ const AddModal = props => { ...@@ -2512,49 +2517,51 @@ const AddModal = props => {
} }
})()} })()}
{/* </div> */} {/* </div> */}
{Shape === '图片' || Shape === '可预览图片' ? ( {/* {Shape === '图片' || Shape === '可预览图片' ? (
'' ''
) : ( ) : ( */}
<Item label="预设值" labelCol={{ span: 4 }}> {/* <Item label="预设值" labelCol={{ span: 4 }}> */}
{/* <div className={styles.listEvent}> */} {/* <div className={styles.listEvent}> */}
<Row> <Row>
<Col span={10}> <Col span={12}>
<Input <Item label="预设值" labelCol={{ span: 8 }}>
// style={{ width: '41%', height: '1.8rem' }} <Input
value={pramData.Preset} // style={{ width: '41%', height: '1.8rem' }}
onChange={e => handleInput(e, 'Preset')} value={pramData.Preset}
placeholder="" onChange={e => handleInput(e, 'Preset')}
allowClear placeholder=""
/> allowClear
</Col> />
<Col span={13}> </Item>
<Item </Col>
style={{ marginLeft: '1rem' }} <Col span={11}>
label="验证" <Item
labelCol={{ span: 8 }} style={{ marginLeft: '1rem' }}
name="ValidationRule" label="验证"
> labelCol={{ span: 7 }}
<Input style={{ width: '92%' }} placeholder="" allowClear /> name="ValidationRule"
</Item> >
</Col> <Input style={{ width: '92%' }} placeholder="" allowClear />
<Col span={1}> </Item>
<Tooltip title="选择验证规则"> </Col>
<PlusSquareOutlined <Col span={1}>
onClick={() => { <Tooltip title="选择验证规则">
add('rule'); <PlusSquareOutlined
}} onClick={() => {
style={{ add('rule');
fontSize: '24px', }}
color: '#1890FF', style={{
marginTop: '8px', fontSize: '24px',
marginLeft: '-3px', color: '#1890FF',
}} marginTop: '8px',
/> marginLeft: '-3px',
</Tooltip> }}
</Col> />
</Row> </Tooltip>
</Item> </Col>
)} </Row>
{/* </Item> */}
{/* // )} */}
{/* <Item label="异常值"> {/* <Item label="异常值">
<div className={styles.listEvent}> <div className={styles.listEvent}>
<Input <Input
......
...@@ -91,7 +91,7 @@ export default props => { ...@@ -91,7 +91,7 @@ export default props => {
form.setFieldsValue({ form.setFieldsValue({
...config, ...config,
primaryColor: config.primaryColor ? config.primaryColor : '#0087F7', primaryColor: config.primaryColor ? config.primaryColor : '#0087F7',
navTheme: config.navTheme ? config.navTheme : 'light', navTheme: config.navTheme ? config.navTheme : 'dark',
headerPrimaryColor: config.headerPrimaryColor headerPrimaryColor: config.headerPrimaryColor
? config.headerPrimaryColor ? config.headerPrimaryColor
: 'linear-gradient(0deg, #0066D6 0%, #39A9FF 100%)', : 'linear-gradient(0deg, #0066D6 0%, #39A9FF 100%)',
...@@ -110,6 +110,7 @@ export default props => { ...@@ -110,6 +110,7 @@ export default props => {
loginTemplate: 'Default.html', loginTemplate: 'Default.html',
primaryColor: '#0087F7', primaryColor: '#0087F7',
navTheme: 'dark', navTheme: 'dark',
CloudStyle: '是',
headerPrimaryColor: 'linear-gradient(0deg, #0066D6 0%, #39A9FF 100%)', headerPrimaryColor: 'linear-gradient(0deg, #0066D6 0%, #39A9FF 100%)',
}); });
} }
...@@ -341,6 +342,14 @@ export default props => { ...@@ -341,6 +342,14 @@ export default props => {
/> />
</Form.Item> </Form.Item>
<div style={{ display: showAdvanced ? 'block' : 'none' }}> <div style={{ display: showAdvanced ? 'block' : 'none' }}>
<Form.Item label="SaaS样式" name="CloudStyle">
<Radio.Group>
<Radio value="是"></Radio>
<Radio value="否">租户</Radio>
</Radio.Group>
{/* <br />
<span>说明:用于云平台模式,默认云,选择租户会在SaaS访问情况下,展示租户样式。</span> */}
</Form.Item>
<Form.Item name="topMenu" label="顶部功能"> <Form.Item name="topMenu" label="顶部功能">
<Checkbox <Checkbox
indeterminate={indeterminate} indeterminate={indeterminate}
......
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