From 95f6b96c4eb4866f031f8dfd9603596ecebe61e2 Mon Sep 17 00:00:00 2001 From: adam Date: Mon, 30 May 2022 16:13:32 +0800 Subject: [PATCH] =?UTF-8?q?=E6=97=A5=E7=A8=8B=E7=AE=A1=E7=90=86=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../core/widget/calendar/CustomMonthView.java | 9 +- .../core/widget/calendar/CustomWeekView.java | 13 +- .../res/drawable-xhdpi/ic_arrow_right_60.png | Bin 0 -> 207 bytes .../main/res/drawable-xhdpi/ic_off_normal.png | Bin 0 -> 1080 bytes .../src/main/res/drawable-xhdpi/ic_on_sel.png | Bin 0 -> 1471 bytes .../shape_btn_nomal_gray_deep_round.xml | 2 +- .../drawable/switch_ios_track_selector.xml | 4 +- .../res/layout/layout_base_search_cancel.xml | 36 ++- baselib/src/main/res/values/colors.xml | 3 +- .../schedule/ScheduleAddActivity.java | 25 +- .../schedule/ScheduleDetailActivity.java | 1 + .../schedule/ScheduleEditActivity.java | 1 + .../schedule/ScheduleSearchActivity.java | 1 + .../src/main/res/layout/activity_schedule.xml | 205 +++++++++-------- .../main/res/layout/activity_schedule_add.xml | 163 ++++++++----- .../res/layout/activity_schedule_detail.xml | 29 ++- .../res/layout/activity_schedule_edit.xml | 214 ++++++++++++------ .../res/layout/activity_schedule_search.xml | 2 +- .../src/main/res/layout/item_schedule.xml | 1 + 19 files changed, 441 insertions(+), 268 deletions(-) create mode 100644 baselib/src/main/res/drawable-xhdpi/ic_arrow_right_60.png create mode 100644 baselib/src/main/res/drawable-xhdpi/ic_off_normal.png create mode 100644 baselib/src/main/res/drawable-xhdpi/ic_on_sel.png diff --git a/baselib/src/main/java/com/tenlionsoft/baselib/core/widget/calendar/CustomMonthView.java b/baselib/src/main/java/com/tenlionsoft/baselib/core/widget/calendar/CustomMonthView.java index 023fc50..d639a40 100644 --- a/baselib/src/main/java/com/tenlionsoft/baselib/core/widget/calendar/CustomMonthView.java +++ b/baselib/src/main/java/com/tenlionsoft/baselib/core/widget/calendar/CustomMonthView.java @@ -8,6 +8,7 @@ import android.text.TextUtils; import com.haibin.calendarview.Calendar; import com.haibin.calendarview.MonthView; +import com.tenlionsoft.baselib.utils.LogUtils; /** * 演示一个变态需求的月视图 @@ -117,7 +118,7 @@ public class CustomMonthView extends MonthView { if (isSelected) { mPointPaint.setColor(Color.WHITE); } else { - mPointPaint.setColor(Color.GRAY); + mPointPaint.setColor(Color.parseColor("#0052D9")); } canvas.drawCircle(x + mItemWidth / 2, y + mItemHeight - 3 * mPadding, mPointRadius, mPointPaint); @@ -133,11 +134,11 @@ public class CustomMonthView extends MonthView { if (calendar.isCurrentDay() && !isSelected) { canvas.drawCircle(cx, cy, mRadius, mCurrentDayPaint); } - + LogUtils.e("是否有Scheme==" + hasScheme); if (hasScheme) { // canvas.drawCircle(x + mItemWidth - mPadding - mCircleRadius / 2, y + mPadding + mCircleRadius, mCircleRadius, mSchemeBasicPaint); - mTextPaint.setColor(calendar.getSchemeColor()); - canvas.drawText(calendar.getScheme(), x + mItemWidth - mPadding - mCircleRadius, y + mPadding + mSchemeBaseLine, mTextPaint); +// mTextPaint.setColor(calendar.getSchemeColor()); +// canvas.drawText(calendar.getScheme(), x + mItemWidth - mPadding - mCircleRadius, y + mPadding + mSchemeBaseLine, mTextPaint); } //当然可以换成其它对应的画笔就不麻烦, diff --git a/baselib/src/main/java/com/tenlionsoft/baselib/core/widget/calendar/CustomWeekView.java b/baselib/src/main/java/com/tenlionsoft/baselib/core/widget/calendar/CustomWeekView.java index f69881d..2d9641e 100644 --- a/baselib/src/main/java/com/tenlionsoft/baselib/core/widget/calendar/CustomWeekView.java +++ b/baselib/src/main/java/com/tenlionsoft/baselib/core/widget/calendar/CustomWeekView.java @@ -78,7 +78,7 @@ public class CustomWeekView extends WeekView { mPointPaint.setAntiAlias(true); mPointPaint.setStyle(Paint.Style.FILL); mPointPaint.setTextAlign(Paint.Align.CENTER); - mPointPaint.setColor(Color.RED); + mPointPaint.setColor(Color.parseColor("#0052D9")); mCurrentDayPaint.setAntiAlias(true); @@ -121,7 +121,7 @@ public class CustomWeekView extends WeekView { if (isSelected) { mPointPaint.setColor(Color.WHITE); } else { - mPointPaint.setColor(Color.GRAY); + mPointPaint.setColor(Color.BLUE); } canvas.drawCircle(x + mItemWidth / 2, mItemHeight - 3 * mPadding, mPointRadius, mPointPaint); @@ -139,11 +139,12 @@ public class CustomWeekView extends WeekView { } if (hasScheme) { + //绘制文字 // canvas.drawCircle(x + mItemWidth - mPadding - mCircleRadius / 2, mPadding + mCircleRadius, mCircleRadius, mSchemeBasicPaint); - - mTextPaint.setColor(calendar.getSchemeColor()); - - canvas.drawText(calendar.getScheme(), x + mItemWidth - mPadding - mCircleRadius, mPadding + mSchemeBaseLine, mTextPaint); +// +// mTextPaint.setColor(calendar.getSchemeColor()); +// +// canvas.drawText(calendar.getScheme(), x + mItemWidth - mPadding - mCircleRadius, mPadding + mSchemeBaseLine, mTextPaint); } if (calendar.isWeekend() && calendar.isCurrentMonth()) { diff --git a/baselib/src/main/res/drawable-xhdpi/ic_arrow_right_60.png b/baselib/src/main/res/drawable-xhdpi/ic_arrow_right_60.png new file mode 100644 index 0000000000000000000000000000000000000000..b29c2ff1d1a16a3bb776f0e8608be73fa8ed3b92 GIT binary patch literal 207 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKx3?xrnI^qbV2 z!FpJ1!?s6L&4i2&D4$-Zv7*O)R%C#{`Z9ONJ+~s=wq6d{Z6%kf?C2PHXVaOkrY61$ z)9#+EWwX-4{>+N}n8kL~MD8pPPtN5JC;OOIF*2l!@Sm%3^#2RAfx*+&&t;ucLK6V! Cr%^Zn literal 0 HcmV?d00001 diff --git a/baselib/src/main/res/drawable-xhdpi/ic_off_normal.png b/baselib/src/main/res/drawable-xhdpi/ic_off_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..89e76bbdb6a99519bd3c0af32e84300bc8539db6 GIT binary patch literal 1080 zcmeAS@N?(olHy`uVBq!ia0vp^UO=qM!3-oXt?54lq!^2X+?^P2p46!aaySb-B8wRq z6fHoQ(RG?(0#HFffKP}kQ1ThI!RyzrKYaM``Sa(mU%$S8|NhmhS8yAiKY#w`&!7MQ z|Nr{+>)pF|aB(2x<;$0!K7IQ8_b-tB^XJcR-@d(g@dB>k?c2A%fB*jR;|E*>$oTT* z3y}Qx?;k|)`}gl~**9iLRd;F?5*RzTa$b=YePJNI`YFqS%Tnq+XKvVDh@NTBz`(@n z>EaktF=y?xm(jNz1dg>gf*ou_jgH$ zFsc0B^Xo_5jI(+3{@PkkK6^%>Qe>BKUr7m<<=JYLn)V~;+ZPe8*)ww+o;|zjRi=16 zF4adwtg_%~>?u{nr2{_i}(mJ(zs)LBsy3j@GvPCs=9!Y))E6$03 z3F52d?ev!LYI!+zi>GYYb%QI}Rmy9Zx;Dy%WyaoGFgqYz^2>yfW!(Sjyv(|S+`JD3 z9(%jcY{|#plk){u=Plg7@C=_@*TrR9qNA>uv{iY(Uvl=9hvkL+-@iOuER(}~iYah@ zhu!IgD=b4~lxsN!d5^W|ec(=bcYE4Tt-V?%oU2*Fy1uU0QttQbYS2>jOo&?XZbxcT zxxeqWKj%UFVdQ&MBb@036qi!2kdN literal 0 HcmV?d00001 diff --git a/baselib/src/main/res/drawable-xhdpi/ic_on_sel.png b/baselib/src/main/res/drawable-xhdpi/ic_on_sel.png new file mode 100644 index 0000000000000000000000000000000000000000..4ea4a05f2ec95abe8b3c403caff3cf02ca5ab088 GIT binary patch literal 1471 zcmb_ceKeF=7@v_r+R<)k(XouvaicKqrw5@!hCDL)%pL`z z0dPp?klgy&PbwtFVch*W6FnpI3rm`cClZ&_qcCU^&ds_l6v@@x$;F*nW1sS|5yKB( z&S^AYZXP*#{ln!4;*T*SVgVe3=sI7*JxC`)Ody6R%C{q#rK| z_`)T_!}>mNKa+Wr#-SvVBUMkOx}3?`C4&(C7fZh>T=(5aM3P$3}ro{?GCt1agum)9y_e9WLRBOy4hapiT zAhc)_lKDkVW{q$~=)XJVko1l_xj=p>Ha?>7)+%n~E=#6RAqiLYuLBD$qIs!RGa?1j z%~L@aPV;Eq>8csI3h5eF`Q=W)h-o-CAa5f3&c{Z!ob^`8;i=mCl$B2;X|x$#$$wy@ zEq5Fqp>`qxAA&O2N9meEfM)h}O}Mew?_(1BA?q6|b(_lyu6C1`$4r)~p4AzdRO;y3 zWy8QG>J_lN39?~xts4)(3k^_83xmFIj$!34RpWaaBo&2y)(*0S<-p|(~MHC*)o_V7BJ3kT7Tm2 zw5a#V)GXEaiGSXA-)FHlV0FE-OO&_&GJ6B1zy(OF0 zzj?Fs30F07@$yY;{M0?Z!?xT#_aj9nU1cb*A&0co_#?9Yw~X1cRk&BvxX*3e&qR9E z5Vk)J#}0o@eA$aR=xDy_#T_!fcM?afEh;zY?frqd^H^yrml%Jv&+EPI{H3d$i+P^z zPAv(H&+y4>JzI;1ej`_euvm}e*A5!J?NehqOUbLgl#VeHx(fZ@u@Xwj0WDGc9&9(O zrdU!#y3gaDGiYVkHil6H2u+hlPK_Nk9Hv*2ZAL>a*6Q%BD-)f^?A4+9!Pg&(i$ON-D}RcsF*?;}q$d>~80dI64zs{aoN=L|7O&8Tpu0EtjND<-X~OaAQc7 zwvHGssI1F4MN1cJa{cP6A5rq{cAHizF!40UulAg^$+@vhRoC2JBoXG<_LRhKjcz5$ zl|QkUR@)T~JldkJ;(oKCu?(%)W=?(S933l4x-r8TEwP~_A9^2`eE!=#B#msmcszq| c7ckhDjs9W>ym|iMc4_Zfe_y;$6D}s_AIi`gcK`qY literal 0 HcmV?d00001 diff --git a/baselib/src/main/res/drawable/shape_btn_nomal_gray_deep_round.xml b/baselib/src/main/res/drawable/shape_btn_nomal_gray_deep_round.xml index b824ce4..9836ee3 100755 --- a/baselib/src/main/res/drawable/shape_btn_nomal_gray_deep_round.xml +++ b/baselib/src/main/res/drawable/shape_btn_nomal_gray_deep_round.xml @@ -1,6 +1,6 @@ - + \ No newline at end of file diff --git a/baselib/src/main/res/drawable/switch_ios_track_selector.xml b/baselib/src/main/res/drawable/switch_ios_track_selector.xml index 1a459e3..497d160 100755 --- a/baselib/src/main/res/drawable/switch_ios_track_selector.xml +++ b/baselib/src/main/res/drawable/switch_ios_track_selector.xml @@ -1,5 +1,5 @@ - - + + \ No newline at end of file diff --git a/baselib/src/main/res/layout/layout_base_search_cancel.xml b/baselib/src/main/res/layout/layout_base_search_cancel.xml index 855e8ab..67609eb 100644 --- a/baselib/src/main/res/layout/layout_base_search_cancel.xml +++ b/baselib/src/main/res/layout/layout_base_search_cancel.xml @@ -11,20 +11,36 @@ android:paddingBottom="3dp"> - + android:gravity="center_vertical" + android:orientation="horizontal" + android:padding="7dp"> + + + + + \ No newline at end of file diff --git a/baselib/src/main/res/values/colors.xml b/baselib/src/main/res/values/colors.xml index 7fea7d2..31d5b63 100755 --- a/baselib/src/main/res/values/colors.xml +++ b/baselib/src/main/res/values/colors.xml @@ -44,7 +44,7 @@ #bb8E8E8E #535353 #7C7C7C - #00A6FE + #3F86FF #3300A6FE #00BEF7 #808080 @@ -69,6 +69,7 @@ #FF84A9 #000000 + #101010 #AA000000 #FBFBFB diff --git a/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleAddActivity.java b/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleAddActivity.java index 84d0e34..d64a4f7 100644 --- a/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleAddActivity.java +++ b/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleAddActivity.java @@ -5,7 +5,6 @@ import android.graphics.Color; import android.text.TextUtils; import android.widget.Button; import android.widget.CheckBox; -import android.widget.CompoundButton; import android.widget.EditText; import android.widget.ImageView; import android.widget.TextView; @@ -27,7 +26,6 @@ import com.tenlionsoft.baselib.utils.ExceptionHandler; import com.tenlionsoft.baselib.utils.LogUtils; import com.tenlionsoft.baselib.utils.TimeUtils; import com.tenlionsoft.baselib.utils.UIUtil; -import com.tenlionsoft.baselib.utils.UserLgUtils; import com.tenlionsoft.oamodule.R; import com.tenlionsoft.oamodule.R2; import com.tenlionsoft.oamodule.beans.SaveScheduleBean; @@ -101,7 +99,8 @@ public class ScheduleAddActivity extends BaseActivity { @Override public void initData() { ButterKnife.bind(this); - mTvBaseTitle.setText("日程添加"); + mTvBaseTitle.setText("新建日程"); + mRlTitleBar.setBackgroundColor(mActivity.getResources().getColor(R.color.gray_f8)); refreshView(STATE_LOAD_SUCCESS); initView(); } @@ -188,16 +187,16 @@ public class ScheduleAddActivity extends BaseActivity { case 2: //判断时间大小 String start = mTvStartTime.getText().toString().trim(); - if(!TextUtils.isEmpty(start)){ - int span = TimeUtils.compareDate(date, TimeUtils.string2Date(start)); - if (span >= 0) { - mTvEndTime.setText(TimeUtils.date2String(date)); - } else { - ToastUtils.show("结束时间须大于开始时间"); - } - }else{ - ToastUtils.show("请选择开始时间"); - } + if (!TextUtils.isEmpty(start)) { + int span = TimeUtils.compareDate(date, TimeUtils.string2Date(start)); + if (span >= 0) { + mTvEndTime.setText(TimeUtils.date2String(date)); + } else { + ToastUtils.show("结束时间须大于开始时间"); + } + } else { + ToastUtils.show("请选择开始时间"); + } break; } }) diff --git a/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleDetailActivity.java b/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleDetailActivity.java index 6066612..ea1ded3 100644 --- a/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleDetailActivity.java +++ b/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleDetailActivity.java @@ -75,6 +75,7 @@ public class ScheduleDetailActivity extends BaseActivity { public void initData() { ButterKnife.bind(this); mTvBaseTitle.setText("详情"); + mRlTitleBar.setBackgroundColor(getResources().getColor(R.color.gray_f8)); mId = getIntent().getStringExtra("id"); if (TextUtils.isEmpty(mId)) { ToastUtils.show("数据有误"); diff --git a/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleEditActivity.java b/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleEditActivity.java index a5df2cf..02623e6 100644 --- a/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleEditActivity.java +++ b/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleEditActivity.java @@ -97,6 +97,7 @@ public class ScheduleEditActivity extends BaseActivity { public void initData() { ButterKnife.bind(this); mTvBaseTitle.setText("日程编辑"); + mRlTitleBar.setBackgroundColor(getResources().getColor(R.color.gray_f8)); mId = getIntent().getStringExtra("id"); initView(); if (TextUtils.isEmpty(mId)) { diff --git a/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleSearchActivity.java b/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleSearchActivity.java index 9abd158..183e47b 100644 --- a/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleSearchActivity.java +++ b/oamodule/src/main/java/com/tenlionsoft/oamodule/activity/schedule/ScheduleSearchActivity.java @@ -75,6 +75,7 @@ public class ScheduleSearchActivity extends BaseActivity { @Override public void initData() { mBind = ButterKnife.bind(this); + mRlTitleBar.setBackgroundColor(getResources().getColor(R.color.gray_f8)); refreshView(STATE_LOAD_SUCCESS); mTvBaseTitle.setText("日程搜索"); initView(); diff --git a/oamodule/src/main/res/layout/activity_schedule.xml b/oamodule/src/main/res/layout/activity_schedule.xml index b352727..be7c854 100644 --- a/oamodule/src/main/res/layout/activity_schedule.xml +++ b/oamodule/src/main/res/layout/activity_schedule.xml @@ -90,106 +90,123 @@ android:layout_marginLeft="10dp" android:layout_marginRight="10dp" android:background="@color/white" - android:gravity="center_vertical" - android:orientation="horizontal" - android:padding="5dp"> + android:orientation="vertical"> - + + + android:orientation="horizontal" + android:padding="7dp"> - + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - + android:layout_marginRight="10dp" + android:background="#E7E7E7" /> @@ -208,8 +225,8 @@ android:id="@+id/calendarView" android:layout_width="match_parent" android:layout_height="wrap_content" - app:current_day_lunar_text_color="#ff0000" - app:current_day_text_color="#ff0000" + app:current_day_lunar_text_color="#8C8C8C" + app:current_day_text_color="#8C8C8C" app:current_month_lunar_text_color="#8C8C8C" app:current_month_text_color="#333333" app:lunar_text_size="10sp" @@ -228,12 +245,12 @@ app:scheme_text="" app:scheme_text_color="#333" app:scheme_theme_color="#8C8C8C" - app:selected_lunar_text_color="#8C8C8C" - app:selected_text_color="#8C8C8C" + app:selected_lunar_text_color="#2158F9" + app:selected_text_color="#2158F9" app:selected_theme_color="#00000000" app:week_background="#ffffff" app:week_bar_height="46dp" - app:week_line_background="#00000000" + app:week_line_background="#FFFFFF" app:week_line_margin="16dp" app:week_start_with="sun" app:week_text_color="#111111" diff --git a/oamodule/src/main/res/layout/activity_schedule_add.xml b/oamodule/src/main/res/layout/activity_schedule_add.xml index 837cdbd..e2c1b1b 100644 --- a/oamodule/src/main/res/layout/activity_schedule_add.xml +++ b/oamodule/src/main/res/layout/activity_schedule_add.xml @@ -3,7 +3,7 @@ xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="match_parent" - android:background="@color/gray_f0" + android:background="@color/gray_f2" android:orientation="vertical"> + android:textColor="@color/black_10" + android:textSize="@dimen/text_14" /> + android:textSize="@dimen/text_14" /> @@ -56,7 +56,7 @@ android:layout_height="wrap_content" android:layout_gravity="center_vertical" android:text="日程类型" - android:textColor="@color/black" + android:textColor="@color/black_10" android:textSize="14sp" /> + android:text="站内" + android:textColor="@color/col_blue_gray" /> + android:text="短信" + android:textColor="@color/col_blue_gray" /> + android:text="邮件" + android:textColor="@color/col_blue_gray" /> @@ -141,21 +144,34 @@ android:layout_height="wrap_content" android:layout_gravity="center_vertical" android:text="开始时间" - android:textColor="@color/black" + android:textColor="@color/black_10" android:textSize="14sp" /> - + android:gravity="center_vertical" + android:orientation="horizontal"> + + + + + @@ -165,21 +181,33 @@ android:layout_height="wrap_content" android:layout_gravity="center_vertical" android:text="结束时间" - android:textColor="@color/black" + android:textColor="@color/black_10" android:textSize="14sp" /> - + android:gravity="center_vertical" + android:orientation="horizontal"> + + + + + @@ -190,21 +218,34 @@ android:layout_height="wrap_content" android:layout_gravity="center_vertical" android:text="提前提醒" - android:textColor="@color/black" + android:textColor="@color/black_10" android:textSize="14sp" /> - + android:gravity="center_vertical" + android:orientation="horizontal"> + + + + + @@ -214,7 +255,7 @@ android:layout_height="wrap_content" android:layout_gravity="center_vertical" android:text="是否公开" - android:textColor="@color/black" + android:textColor="@color/black_10" android:textSize="14sp" /> - + android:gravity="center_vertical" + android:orientation="horizontal"> + + + + + + diff --git a/oamodule/src/main/res/layout/activity_schedule_detail.xml b/oamodule/src/main/res/layout/activity_schedule_detail.xml index be00f8f..bce2393 100644 --- a/oamodule/src/main/res/layout/activity_schedule_detail.xml +++ b/oamodule/src/main/res/layout/activity_schedule_detail.xml @@ -3,18 +3,20 @@ xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="match_parent" + android:background="@color/gray_f2" android:orientation="vertical"> @@ -33,7 +35,7 @@ android:layout_height="wrap_content" android:layout_gravity="center_vertical" android:text="日程内容" - android:textColor="@color/black" + android:textColor="@color/black_10" android:textSize="14sp" /> + android:text="站内" + android:textColor="@color/col_blue_gray" /> + android:text="短信" + android:textColor="@color/col_blue_gray" /> + android:text="邮件" + android:textColor="@color/col_blue_gray" /> @@ -137,7 +142,7 @@ android:layout_height="wrap_content" android:layout_gravity="center_vertical" android:text="开始时间" - android:textColor="@color/black" + android:textColor="@color/black_10" android:textSize="14sp" /> @@ -58,30 +60,33 @@ android:textColor="@color/black" android:textSize="14sp" /> - -