需要授权验证
- 如果源项目为公有仓库,禁止填写用户名密码。如果源项目为私有仓库,则必须填写正确的用户名和密码!
+
如果导入项目为私有仓库,则必须填写相应平台正确的用户名和密码
{
mirrorCheck &&
-
+
用户名
密码
{getFieldDecorator('password', {
rules: [],
@@ -393,143 +386,144 @@ class Index extends Component {
}
-
+
}
+
+
+ {getFieldDecorator('user_id', {
+ rules: [{
+ required: true, message: '请选择拥有者'
+ },{
+ validator:(rule, value, callback) => this.checkId(rule, value, callback, OwnerList, '拥有者')
+ }],
+ })(
+ this.ChangePlatform(value, e, 'owners', OwnerList)}
+ className="plateAutoComplete"
+ onBlur={(value) => this.blurCategory(value, OwnerList, "owners")}
+ >
+ {owners_list}
+
+ )}
+
+ /
+
+ {getFieldDecorator('name', {
+ rules: [{
+ required: true, message: '请填写项目名称'
+ }],
+ })(
+
+ )}
+
+
项目标识 (项目url标识部分)}
+ colon={false}
>
- {getFieldDecorator('name', {
+ {getFieldDecorator('repository_name', {
rules: [{
- required: true, message: '请填写项目名称'
+ required: true, message: '请填写项目标识'
}],
})(
-
+
)}
{descNum}/200
{getFieldDecorator('description', {
- rules: [{
- required: true, message: '请填写项目简介'
- }],
+ rules: [],
})(
)}
-
- {getFieldDecorator('repository_name', {
- rules: [{
- required: true, message: '请填写仓库名称'
- }],
- })(
-
- )}
-
-
- {getFieldDecorator('project_category', {
- rules: [{
- required: true, message: '请选择大类别',
- }, {
- validator: (rule, value, callback) => this.checkId(rule, value, callback, CategoryList, '项目类别')
- }],
- })(
- this.ChangePlatform(value, e, 'project_category', CategoryList)}
- className="plateAutoComplete"
- onBlur={(value) => this.blurCategory(value, CategoryList, "project_category")}
- >
- {project_category_list}
-
- )}
-
-
- {getFieldDecorator('project_language', {
- rules: [{
- required: true, message: '请选择项目语言'
- }, {
- validator: (rule, value, callback) => this.checkId(rule, value, callback, LanguageList, '项目语言')
- }],
- })(
- this.ChangePlatform(value, e, 'project_language', LanguageList)}
- className="plateAutoComplete"
- onBlur={(value) => this.blurCategory(value, LanguageList, "project_language")}
- >
- {project_language_list}
-
- )}
-
+
{
(projectsType === "deposit" || !projectsType) &&
- {getFieldDecorator('ignore', {
- rules: [{
- required: true, message: '请选择gitignore'
- }, {
- validator: (rule, value, callback) => this.checkId(rule, value, callback, GitignoreList, 'gitignore')
- }],
- })(
- this.ChangePlatform(value, e, 'ignore', GitignoreList)}
- className="plateAutoComplete"
- onBlur={(value) => this.blurCategory(value, GitignoreList, "ignore")}
- >
- {ignore_list}
-
+ {getFieldDecorator('ignoreFlag')(
+ this.setState({ignoreFlag:e.target.checked})}>.gitignore
)}
+ { ignoreFlag &&
+
+ {getFieldDecorator('ignore', {
+ rules: [{
+ required: ignoreFlag, message: '请选择gitignore'
+ }, {
+ validator: (rule, value, callback) => this.checkId(rule, value, callback, GitignoreList, 'gitignore')
+ }],
+ })(
+ this.ChangePlatform(value, e, 'ignore', GitignoreList)}
+ className="plateAutoComplete"
+ onBlur={(value) => this.blurCategory(value, GitignoreList, "ignore")}
+ >
+ {ignore_list}
+
+ )}
+
+ }
- {getFieldDecorator('license', {
- rules: [{
- required: true, message: '请选择开源许可证'
- }, {
- validator: (rule, value, callback) => this.checkId(rule, value, callback, LicensesList, '开源许可证')
- }],
- })(
- this.ChangePlatform(value, e, 'license', LicensesList)}
- className="plateAutoComplete"
- onBlur={(value) => this.blurCategory(value, LicensesList, "license")}
- >
- {license_list}
-
+ {getFieldDecorator('licenseFlag')(
+ this.setState({licenseFlag:e.target.checked})}>开源许可证
)}
+ { licenseFlag &&
+
+ {getFieldDecorator('license', {
+ rules: [{
+ required: licenseFlag, message: '请选择开源许可证'
+ }, {
+ validator: (rule, value, callback) => this.checkId(rule, value, callback, LicensesList, '开源许可证')
+ }],
+ })(
+ this.ChangePlatform(value, e, 'license', LicensesList)}
+ className="plateAutoComplete"
+ onBlur={(value) => this.blurCategory(value, LicensesList, "license")}
+ >
+ {license_list}
+
+ )}
+
+ }
}
{getFieldDecorator('private')(
- 将项目设为私有(只有项目所有人或拥有权限的项目成员才能看到)
+ 将项目设为私有(只有项目所有人或拥有权限的项目成员才能看到)
)}
{
projectsType && projectsType === "mirror" &&
{getFieldDecorator('is_mirror')(
@@ -537,7 +531,64 @@ class Index extends Component {
)}
}
-
+
+ {getFieldDecorator('categoreFlag')(
+ this.setState({categoreFlag:e.target.checked})}>项目类别
+ )}
+
+ {categoreFlag &&
+
+ {getFieldDecorator('project_category', {
+ rules: [{
+ required: categoreFlag, message: '请选择大类别',
+ }, {
+ validator: (rule, value, callback) => this.checkId(rule, value, callback, CategoryList, '项目类别')
+ }],
+ })(
+ this.ChangePlatform(value, e, 'project_category', CategoryList)}
+ className="plateAutoComplete"
+ onBlur={(value) => this.blurCategory(value, CategoryList, "project_category")}
+ >
+ {project_category_list}
+
+ )}
+
+ }
+
+ {getFieldDecorator('languageFlag')(
+ this.setState({languageFlag:e.target.checked})}>项目语言
+ )}
+
+ {languageFlag &&
+
+ {getFieldDecorator('project_language', {
+ rules: [{
+ required: languageFlag, message: '请选择项目语言'
+ }, {
+ validator: (rule, value, callback) => this.checkId(rule, value, callback, LanguageList, '项目语言')
+ }],
+ })(
+ this.ChangePlatform(value, e, 'project_language', LanguageList)}
+ className="plateAutoComplete"
+ onBlur={(value) => this.blurCategory(value, LanguageList, "project_language")}
+ >
+ {project_language_list}
+
+ )}
+
+ }
+
注: 为必填项,否则为选填
diff --git a/src/forge/New/new.css b/src/forge/New/new.scss
similarity index 72%
rename from src/forge/New/new.css
rename to src/forge/New/new.scss
index fcb6fa8cf..15aca70b2 100644
--- a/src/forge/New/new.css
+++ b/src/forge/New/new.scss
@@ -12,7 +12,13 @@
border-bottom: 1px solid #f0f0f0
}
.newPanel_content{
- padding:1rem 2rem;
+ padding:2rem;
+}
+.newPanel_content form .ant-row.ant-form-item{
+ margin-bottom: 25px;
+}
+.newPanel_content .ant-form-item-label label{
+ font-size: 16px;
}
.newPanel_content .ant-form-item-control-wrapper{
flex: 1;
@@ -25,24 +31,35 @@
height: 35px;
line-height: 35px;
}
-
.newContent_inline{
display: flex;
flex-wrap: wrap;
justify-content: space-between;
align-items:flex-end
}
+.explainPos{
+ .ant-form-explain{
+ position: absolute;
+ }
+}
.newContent_inline > .ant-form-item:nth-child(2){
margin-left: 20px;
}
-.newPanel_content .privatePart .ant-form-item-label{
- margin-left: 0px;
+.privatePart{
+ margin-bottom: 0px!important;
+ .ant-form-item-label{
+ margin-left: 0px;
+ }
}
.newPanel_content .ant-form-item-label{
line-height: 25px;
height: 25px;
- margin-left: -0.8rem;
+}
+.plateAutoComplete{
+ .ant-input{
+ height: 34px!important;
+ }
}
@media screen and (max-width: 750px){
.newPanel_content{
diff --git a/src/forge/Team/List.jsx b/src/forge/Team/List.jsx
index 7e64c5de2..5eebfc385 100644
--- a/src/forge/Team/List.jsx
+++ b/src/forge/Team/List.jsx
@@ -63,10 +63,10 @@ function List(props){
const menu_new=(
)
diff --git a/src/forge/Team/RightBox.jsx b/src/forge/Team/RightBox.jsx
index 7616fd6ca..5c85ae474 100644
--- a/src/forge/Team/RightBox.jsx
+++ b/src/forge/Team/RightBox.jsx
@@ -108,7 +108,7 @@ function RightBox({ OIdentifier , history , admin , showCompeleteDialog ,complet
{
(item.is_admin || item.is_member) ?
- {item.name}
+ {item.nickname}
:
{item.name}
}
diff --git a/src/forge/users/InfosUser.js b/src/forge/users/InfosUser.js
index 276a0b1f8..d6f30ee89 100644
--- a/src/forge/users/InfosUser.js
+++ b/src/forge/users/InfosUser.js
@@ -115,11 +115,11 @@ class InfosUser extends Component {
newItem =()=> (
);