refs #4904 Code clean, URL changed to shop

This commit is contained in:
Sergio De la torre 2023-04-27 14:15:01 +02:00
parent e841a88215
commit 6db9617fd5
12 changed files with 77 additions and 449 deletions

BIN
.DS_Store vendored

Binary file not shown.

1
.gitignore vendored
View File

@ -0,0 +1 @@
.DS_Store

View File

@ -1,348 +0,0 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 50;
objects = {
/* Begin PBXBuildFile section */
EBC33AA22595B47600CD89D7 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = EBC33AA12595B47600CD89D7 /* AppDelegate.swift */; };
EBC33AA62595B47600CD89D7 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = EBC33AA52595B47600CD89D7 /* ViewController.swift */; };
EBC33AA92595B47600CD89D7 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = EBC33AA72595B47600CD89D7 /* Main.storyboard */; };
EBC33AAB2595B47900CD89D7 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = EBC33AAA2595B47900CD89D7 /* Assets.xcassets */; };
EBC33AAE2595B47900CD89D7 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = EBC33AAC2595B47900CD89D7 /* LaunchScreen.storyboard */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
EBC33A9E2595B47600CD89D7 /* Verdnatura.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Verdnatura.app; sourceTree = BUILT_PRODUCTS_DIR; };
EBC33AA12595B47600CD89D7 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
EBC33AA52595B47600CD89D7 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = "<group>"; };
EBC33AA82595B47600CD89D7 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
EBC33AAA2595B47900CD89D7 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
EBC33AAD2595B47900CD89D7 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
EBC33AAF2595B47900CD89D7 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
EBC33A9B2595B47600CD89D7 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
EBC33A952595B47600CD89D7 = {
isa = PBXGroup;
children = (
EBC33AA02595B47600CD89D7 /* Verdnatura */,
EBC33A9F2595B47600CD89D7 /* Products */,
);
sourceTree = "<group>";
};
EBC33A9F2595B47600CD89D7 /* Products */ = {
isa = PBXGroup;
children = (
EBC33A9E2595B47600CD89D7 /* Verdnatura.app */,
);
name = Products;
sourceTree = "<group>";
};
EBC33AA02595B47600CD89D7 /* Verdnatura */ = {
isa = PBXGroup;
children = (
EBC33AA12595B47600CD89D7 /* AppDelegate.swift */,
EBC33AA52595B47600CD89D7 /* ViewController.swift */,
EBC33AA72595B47600CD89D7 /* Main.storyboard */,
EBC33AAA2595B47900CD89D7 /* Assets.xcassets */,
EBC33AAC2595B47900CD89D7 /* LaunchScreen.storyboard */,
EBC33AAF2595B47900CD89D7 /* Info.plist */,
);
path = Verdnatura;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
EBC33A9D2595B47600CD89D7 /* Verdnatura */ = {
isa = PBXNativeTarget;
buildConfigurationList = EBC33AB22595B47900CD89D7 /* Build configuration list for PBXNativeTarget "Verdnatura" */;
buildPhases = (
EBC33A9A2595B47600CD89D7 /* Sources */,
EBC33A9B2595B47600CD89D7 /* Frameworks */,
EBC33A9C2595B47600CD89D7 /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = Verdnatura;
productName = Verdnatura;
productReference = EBC33A9E2595B47600CD89D7 /* Verdnatura.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
EBC33A962595B47600CD89D7 /* Project object */ = {
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 1210;
LastUpgradeCheck = 1210;
TargetAttributes = {
EBC33A9D2595B47600CD89D7 = {
CreatedOnToolsVersion = 12.1;
};
};
};
buildConfigurationList = EBC33A992595B47600CD89D7 /* Build configuration list for PBXProject "Verdnatura" */;
compatibilityVersion = "Xcode 9.3";
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = EBC33A952595B47600CD89D7;
productRefGroup = EBC33A9F2595B47600CD89D7 /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
EBC33A9D2595B47600CD89D7 /* Verdnatura */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
EBC33A9C2595B47600CD89D7 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
EBC33AAE2595B47900CD89D7 /* LaunchScreen.storyboard in Resources */,
EBC33AAB2595B47900CD89D7 /* Assets.xcassets in Resources */,
EBC33AA92595B47600CD89D7 /* Main.storyboard in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
EBC33A9A2595B47600CD89D7 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
EBC33AA62595B47600CD89D7 /* ViewController.swift in Sources */,
EBC33AA22595B47600CD89D7 /* AppDelegate.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXVariantGroup section */
EBC33AA72595B47600CD89D7 /* Main.storyboard */ = {
isa = PBXVariantGroup;
children = (
EBC33AA82595B47600CD89D7 /* Base */,
);
name = Main.storyboard;
sourceTree = "<group>";
};
EBC33AAC2595B47900CD89D7 /* LaunchScreen.storyboard */ = {
isa = PBXVariantGroup;
children = (
EBC33AAD2595B47900CD89D7 /* Base */,
);
name = LaunchScreen.storyboard;
sourceTree = "<group>";
};
/* End PBXVariantGroup section */
/* Begin XCBuildConfiguration section */
EBC33AB02595B47900CD89D7 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 14.1;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
};
name = Debug;
};
EBC33AB12595B47900CD89D7 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 14.1;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
SDKROOT = iphoneos;
SWIFT_COMPILATION_MODE = wholemodule;
SWIFT_OPTIMIZATION_LEVEL = "-O";
VALIDATE_PRODUCT = YES;
};
name = Release;
};
EBC33AB32595B47900CD89D7 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 15;
DEVELOPMENT_TEAM = S2MKP69DVN;
INFOPLIST_FILE = Verdnatura/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 2.0.0;
PRODUCT_BUNDLE_IDENTIFIER = com.verdnatura.Verdnaturaventas;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
};
EBC33AB42595B47900CD89D7 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 15;
DEVELOPMENT_TEAM = S2MKP69DVN;
INFOPLIST_FILE = Verdnatura/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 2.0.0;
PRODUCT_BUNDLE_IDENTIFIER = com.verdnatura.Verdnaturaventas;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
EBC33A992595B47600CD89D7 /* Build configuration list for PBXProject "Verdnatura" */ = {
isa = XCConfigurationList;
buildConfigurations = (
EBC33AB02595B47900CD89D7 /* Debug */,
EBC33AB12595B47900CD89D7 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
EBC33AB22595B47900CD89D7 /* Build configuration list for PBXNativeTarget "Verdnatura" */ = {
isa = XCConfigurationList;
buildConfigurations = (
EBC33AB32595B47900CD89D7 /* Debug */,
EBC33AB42595B47900CD89D7 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = EBC33A962595B47600CD89D7 /* Project object */;
}

View File

@ -1,7 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<Workspace
version = "1.0">
<FileRef
location = "self:">
</FileRef>
</Workspace>

View File

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<Bucket
uuid = "35F000CB-B2F6-4EDE-B491-B575AB22E300"
type = "1"
version = "2.0">
</Bucket>

View File

@ -1,14 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SchemeUserState</key>
<dict>
<key>Verdnatura.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
</dict>
</dict>
</plist>

View File

@ -6,6 +6,7 @@
//
import UIKit
import WebKit
@main
class AppDelegate: UIResponder, UIApplicationDelegate {
@ -30,6 +31,5 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
window?.rootViewController = rootController
}
}

View File

@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="17701" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="BYZ-38-t0r">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="21507" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="BYZ-38-t0r">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17703"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21505"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
@ -71,31 +71,24 @@
<constraint firstAttribute="trailing" secondItem="Sk0-EB-POG" secondAttribute="trailing" id="qoC-eR-DFt"/>
</constraints>
</view>
<webView contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="GGK-QR-aLx">
<rect key="frame" x="0.0" y="44" width="414" height="791"/>
<color key="backgroundColor" red="0.36078431370000003" green="0.38823529410000002" blue="0.4039215686" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</webView>
</subviews>
<viewLayoutGuide key="safeArea" id="6Tk-OE-BBY"/>
<color key="backgroundColor" red="0.0" green="0.53333333333333333" blue="0.48627450980392156" alpha="0.84705882352941175" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstItem="qRa-IP-J4a" firstAttribute="leading" secondItem="6Tk-OE-BBY" secondAttribute="leading" id="85Y-fl-AUE"/>
<constraint firstItem="0Hd-qc-i6v" firstAttribute="leading" secondItem="6Tk-OE-BBY" secondAttribute="leading" id="8Hi-Z9-Udp"/>
<constraint firstItem="GGK-QR-aLx" firstAttribute="top" secondItem="6Tk-OE-BBY" secondAttribute="top" id="C12-wC-XZA"/>
<constraint firstItem="0Hd-qc-i6v" firstAttribute="top" secondItem="8bC-Xf-vdC" secondAttribute="top" id="Hye-oH-8x3"/>
<constraint firstItem="GGK-QR-aLx" firstAttribute="leading" secondItem="6Tk-OE-BBY" secondAttribute="leading" id="Jsc-Ug-Bvw"/>
<constraint firstAttribute="bottom" secondItem="qRa-IP-J4a" secondAttribute="bottom" id="SEs-Wj-6Xi"/>
<constraint firstItem="GGK-QR-aLx" firstAttribute="trailing" secondItem="6Tk-OE-BBY" secondAttribute="trailing" id="TKQ-mv-1qf"/>
<constraint firstItem="qRa-IP-J4a" firstAttribute="trailing" secondItem="6Tk-OE-BBY" secondAttribute="trailing" id="eYA-6H-lQw"/>
<constraint firstAttribute="bottom" secondItem="GGK-QR-aLx" secondAttribute="bottom" constant="61" id="ekN-3Z-2ip"/>
<constraint firstItem="0Hd-qc-i6v" firstAttribute="trailing" secondItem="6Tk-OE-BBY" secondAttribute="trailing" id="gFi-fF-Wbg"/>
<constraint firstAttribute="bottom" secondItem="0Hd-qc-i6v" secondAttribute="bottom" id="ruc-e9-MJ3"/>
</constraints>
</view>
<toolbarItems/>
<simulatedToolbarMetrics key="simulatedBottomBarMetrics"/>
<connections>
<outlet property="btnBack" destination="Sk0-EB-POG" id="30D-KB-97y"/>
<outlet property="loadingview" destination="0Hd-qc-i6v" id="A1C-qk-bSn"/>
<outlet property="webView" destination="GGK-QR-aLx" id="mCf-fb-4cl"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>

View File

@ -1,48 +1,53 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>$(MARKETING_VERSION)</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIApplicationSupportsIndirectInputEvents</key>
<true/>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIMainStoryboardFile</key>
<string>Main</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
</dict>
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>$(MARKETING_VERSION)</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIApplicationSupportsIndirectInputEvents</key>
<true/>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIMainStoryboardFile</key>
<string>Main</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
</dict>
</plist>

View File

@ -6,36 +6,48 @@
//
import UIKit
import WebKit
class ViewController: UIViewController ,UIWebViewDelegate{
@IBOutlet weak var webView: UIWebView!
@IBOutlet weak var loadingview: UIView!
@IBOutlet weak var btnBack: UIButton!
private var newWebView:WKWebView!
override func viewDidLoad() {
super.viewDidLoad()
self.webView.delegate = self
}
override func viewDidAppear(_ animated: Bool) {
let url = URL (string: "https://www.verdnatura.es/")
let requestObj = URLRequest(url: url!)
webView.loadRequest(requestObj)
let webViewPrefs = WKPreferences()
webViewPrefs.javaScriptEnabled = true
webViewPrefs.javaScriptCanOpenWindowsAutomatically = true
let webViewConf = WKWebViewConfiguration()
webViewConf.preferences = webViewPrefs
newWebView = WKWebView(frame: view.frame, configuration: webViewConf)
newWebView.autoresizingMask = [.flexibleWidth, .flexibleHeight]
newWebView.scrollView.keyboardDismissMode = .onDrag
view.addSubview(newWebView)
view.addSubview(btnBack)
load(url: "https://shop.verdnatura.es/")
}
func webViewDidStartLoad(_ webView: UIWebView) {
func webViewDidStartLoad(_ webView: UIButton) {
loadingview.isHidden = false
}
private func load(url: String) {
newWebView.load(URLRequest(url:URL(string:url)!))
newWebView.allowsBackForwardNavigationGestures = true
}
func webViewDidFinishLoad(_ webView: UIWebView) {
loadingview.isHidden = true
loadingview.isHidden = true
}
@IBAction func goBack(_ sender: Any) {
self.webView.goBack()
self.newWebView.goBack()
}
}