Commit 1b3257ee authored by shiyunjie's avatar shiyunjie

注释 console

parent 836d8efd
......@@ -31,6 +31,7 @@
"react-native-svg": "^9.5.1",
"react-native-swiper": "^1.5.14",
"react-native-tab-view": "2.7.1",
"react-native-update-mutlirn-hg": "^3.1.1",
"react-native-vector-icons": "^6.4.2",
"react-navigation": "^3.11.0",
"react-navigation-redux-helpers": "^3.0.2",
......
......@@ -2,8 +2,6 @@
#read env
echo 玩命打包中....
echo '程序会自动npm prune,旧包将备份在build/backup文件夹下'
echo '在updage.json文件中可以定义模板,binary版本信息等'
echo '在update.json中,_androidPPK,_iOSPPK字符将会替换成打包后的文件名'
echo ''
backup(){
if [ ! -d "build/backup" ];then
......@@ -28,23 +26,13 @@ bundle(){
package(){
currentPath=`pwd`;
workPath=build/output
content=`cat ./update.json`;
cd $workPath;
android=`ls android*.ppk`;
ios=`ls ios*.ppk`;
content=${content/'_iOSPPK'/$ios};
content=${content/'_androidPPK'/$android};
content=${content/'_buildBy'/`git config user.name`};
content=${content/'_buildDate'/`date '+%Y-%m-%d-%H-%M-%S'`};
cd $currentPath
androidBinary=`cd android && ./gradlew echoVersionName -q`
cd $workPath;
content=${content/'_androidBinary'/$androidBinary};
echo $content > update.json;
zip -r `date '+%Y-%m-%d-%H时%M分%S秒'.zip` ./
rm *.ppk *.json
cd $currentPath;
echo '打包完毕,将自动打开Finder...'
echo '打包完毕,将自动打开Finder...'
}
backup && npm prune && bundle '--platform ios' && bundle '--platform android'
......
......@@ -16,7 +16,7 @@ const ActionForNativePage = action => NavigationStack.router
const initialState = NavigationStack.router.getStateForAction(ActionForTab);
const nav = (state = initialState, action) => {
console.log('nav:',action)
//console.log('nav:',action)
switch (action.type) {
case PUSH:
return NavigationStack.router.getStateForAction(ActionForNativePage(action), state);
......
......@@ -11,7 +11,7 @@ type Props = {
}
function SwiperBanner(props:Props) {
console.log('SwiperBanner',props)
//console.log('SwiperBanner',props)
return (
<SwipeView
showsButtons={false}
......
......@@ -18,7 +18,7 @@ class TabButton extends Component<Props> {
theme, iconSuite, tabBarIconName, tabBarTitle, focused, badge,
} = this.props;
const color = focused ? theme.ThemeColor : theme.Colors.charcoal;
console.log('badge:', badge);
//console.log('badge:', badge);
const hasBadge = !!badge;
return (
<View style={{ alignItems: 'center' }}>
......
......@@ -63,7 +63,7 @@ const pageName = 'productDetail';
class BaseContainer extends Component {
constructor(props : Props) {
super(props);
console.log('props', props);
//console.log('props', props);
const productDetail = getConfig(props.blueId)[props.pageName];
const { params } = props;
const { keys, layout } = productDetail;
......@@ -79,7 +79,7 @@ class BaseContainer extends Component {
keys,
};
console.log('ProductDetailPage', this.state);
//console.log('ProductDetailPage', this.state);
}
componentWillMount() : void {
......@@ -88,7 +88,7 @@ class BaseContainer extends Component {
const { keys, layout } = this.productDetail;
keys.forEach((key) => {
const data = this.fillData(key, this.productDetail[key], params);
console.log('productDetail:', this.productDetail, layout[key], key);
//console.log('productDetail:', this.productDetail, layout[key], key);
config[key] = { ...layout[key], ...data };
});
this.setState({
......@@ -102,7 +102,7 @@ class BaseContainer extends Component {
name, description, tagNameList, bannerIconUrl, guaranteeContent,
productIntroductionUrl, serviceProcessUrl,
} = params.detail;
console.log('productIntroductionUrl', productIntroductionUrl);
//console.log('productIntroductionUrl', productIntroductionUrl);
switch (key) {
case PRODUCT_BANNER:
return {
......@@ -113,7 +113,7 @@ class BaseContainer extends Component {
case PREM_GROUP:
return {
onSelect: (index) => {
console.log('BUTTON_GROUP,onSelect', index);
//console.log('BUTTON_GROUP,onSelect', index);
switch (index) {
case 0:
this.policy.prem = 99;
......@@ -151,9 +151,9 @@ class BaseContainer extends Component {
case MULT:
return {
onChangeText: (value) => {
console.log('ProductDetailPage_onChangeText', value);
//console.log('ProductDetailPage_onChangeText', value);
this.policy.mult = value;
console.log(this.policy.mult);
//console.log(this.policy.mult);
},
onEndEditing: () => {
},
......@@ -226,7 +226,7 @@ class BaseContainer extends Component {
)
renderPicker = (data) => {
console.log('renderPicker:', data);
//console.log('renderPicker:', data);
return (
<Picker {...data} />
);
......@@ -240,7 +240,7 @@ class BaseContainer extends Component {
render() {
const { config, keys } = this.state;
console.log('config:', config, keys);
//console.log('config:', config, keys);
const type = 'type';
return (
<SpringScrollView
......
......@@ -9,9 +9,9 @@ type RiskTakerParams = {
}
export async function queryInsuranceListByUidAPI(params : RiskTakerParams) {
console.log('queryInsuranceListByUidAPI', params);
//console.log('queryInsuranceListByUidAPI', params);
const body = await fetchCoreAPI('001001', params);
console.log('queryInsuranceListByUidAPI_body:', body);
//console.log('queryInsuranceListByUidAPI_body:', body);
if (_.get(body, 'code') === '0000' && _.get(body, 'data')) {
return _.get(body, 'data');
}
......@@ -19,9 +19,9 @@ export async function queryInsuranceListByUidAPI(params : RiskTakerParams) {
}
export async function queryInsuranceProductsAPI(params) {
console.log('queryInsuranceProductsAPI', params);
//console.log('queryInsuranceProductsAPI', params);
const body = await fetchCoreAPI('001002', params);
console.log('queryInsuranceProductsAPI_body:', body);
//console.log('queryInsuranceProductsAPI_body:', body);
if (_.get(body, 'code') === '0000' && _.get(body, 'data')) {
return _.get(body, 'data');
}
......@@ -29,9 +29,9 @@ export async function queryInsuranceProductsAPI(params) {
}
export async function trailPolicyAPI(params) {
console.log('trailPolicyAPI', params);
//console.log('trailPolicyAPI', params);
const body = await fetchCoreAPI('001003', {params:params});
console.log('trailPolicyAPI_body:', body);
//console.log('trailPolicyAPI_body:', body);
if (_.get(body, 'code') === '0000' && _.get(body, 'data')) {
return _.get(body, 'data');
}
......
......@@ -92,7 +92,7 @@ function renderInsuranceDetail(props) {
);
const uri = `${resourceURLMapping[ENV]}${
params.company === '太平人寿' ? 'bg_bdxq_rs.png' : 'bg_bdxq_cx.png'}`
console.log('uri:',uri)
//console.log('uri:',uri)
return (
<View style={[Styles.container, { backgroundColor: '#F4F5F5' }]}>
<NavigationBar
......
......@@ -97,7 +97,7 @@ function InsuranceListPage(props : Props) {
};
const queryList = async () => {
const list = await queryInsuranceListByUidAPI({ params: { uid: 'u0000001' } });
console.log('list:', list);
//console.log('list:', list);
if (list) {
setData([
......
......@@ -45,16 +45,15 @@ class HomePage extends Component<Props> {
};
this.scrollView = null;
}
componentDidMount() : void {
this.listener =NativeAppEventEmitter.addListener('react_navigation_onTransitionEnd_call',() => console.log('onTransitionEnd_call'))
componentDidMount() : void {
this.listener = NativeAppEventEmitter.addListener('react_navigation_onTransitionEnd_call', () => console.log('onTransitionEnd_call'));
}
componentWillUnmount() : void {
if(this.listener){
if (this.listener) {
this.listener.remove();
}
}
......@@ -76,7 +75,7 @@ class HomePage extends Component<Props> {
};
render() {
const { pushTo } = this.props
const { pushTo } = this.props;
return (
<View style={styles.container}>
<HomeHeader />
......
......@@ -55,7 +55,7 @@ class PolicyList extends Component {
queryList = async () => {
const list = await queryInsuranceProductsAPI({});
console.log('queryInsuranceProductsAPI:', list);
//console.log('queryInsuranceProductsAPI:', list);
if (list) {
this.setState({
data: [
......
......@@ -76,7 +76,7 @@ class PolicyPage extends Component<Props> {
};
_handleIndexChange = (index) => {
console.log('_handleIndexChange:', index);
//console.log('_handleIndexChange:', index);
const type = {
index,
routes: typeArr,
......
......@@ -41,7 +41,6 @@ const step = 13;
class ServicePage extends Component<Props> {
constructor(props) {
super(props);
console.log('constructor', this);
this.state = {
count: step,
allLoaded: false,
......
......@@ -67,7 +67,7 @@ export function swiperItem(props) {
}
export function renderBanner(props) {
console.log('renderBanner', props);
//console.log('renderBanner', props);
return (
<View
key="SwiperView"
......@@ -93,7 +93,7 @@ export const renderGridItem = (props) => {
return (
<TouchableOpacity
onPress={() => {
console.log(props, item.tagUrl);
//console.log(props, item.tagUrl);
props.pushTo(item.tagUrl);
}}
>
......@@ -130,7 +130,7 @@ export const renderGridItem = (props) => {
export const renderGrid = (props) => {
const gridWidth = ((props.width) / 4);
console.log('renderGrid:', gridWidth);
//console.log('renderGrid:', gridWidth);
return (
<FlatGrid
itemDimension={gridWidth}
......@@ -219,7 +219,7 @@ export function renderActivity(props) {
{props.data.map((item, index) => (
<TouchableOpacity
onPress={() => {
console.log(props.pushTo, item.tagUrl);
//console.log(props.pushTo, item.tagUrl);
props.pushTo(item.tagUrl);
}}
>
......
......@@ -68,7 +68,7 @@ function renderGrid(props) {
renderItem={({ item, index }) => (
<TouchableOpacity
onPress={() => {
console.log(props, item.tagUrl);
//console.log(props, item.tagUrl);
props.pushTo(item.tagUrl);
}}
>
......
......@@ -80,7 +80,7 @@ class FillPolicyInfoPage extends Component {
this.policy = props.navigation.state.params.policy;
const { fillInfo } = getConfig(this.policy.blueId);
console.log('FillPolicyInfoPage_fillInfo', fillInfo);
//console.log('FillPolicyInfoPage_fillInfo', fillInfo);
const { keys, layout } = fillInfo;
this.fillInfo = fillInfo;
this.state = {
......@@ -91,7 +91,7 @@ class FillPolicyInfoPage extends Component {
keys,
};
console.log('FillPolicyInfoPage', this.state);
//console.log('FillPolicyInfoPage', this.state);
}
componentWillMount() : void {
......@@ -100,7 +100,7 @@ class FillPolicyInfoPage extends Component {
const { keys, layout } = this.fillInfo;
keys.forEach((key) => {
const data = this.fillData(key, this.fillInfo[key], params);
console.log('FillPolicyInfoPage:', this.fillInfo, layout[key], key);
//console.log('FillPolicyInfoPage:', this.fillInfo, layout[key], key);
config[key] = { ...layout[key], ...data };
});
this.setState({
......
......@@ -69,7 +69,7 @@ class PaymentPage extends Component {
this.policy = props.navigation.state.params.policy;
const { payment } = getConfig(this.policy.blueId);
console.log('paymentPage_payment', payment);
//console.log('paymentPage_payment', payment);
const { keys, layout } = payment;
this.payment = payment;
this.state = {
......@@ -83,7 +83,7 @@ class PaymentPage extends Component {
keys,
};
console.log('paymentPage', this.state);
//console.log('paymentPage', this.state);
}
componentWillMount() : void {
......@@ -92,7 +92,7 @@ class PaymentPage extends Component {
const { keys, layout } = this.payment;
keys.forEach((key) => {
const data = this.fillData(key, this.payment[key], params);
console.log('paymentPage:', this.payment, layout[key], key);
//console.log('paymentPage:', this.payment, layout[key], key);
config[key] = { ...layout[key], ...data };
});
this.setState({
......
......@@ -85,7 +85,7 @@ class ProductDetailPage extends Component {
keys,
};
console.log('ProductDetailPage', this.state);
//console.log('ProductDetailPage', this.state);
}
componentWillMount() : void {
......@@ -94,7 +94,7 @@ class ProductDetailPage extends Component {
const { keys, layout } = this.productDetail;
keys.forEach((key) => {
const data = this.fillData(key, this.productDetail[key], params);
console.log('productDetail:', this.productDetail, layout[key], key);
//console.log('productDetail:', this.productDetail, layout[key], key);
config[key] = { ...layout[key], ...data };
});
this.setState({
......@@ -107,7 +107,7 @@ class ProductDetailPage extends Component {
name, description, tagNameList, bannerIconUrl, guaranteeContent,
productIntroductionUrl, serviceProcessUrl,
} = params.detail;
console.log('productIntroductionUrl', productIntroductionUrl);
//console.log('productIntroductionUrl', productIntroductionUrl);
switch (key) {
case PRODUCT_BANNER:
return {
......@@ -118,7 +118,7 @@ class ProductDetailPage extends Component {
case PREM_GROUP:
return {
onSelect: (index) => {
console.log('BUTTON_GROUP,onSelect', index);
//console.log('BUTTON_GROUP,onSelect', index);
switch (index) {
case 0:
this.policy.prem = 99;
......@@ -157,9 +157,9 @@ class ProductDetailPage extends Component {
case MULT:
return {
onChangeText: (value) => {
console.log('ProductDetailPage_onChangeText', value);
//console.log('ProductDetailPage_onChangeText', value);
this.policy.mult = value;
console.log(this.policy.mult);
//console.log(this.policy.mult);
},
onEndEditing: () => {
this.trialPolicy();
......@@ -221,7 +221,7 @@ class ProductDetailPage extends Component {
console.log('trialPolicy:', prem);
this.policy.premTotal = prem;
this.submit.setPrem(prem);
console.log('this.policy:', this.policy);
//console.log('this.policy:', this.policy);
}
renderPicker = (data) => {
......
......@@ -30,7 +30,7 @@ function JSPage(props: Props) {
useEffect(() => {
console.log('在 dep 改变时触发,若无 dep 则,每次更新组件都会触发')
const didFocus = NativeAppEventEmitter.addListener('react_navigation_onTransitionEnd_call', () => {
console.log('JSPage__didFocus',props.nav);
//console.log('JSPage__didFocus',props.nav);
})
return () => {
console.log('在组件 unmount 时触发');
......
......@@ -36,7 +36,7 @@ class NativePage extends Component<Props> {
<Button
containerStyle={{ height: 40, margin: 10 }}
onPress={() => {
console.log('onPress', this.props);
//console.log('onPress', this.props);
this.props.popTo('TabPage');
}}
title="返回首页"
......
......@@ -29,7 +29,7 @@ type
function RatingPage(props:Props) {
const { theme } = props;
const ratingCompleted = (rating) => {
console.log('Rating is: ', rating);
//console.log('Rating is: ', rating);
};
return (
<View style={Styles.container}>
......
......@@ -32,13 +32,13 @@ import React, { Component, Fragment } from 'react';
function decorator(Comp) {
if(typeof Comp === 'function'){
console.log('isFunction')
//console.log('isFunction')
return Comp;
}
class WrapComp extends Component {
componentDidMount() : void {
console.log('WrapComp_name', Comp.name);
console.log('WrapComp_componentDidMount', Comp);
//console.log('WrapComp_name', Comp.name);
//console.log('WrapComp_componentDidMount', Comp);
}
render() {
......
{
"ios": {
"binary": "1.0.4",
"url": "https://fir.im/f9ay",
"patch":"http://192.168.3.13/IXX/_iOSPPK"
},
"android": {
"binary": "1.0.4",
"url": "https://fir.im/qbsy",
"patch":"http://192.168.3.13/_androidPPK"
},
"buildDate":"_buildDate",
"buildBy":"_buildBy"
}
\ No newline at end of file
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