Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
GeliBusinessPlatform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
CI / CD Analytics
Repository Analytics
Value Stream Analytics
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ljy
GeliBusinessPlatform
Commits
3f495093
Commit
3f495093
authored
Dec 31, 2020
by
lujunye
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
整理设置背景色方法
parent
6429fc57
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
34 additions
and
16 deletions
+34
-16
GeliBusinessPlatform.xcworkspace/xcuserdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
...erdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
+0
-0
GeliBusinessPlatform/View/TimeSelectView/DIYCalendarCell.swift
...usinessPlatform/View/TimeSelectView/DIYCalendarCell.swift
+23
-13
GeliBusinessPlatform/View/TimeSelectView/TimeShowDownView.xib
...BusinessPlatform/View/TimeSelectView/TimeShowDownView.xib
+2
-2
GeliBusinessPlatform/ViewController/分销员管理/ADD_FXY_View.swift
GeliBusinessPlatform/ViewController/分销员管理/ADD_FXY_View.swift
+9
-1
No files found.
GeliBusinessPlatform.xcworkspace/xcuserdata/junyelu.xcuserdatad/UserInterfaceState.xcuserstate
View file @
3f495093
No preview for this file type
GeliBusinessPlatform/View/TimeSelectView/DIYCalendarCell.swift
View file @
3f495093
...
@@ -47,15 +47,15 @@ class DIYCalendarCell: FSCalendarCell {
...
@@ -47,15 +47,15 @@ class DIYCalendarCell: FSCalendarCell {
self
.
contentView
.
layer
.
insertSublayer
(
selectionLayer
,
below
:
self
.
titleLabel
!.
layer
)
self
.
contentView
.
layer
.
insertSublayer
(
selectionLayer
,
below
:
self
.
titleLabel
!.
layer
)
self
.
selectionLayer
=
selectionLayer
self
.
selectionLayer
=
selectionLayer
self
.
shapeLayer
.
isHidden
=
true
self
.
shapeLayer
.
isHidden
=
true
//下面代码为添加选中日期背景色
//下面代码为添加选中日期背景色
let
selectionLayer2
=
CAShapeLayer
()
selectionLayer2
.
fillColor
=
color
?
.
cgColor
selectionLayer2
.
actions
=
[
"hidden"
:
NSNull
()]
self
.
contentView
.
layer
.
insertSublayer
(
selectionLayer2
,
below
:
selectionLayer
)
self
.
selectionLayer2
=
selectionLayer2
添加日期别景色1
()
}
}
override
func
layoutSubviews
()
{
override
func
layoutSubviews
()
{
super
.
layoutSubviews
()
super
.
layoutSubviews
()
...
@@ -74,10 +74,9 @@ class DIYCalendarCell: FSCalendarCell {
...
@@ -74,10 +74,9 @@ class DIYCalendarCell: FSCalendarCell {
// self.selectionLayer.path = UIBezierPath(rect: self.selectionLayer.bounds).cgPath
// self.selectionLayer.path = UIBezierPath(rect: self.selectionLayer.bounds).cgPath
//下面代码为添加选中日期背景色
//下面代码为添加选中日期背景色
self
.
selectionLayer
.
fillColor
=
UIColor
(
named
:
"#E0EEFF"
)?
.
cgColor
let
bounds
=
CGRect
(
x
:
0
,
y
:
2
,
width
:
self
.
selectionLayer
.
bounds
.
size
.
width
,
height
:
self
.
selectionLayer
.
bounds
.
height
-
8
)
self
.
selectionLayer
.
path
=
UIBezierPath
(
rect
:
bounds
)
.
cgPath
let
bounds
=
CGRect
(
x
:
0
,
y
:
2
,
width
:
self
.
selectionLayer
.
bounds
.
size
.
width
,
height
:
self
.
selectionLayer
.
bounds
.
height
-
8
)
添加日期背景色2
(
shaper
:
self
.
selectionLayer
,
rect
:
bounds
,
color
:
UIColor
(
named
:
"#E0EEFF"
)
!
)
}
}
else
if
selectionType
==
.
leftBorder
{
else
if
selectionType
==
.
leftBorder
{
self
.
titleLabel
.
textColor
=
UIColor
.
white
self
.
titleLabel
.
textColor
=
UIColor
.
white
...
@@ -87,9 +86,9 @@ class DIYCalendarCell: FSCalendarCell {
...
@@ -87,9 +86,9 @@ class DIYCalendarCell: FSCalendarCell {
//下面代码为添加选中日期背景色
//下面代码为添加选中日期背景色
let
bounds
=
CGRect
(
x
:
self
.
selectionLayer2
.
bounds
.
size
.
width
*
0.5
,
y
:
2
,
width
:
self
.
selectionLayer2
.
bounds
.
size
.
width
,
height
:
self
.
selectionLayer2
.
bounds
.
height
-
8
)
let
bounds
=
CGRect
(
x
:
self
.
selectionLayer2
.
bounds
.
size
.
width
*
0.5
,
y
:
2
,
width
:
self
.
selectionLayer2
.
bounds
.
size
.
width
,
height
:
self
.
selectionLayer2
.
bounds
.
height
-
8
)
self
.
selectionLayer2
.
fillColor
=
UIColor
(
named
:
"#E0EEFF"
)?
.
cgColor
//
self.selectionLayer2.fillColor = UIColor(named: "#E0EEFF")?.cgColor
self
.
selectionLayer2
.
path
=
UIBezierPath
(
rect
:
bounds
)
.
cgPath
//
self.selectionLayer2.path = UIBezierPath(rect: bounds).cgPath
添加日期背景色2
(
shaper
:
self
.
selectionLayer2
,
rect
:
bounds
,
color
:
UIColor
(
named
:
"#E0EEFF"
)
!
)
print
(
"leftBorder--leftBorder"
)
print
(
"leftBorder--leftBorder"
)
}
}
else
if
selectionType
==
.
rightBorder
{
else
if
selectionType
==
.
rightBorder
{
...
@@ -100,8 +99,7 @@ class DIYCalendarCell: FSCalendarCell {
...
@@ -100,8 +99,7 @@ class DIYCalendarCell: FSCalendarCell {
//下面代码为添加选中日期背景色
//下面代码为添加选中日期背景色
let
bounds
=
CGRect
(
x
:
0
,
y
:
2
,
width
:
self
.
selectionLayer2
.
bounds
.
size
.
width
*
0.5
,
height
:
self
.
selectionLayer2
.
bounds
.
height
-
8
)
let
bounds
=
CGRect
(
x
:
0
,
y
:
2
,
width
:
self
.
selectionLayer2
.
bounds
.
size
.
width
*
0.5
,
height
:
self
.
selectionLayer2
.
bounds
.
height
-
8
)
self
.
selectionLayer2
.
fillColor
=
UIColor
(
named
:
"#E0EEFF"
)?
.
cgColor
添加日期背景色2
(
shaper
:
self
.
selectionLayer2
,
rect
:
bounds
,
color
:
UIColor
(
named
:
"#E0EEFF"
)
!
)
self
.
selectionLayer2
.
path
=
UIBezierPath
(
rect
:
bounds
)
.
cgPath
}
else
if
selectionType
==
.
single
{
}
else
if
selectionType
==
.
single
{
self
.
selectionLayer
.
fillColor
=
UIColor
.
init
(
named
:
"蓝色字体颜色"
)?
.
cgColor
self
.
selectionLayer
.
fillColor
=
UIColor
.
init
(
named
:
"蓝色字体颜色"
)?
.
cgColor
...
@@ -115,6 +113,18 @@ class DIYCalendarCell: FSCalendarCell {
...
@@ -115,6 +113,18 @@ class DIYCalendarCell: FSCalendarCell {
}
}
}
}
func
添加日期别景色1
(){
let
selectionLayer2
=
CAShapeLayer
()
selectionLayer2
.
fillColor
=
UIColor
(
named
:
"蓝色字体颜色"
)?
.
cgColor
selectionLayer2
.
actions
=
[
"hidden"
:
NSNull
()]
self
.
contentView
.
layer
.
insertSublayer
(
selectionLayer2
,
below
:
selectionLayer
)
self
.
selectionLayer2
=
selectionLayer2
}
func
添加日期背景色2
(
shaper
:
CAShapeLayer
,
rect
:
CGRect
,
color
:
UIColor
){
shaper
.
fillColor
=
color
.
cgColor
shaper
.
path
=
UIBezierPath
(
rect
:
rect
)
.
cgPath
}
override
func
configureAppearance
()
{
override
func
configureAppearance
()
{
super
.
configureAppearance
()
super
.
configureAppearance
()
}
}
...
...
GeliBusinessPlatform/View/TimeSelectView/TimeShowDownView.xib
View file @
3f495093
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<document
type=
"com.apple.InterfaceBuilder3.CocoaTouch.XIB"
version=
"3.0"
toolsVersion=
"17
156
"
targetRuntime=
"iOS.CocoaTouch"
propertyAccessControl=
"none"
useAutolayout=
"YES"
useTraitCollections=
"YES"
useSafeAreas=
"YES"
colorMatched=
"YES"
>
<document
type=
"com.apple.InterfaceBuilder3.CocoaTouch.XIB"
version=
"3.0"
toolsVersion=
"17
701
"
targetRuntime=
"iOS.CocoaTouch"
propertyAccessControl=
"none"
useAutolayout=
"YES"
useTraitCollections=
"YES"
useSafeAreas=
"YES"
colorMatched=
"YES"
>
<device
id=
"retina6_1"
orientation=
"portrait"
appearance=
"light"
/>
<device
id=
"retina6_1"
orientation=
"portrait"
appearance=
"light"
/>
<dependencies>
<dependencies>
<deployment
identifier=
"iOS"
/>
<deployment
identifier=
"iOS"
/>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"17
126
"
/>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"17
703
"
/>
<capability
name=
"Named colors"
minToolsVersion=
"9.0"
/>
<capability
name=
"Named colors"
minToolsVersion=
"9.0"
/>
<capability
name=
"Safe area layout guides"
minToolsVersion=
"9.0"
/>
<capability
name=
"Safe area layout guides"
minToolsVersion=
"9.0"
/>
<capability
name=
"System colors in document resources"
minToolsVersion=
"11.0"
/>
<capability
name=
"System colors in document resources"
minToolsVersion=
"11.0"
/>
...
...
GeliBusinessPlatform/ViewController/分销员管理/ADD_FXY_View.swift
View file @
3f495093
...
@@ -21,6 +21,7 @@ class ADD_FXY_View: UIView {
...
@@ -21,6 +21,7 @@ class ADD_FXY_View: UIView {
}
}
var
temp
=
""
var
temp
=
""
// var temp2 = ""
@objc
func
textChange
(
tf
:
UITextField
){
@objc
func
textChange
(
tf
:
UITextField
){
if
tf
==
phoneTf
{
if
tf
==
phoneTf
{
if
tf
.
text
!.
count
<=
11
{
if
tf
.
text
!.
count
<=
11
{
...
@@ -35,7 +36,14 @@ class ADD_FXY_View: UIView {
...
@@ -35,7 +36,14 @@ class ADD_FXY_View: UIView {
nameTf
.
text
=
""
nameTf
.
text
=
""
nameTf
.
isUserInteractionEnabled
=
false
nameTf
.
isUserInteractionEnabled
=
false
}
}
delegate
?
.
ADD_FXY_ViewTextInput
(
txt
:
tf
.
text
!
,
type
:
2
,
view
:
self
)
// if tf.text?.containsEmoji {
// HUD.flash(.label("请输入非表情符号"), delay: 1.2)
// tf.text = temp2
// return
// }else{
// temp2 = tf.text
// }
delegate
?
.
ADD_FXY_ViewTextInput
(
txt
:
nameTf
.
text
!
,
type
:
2
,
view
:
self
)
}
}
}
}
@IBAction
func
finish_action
(
_
sender
:
UIButton
)
{
@IBAction
func
finish_action
(
_
sender
:
UIButton
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment