pick image widget add max count

pull/1/head
张萌 3 years ago
parent 19469b774a
commit b6026d029c

@ -409,17 +409,18 @@ class _PublishTaskPageState extends State<PublishTaskPage> {
},
child: Material(
color: Colors.transparent,
child:'${_appointDate==null ? '请选择开始时间' : DateUtil.formatDate(_appointDate, format: 'MM月dd日 HH:mm')}'
child:
'${_appointDate == null ? '请选择开始时间' : DateUtil.formatDate(_appointDate, format: 'MM月dd日 HH:mm')}'
.text
.size(28.sp)
.color(Colors.black.withOpacity(_appointDate == null ? 0.25 : 0.85))
.color(Colors.black
.withOpacity(_appointDate == null ? 0.25 : 0.85))
.make(),
),
),
),
'- '.text.size(28.sp).color(Colors.black.withOpacity(0.85)).make(),
Expanded(
child: GestureDetector(
onTap: () async {
_appointEndDate = await BeeDatePicker.timePicker(DateTime.now());
@ -427,10 +428,12 @@ class _PublishTaskPageState extends State<PublishTaskPage> {
},
child: Material(
color: Colors.transparent,
child:'${_appointEndDate==null ? '请选择结束时间' : DateUtil.formatDate(_appointEndDate, format: 'MM月dd日 HH:mm')}'
child:
'${_appointEndDate == null ? '请选择结束时间' : DateUtil.formatDate(_appointEndDate, format: 'MM月dd日 HH:mm')}'
.text
.size(28.sp)
.color(Colors.black.withOpacity(_appointEndDate == null ? 0.25 : 0.85))
.color(Colors.black
.withOpacity(_appointEndDate == null ? 0.25 : 0.85))
.make(),
),
),
@ -702,7 +705,7 @@ class _PublishTaskPageState extends State<PublishTaskPage> {
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Image.asset(
R.ASSETS_ICONS_ICON_MAIN_LOCATION_PNG,
Assets.icons.iconMainLocation.path,
width: 40.w,
height: 40.w,
color: Colors.black.withOpacity(0.45),
@ -714,7 +717,8 @@ class _PublishTaskPageState extends State<PublishTaskPage> {
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
if(_accessAddress.isEmptyOrNull && _accessAddressDetail.isEmptyOrNull)
if (_accessAddress.isEmptyOrNull &&
_accessAddressDetail.isEmptyOrNull)
'请输入任务地址'
.text
.size(32.sp)
@ -959,10 +963,17 @@ class _PublishTaskPageState extends State<PublishTaskPage> {
.color(Colors.black.withOpacity(0.45))
.make(),
Spacer(),
'建议上传图片不超过6张'
.text
.size(24.sp)
.color(Colors.black.withOpacity(0.25))
.make(),
],
),
24.w.heightBox,
BeePickImageWidget(onChanged: (value) {
BeePickImageWidget(
maxCount: 6,
onChanged: (value) {
_photos = value;
}),
24.w.heightBox,

Loading…
Cancel
Save