Commit 6c512d18 authored by lmj_521aiau@163.com's avatar lmj_521aiau@163.com

1.tabbar

2.UI
parent 58c5ce6e
No preview for this file type
......@@ -1117,11 +1117,11 @@
A9C2B91A24D039B400010EAE /* ZJMineViewController.h */,
A9C2B91624D039B400010EAE /* ZJMineViewController.m */,
A9C2B91324D039B400010EAE /* ZJSettingViewController.h */,
A9C2B91424D039B400010EAE /* ZJEmergencyContactViewController.m */,
A9C2B91524D039B400010EAE /* ZJSelectEmergencyPersonVC.m */,
A9C2B91724D039B400010EAE /* ZJSettingViewController.m */,
A9C2B91824D039B400010EAE /* ZJEmergencyContactViewController.h */,
A9C2B91924D039B400010EAE /* ZJSelectEmergencyPersonVC.h */,
A9C2B91524D039B400010EAE /* ZJSelectEmergencyPersonVC.m */,
A9C2B91824D039B400010EAE /* ZJEmergencyContactViewController.h */,
A9C2B91424D039B400010EAE /* ZJEmergencyContactViewController.m */,
);
path = Controller;
sourceTree = "<group>";
......@@ -1298,6 +1298,7 @@
children = (
A9C2B97D24D039B400010EAE /* UIKitInit.swift */,
A9C2B97524D039B400010EAE /* Constants.swift */,
A9C2B98024D039B400010EAE /* APPTabBar.swift */,
A9C2BA4524D03E9A00010EAE /* Dolphins-Bridging-Header.h */,
A9C2B97E24D039B400010EAE /* BaseTabBarViewController.h */,
A9C2B97724D039B400010EAE /* BaseTabBarViewController.m */,
......@@ -1308,7 +1309,6 @@
A9C2B97A24D039B400010EAE /* BaseModel.m */,
A9C2B97B24D039B400010EAE /* BaseNavigationViewController.h */,
A9C2B97F24D039B400010EAE /* APPNavigationBar.swift */,
A9C2B98024D039B400010EAE /* APPTabBar.swift */,
A9C2B98224D039B400010EAE /* BaseTableViewController.h */,
A9C2B98324D039B400010EAE /* BaseNavigationViewController.m */,
A9C2B98424D039B400010EAE /* BaseHead.h */,
......
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "关心@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "关心@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "底框@2x(1).png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "底框@3x(1).png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "我的@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "我的@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"info" : {
"author" : "xcode",
"version" : 1
}
}
......@@ -5,11 +5,12 @@
"scale" : "1x"
},
{
"filename" : "组 9@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "组 7@3x.png",
"filename" : "组 9@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
......
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "形状 15@2x(1).png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "形状 15@3x(1).png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
......@@ -5,12 +5,12 @@
"scale" : "1x"
},
{
"filename" : "关心@2x.png",
"filename" : "形状 15@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "关心@3x.png",
"filename" : "形状 15@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
......
......@@ -5,12 +5,12 @@
"scale" : "1x"
},
{
"filename" : "我的@2x.png",
"filename" : "形状 17@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "我的@3x.png",
"filename" : "形状 17@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
......
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "形状 17@2x(1).png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "形状 17@3x(1).png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "底框@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "底框@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
......@@ -500,7 +500,7 @@
}
NSMutableDictionary * modelDic = [model dictionaryWithValuesForKeys:@[@"address", @"city", @"latitude", @"longitude", @"time"]].mutableCopy;
[modelDic setDictionary:@{@"power":power}];
[modelDic addEntriesFromDictionary:@{@"power":power}];
NSData *jsonData = [NSJSONSerialization dataWithJSONObject:modelDic options:NSJSONWritingPrettyPrinted error:nil];
NSString * string = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding];
......
......@@ -124,6 +124,28 @@
}
- (void)headerBtnClick:(UIButton *)sender{
// if (![ZJUserInfoManager shared].token) {
// ZJOauthLoginConfig * config = [[ZJOauthLoginConfig alloc] initWithCurrentVC:self];
// [config loginVerify:^(id _Nonnull model) {
// if ([model isKindOfClass:[ZJMineUserInfoModel class]] ) {
// NSLog(@"success");
// }
// } alert:NO];
// return;
// }
if(![ZJUserInfoManager shared].userInfoModel.isMember){
[[ZJGoodsMagager shared] goodsWithVC:self callBack:^(id _Nonnull s) {
[[ZJUserInfoManager shared] updataUserInfo:^(ZJMineUserInfoModel * _Nonnull model) {
} failure:^(id _Nonnull error) {
}];
}];
return;
}
switch (sender.tag-0x64) {
case 0:{
NSDictionary * switchDic = [[self.data Read] objectForKey:@"switch"];
......@@ -135,11 +157,6 @@
}
break;
case 1:{
if (![ZJUserInfoManager shared].isLogin){
[MBProgressHUD showMessage:@"请先进行登陆"];
return;
}
ZJLocationAttentionVC * vc = [ZJLocationAttentionVC new];
[self.navigationController pushViewController:vc animated:YES];
}
......@@ -210,6 +227,17 @@
{
[collectionView deselectItemAtIndexPath:indexPath animated:YES];
if(![ZJUserInfoManager shared].userInfoModel.isMember){
[[ZJGoodsMagager shared] goodsWithVC:self callBack:^(id _Nonnull s) {
[[ZJUserInfoManager shared] updataUserInfo:^(ZJMineUserInfoModel * _Nonnull model) {
} failure:^(id _Nonnull error) {
}];
}];
return;
}
if (indexPath.row == self.dataSource.count - 1) {
ZJAddReminderController *vc = [ZJAddReminderController new];
[self.navigationController pushViewController:vc animated:YES];
......
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="15505" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="16097.2" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="15510"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="16087"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
......@@ -18,14 +18,14 @@
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="remind_cell_Add" translatesAutoresizingMaskIntoConstraints="NO" id="wdg-vm-tUc">
<rect key="frame" x="132.5" y="56.5" width="40" height="40"/>
<rect key="frame" x="131.5" y="55.5" width="42" height="42"/>
<constraints>
<constraint firstAttribute="height" constant="40" id="Cw1-FS-hD9"/>
<constraint firstAttribute="width" constant="40" id="skZ-oG-oDx"/>
<constraint firstAttribute="height" constant="42" id="Cw1-FS-hD9"/>
<constraint firstAttribute="width" constant="42" id="skZ-oG-oDx"/>
</constraints>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="mve-uo-rrt">
<rect key="frame" x="138.5" y="104.5" width="28.5" height="13.5"/>
<rect key="frame" x="138.5" y="105.5" width="28.5" height="13.5"/>
<fontDescription key="fontDescription" type="system" pointSize="11"/>
<color key="textColor" red="0.40000000000000002" green="0.40000000000000002" blue="0.40000000000000002" alpha="1" colorSpace="calibratedRGB"/>
<nil key="highlightedColor"/>
......
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="16097" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="16097.2" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina4_7" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
......@@ -17,13 +17,13 @@
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Psq-qy-gWS">
<rect key="frame" x="0.0" y="417" width="375" height="250"/>
<rect key="frame" x="0.0" y="383" width="375" height="250"/>
<subviews>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="5vU-Px-2bq">
<rect key="frame" x="0.0" y="200" width="375" height="50"/>
<rect key="frame" x="0.0" y="201" width="375" height="49"/>
<color key="backgroundColor" red="0.32156862745098036" green="0.54509803921568623" blue="1" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstAttribute="height" constant="50" id="dZ4-cF-TR1"/>
<constraint firstAttribute="height" constant="49" id="dZ4-cF-TR1"/>
</constraints>
<fontDescription key="fontDescription" type="boldSystem" pointSize="18"/>
<state key="normal" title="确认">
......@@ -34,7 +34,7 @@
</connections>
</button>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="ld4-5g-zWj">
<rect key="frame" x="0.0" y="145" width="375" height="55"/>
<rect key="frame" x="0.0" y="146" width="375" height="55"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="地点备注" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="8aA-rx-erU">
<rect key="frame" x="18" y="18" width="65.5" height="19.5"/>
......@@ -64,14 +64,14 @@
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="9NB-nU-eCb">
<rect key="frame" x="0.0" y="144" width="375" height="1"/>
<rect key="frame" x="0.0" y="145" width="375" height="1"/>
<color key="backgroundColor" red="0.93333333333333335" green="0.93333333333333335" blue="0.93333333333333335" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstAttribute="height" constant="1" id="hGX-HB-grs"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="7p9-7m-NdN">
<rect key="frame" x="0.0" y="68" width="375" height="76"/>
<rect key="frame" x="0.0" y="69" width="375" height="76"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="location_find_current_location_icon" translatesAutoresizingMaskIntoConstraints="NO" id="BmW-Yb-xcu">
<rect key="frame" x="20" y="29" width="15" height="18"/>
......@@ -232,15 +232,25 @@
<constraint firstAttribute="bottom" secondItem="T43-hs-epE" secondAttribute="bottom" id="vfm-6h-yBK"/>
</constraints>
</view>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="0gs-rr-Zbk">
<rect key="frame" x="0.0" y="633" width="375" height="34"/>
<color key="backgroundColor" red="0.32156862745098036" green="0.54509803921568623" blue="1" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstAttribute="height" constant="34" id="CN1-kF-gcp"/>
</constraints>
</view>
</subviews>
<color key="backgroundColor" cocoaTouchSystemColor="groupTableViewBackgroundColor"/>
<constraints>
<constraint firstItem="Psq-qy-gWS" firstAttribute="leading" secondItem="2X8-dr-USg" secondAttribute="leading" id="2Xp-I3-Tgg"/>
<constraint firstItem="2X8-dr-USg" firstAttribute="trailing" secondItem="0gs-rr-Zbk" secondAttribute="trailing" id="EVc-FL-mn7"/>
<constraint firstItem="f1F-Oj-HgK" firstAttribute="top" secondItem="2X8-dr-USg" secondAttribute="top" constant="10" id="OqH-sw-LXP"/>
<constraint firstAttribute="bottom" secondItem="Psq-qy-gWS" secondAttribute="bottom" id="abz-5c-wmM"/>
<constraint firstItem="f1F-Oj-HgK" firstAttribute="leading" secondItem="2X8-dr-USg" secondAttribute="leading" constant="10" id="bIU-4F-zjc"/>
<constraint firstItem="0gs-rr-Zbk" firstAttribute="leading" secondItem="2X8-dr-USg" secondAttribute="leading" id="eWz-gb-esJ"/>
<constraint firstItem="Psq-qy-gWS" firstAttribute="trailing" secondItem="2X8-dr-USg" secondAttribute="trailing" id="fwl-pw-OKg"/>
<constraint firstAttribute="bottom" secondItem="0gs-rr-Zbk" secondAttribute="bottom" id="pVb-kL-opo"/>
<constraint firstItem="2X8-dr-USg" firstAttribute="trailing" secondItem="f1F-Oj-HgK" secondAttribute="trailing" constant="10" id="qnX-QQ-5sc"/>
<constraint firstItem="0gs-rr-Zbk" firstAttribute="top" secondItem="Psq-qy-gWS" secondAttribute="bottom" id="tMt-Y2-gCj"/>
</constraints>
<viewLayoutGuide key="safeArea" id="2X8-dr-USg"/>
</view>
......@@ -248,6 +258,7 @@
<outlet property="addressMainTitleLabel" destination="rYs-Rr-B8q" id="7rC-2m-BOb"/>
<outlet property="addressSubTitleLabel" destination="ZI4-UW-sIm" id="55h-N6-nD1"/>
<outlet property="distanceTipLabel" destination="lWH-a8-J2r" id="WBG-hS-ota"/>
<outlet property="safeBottomConstraint" destination="CN1-kF-gcp" id="vlz-R8-pkf"/>
<outlet property="sliderContainerView" destination="Wt5-Uz-c50" id="FTd-o0-SfH"/>
</connections>
</viewController>
......
......@@ -26,6 +26,7 @@
@property (weak, nonatomic) IBOutlet UILabel *addressMainTitleLabel;
@property (weak, nonatomic) IBOutlet UILabel *addressSubTitleLabel;
@property (weak, nonatomic) IBOutlet UILabel *distanceTipLabel;
@property (weak, nonatomic) IBOutlet NSLayoutConstraint * safeBottomConstraint;
@property (nonatomic, strong) MAPointAnnotation *pointAnnotation;
//@property (nonatomic, strong) AMapSearchAPI *searchApi;
......@@ -109,6 +110,7 @@
self.addressMainTitleLabel.text = _editModel.address;
self.addressSubTitleLabel.text = _editModel.addressName;
_safeBottomConstraint.constant = self.tabBarController.tabBar.frame.size.height-49;
}
//添加固定
......
......@@ -14,6 +14,8 @@ class APPTabBar: UITabBar {
private lazy var centerBtn: UIButton = {
let x = UIButton(type: UIButton.ButtonType.custom)
x.setBackgroundImage(UIImage(named: "icon"), for: UIControl.State.normal)
x.setBackgroundImage(UIImage(named: "icon"), for: UIControl.State.highlighted)
x.setBackgroundImage(UIImage(named: "icon"), for: UIControl.State.selected)
x.addTouch { [weak self] _ in
self?.centerBtnClick?(nil)
}
......@@ -24,7 +26,8 @@ class APPTabBar: UITabBar {
super.init(frame: frame)
// MARK: - 513 改版去掉中心按钮
sd_addSubviews([centerBtn])
centerBtn.sd.centerXEqual(self).topEqual(self).offset(-20).widthIs(76).heightIs(76)
let centerSize = UIImage(named: "icon")!.size
centerBtn.sd.centerXEqual(self).topEqual(self).offset(-33).widthIs(76*centerSize.width/centerSize.height).heightIs(76)
backgroundImage = UIImage(named: "底框(2)")
}
......
......@@ -404,8 +404,12 @@
ZJLocationModel *coordinate = [[ZJLocationModel alloc] init];
coordinate.latitude = [dict[@"lat"] doubleValue]; //[latitude doubleValue];
coordinate.longitude = [dict[@"lon"] doubleValue]; //[longitude doubleValue];
if ([response[@"result"][@"data"][@"lat"] isMemberOfClass:[NSNull class]] || [response[@"result"][@"data"][@"lon"] isMemberOfClass:[NSNull class]]) {
}else{
[_self.locations addObject:coordinate];
}
}
// 去除数组中model重复
for (NSInteger i = 0; i < _self.locations.count; i++) {
......
......@@ -38,7 +38,8 @@
make.top.mas_equalTo(self.view);
make.left.mas_equalTo(self.view);
make.right.mas_equalTo(self.view);
make.height.mas_offset(StatusBarHeight+KScaleWidth(119));
// make.height.mas_offset(StatusBarHeight+KScaleWidth(119));
make.height.mas_offset(KScaleWidth(119));
}];
self.phoneTF = [[UITextField alloc] init];
......@@ -55,7 +56,8 @@
[self.phoneTF addTarget:self action:@selector(changedTextField:) forControlEvents:UIControlEventEditingChanged];
[self.style2BgImV addSubview:self.phoneTF];
[self.phoneTF mas_makeConstraints:^(MASConstraintMaker *make) {
make.top.mas_equalTo(self.style2BgImV).mas_offset(StatusBarHeight+KScaleWidth(19));
make.top.mas_equalTo(self.style2BgImV).mas_offset(KScaleWidth(19));
// make.top.mas_equalTo(self.style2BgImV).mas_offset(StatusBarHeight+KScaleWidth(19));
make.centerX.mas_equalTo(self.style2BgImV);
make.size.mas_offset(CGSizeMake(KScaleWidth(308), KScaleWidth(46)));
}];
......@@ -332,7 +334,8 @@
make.top.mas_equalTo(self.view);
make.left.mas_equalTo(self.view);
make.right.mas_equalTo(self.view);
make.height.mas_offset(StatusBarHeight+KScaleWidth(119));
// make.height.mas_offset(StatusBarHeight+KScaleWidth(119));
make.height.mas_offset(KScaleWidth(119));
}];
} else if (style == 1) {
_hintPrefixLab.text = @"注:";
......@@ -342,7 +345,8 @@
make.top.mas_equalTo(self.view);
make.left.mas_equalTo(self.view);
make.right.mas_equalTo(self.view);
make.height.mas_offset(StatusBarHeight+KScaleWidth(119));
// make.height.mas_offset(StatusBarHeight+KScaleWidth(119));
make.height.mas_offset(KScaleWidth(119));
}];
}else{
_hintPrefixLab.hidden = YES;
......@@ -352,7 +356,8 @@
make.top.mas_equalTo(self.view);
make.left.mas_equalTo(self.view);
make.right.mas_equalTo(self.view);
make.height.mas_offset(StatusBarHeight+KScaleWidth(77));
// make.height.mas_offset(StatusBarHeight+KScaleWidth(77));
make.height.mas_offset(KScaleWidth(77));
}];
}
}
......
......@@ -54,7 +54,7 @@
self.versionLab.sd_layout.centerYEqualToView(self.contentView).rightSpaceToView(self.pushIcon, 4).heightIs(11).widthIs(90);
self.setTitleLabel.sd_layout.centerYEqualToView(self.contentView).leftSpaceToView(self.contentView, 18).heightIs(15).widthIs(120);
self.setTitleLabel.sd_layout.centerYEqualToView(self.contentView).leftSpaceToView(self.contentView, 18).heightIs(15).widthIs(180);
}
......
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