Commit c757fe1c by 姜雷

添加用户默认图并删除npm包

parent 536a08da
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
module.exports =
/******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId]) {
/******/ return installedModules[moduleId].exports;
/******/ }
/******/ // Create a new module (and put it into the cache)
/******/ var module = installedModules[moduleId] = {
/******/ i: moduleId,
/******/ l: false,
/******/ exports: {}
/******/ };
/******/
/******/ // Execute the module function
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ // Flag the module as loaded
/******/ module.l = true;
/******/
/******/ // Return the exports of the module
/******/ return module.exports;
/******/ }
/******/
/******/
/******/ // expose the modules object (__webpack_modules__)
/******/ __webpack_require__.m = modules;
/******/
/******/ // expose the module cache
/******/ __webpack_require__.c = installedModules;
/******/
/******/ // define getter function for harmony exports
/******/ __webpack_require__.d = function(exports, name, getter) {
/******/ if(!__webpack_require__.o(exports, name)) {
/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
/******/ }
/******/ };
/******/
/******/ // define __esModule on exports
/******/ __webpack_require__.r = function(exports) {
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ }
/******/ Object.defineProperty(exports, '__esModule', { value: true });
/******/ };
/******/
/******/ // create a fake namespace object
/******/ // mode & 1: value is a module id, require it
/******/ // mode & 2: merge all properties of value into the ns
/******/ // mode & 4: return value when already ns object
/******/ // mode & 8|1: behave like require
/******/ __webpack_require__.t = function(value, mode) {
/******/ if(mode & 1) value = __webpack_require__(value);
/******/ if(mode & 8) return value;
/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
/******/ var ns = Object.create(null);
/******/ __webpack_require__.r(ns);
/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
/******/ return ns;
/******/ };
/******/
/******/ // getDefaultExport function for compatibility with non-harmony modules
/******/ __webpack_require__.n = function(module) {
/******/ var getter = module && module.__esModule ?
/******/ function getDefault() { return module['default']; } :
/******/ function getModuleExports() { return module; };
/******/ __webpack_require__.d(getter, 'a', getter);
/******/ return getter;
/******/ };
/******/
/******/ // Object.prototype.hasOwnProperty.call
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "";
/******/
/******/
/******/ // Load entry module and return exports
/******/ return __webpack_require__(__webpack_require__.s = 0);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var _wxF = __webpack_require__(1);
var _wxF2 = _interopRequireDefault(_wxF);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
Component({
/**
* 组件的属性列表
*/
properties: {
canvasId: {
type: String,
value: 'f2-canvas'
},
opts: {
type: Object
}
},
/**
* 组件的初始数据
*/
data: {},
ready: function ready() {
if (!this.data.opts) {
console.warn('组件需绑定 opts 变量,例:<ff-canvas id="mychart-dom-bar" canvas-id="mychart-bar" opts="{{ opts }}"></ff-canvas>');
return;
}
if (!this.data.opts.lazyLoad) {
this.init();
}
},
/**
* 组件的方法列表
*/
methods: {
init: function init(callback) {
var _this = this;
var version = wx.version.version.split('.').map(function (n) {
return parseInt(n, 10);
});
var isValid = version[0] > 1 || version[0] === 1 && version[1] > 9 || version[0] === 1 && version[1] === 9 && version[2] >= 91;
if (!isValid) {
console.error('微信基础库版本过低,需大于等于 1.9.91。');
return;
}
var ctx = wx.createCanvasContext(this.data.canvasId, this); // 获取小程序上下文
var canvas = new _wxF2.default.Renderer(ctx);
this.canvas = canvas;
var query = wx.createSelectorQuery().in(this);
query.select('.f2-canvas').boundingClientRect(function (res) {
if (typeof callback === 'function') {
_this.chart = callback(canvas, res.width, res.height, _wxF2.default);
} else if (_this.data.opts && _this.data.opts.onInit) {
_this.chart = _this.data.opts.onInit(canvas, res.width, res.height, _wxF2.default);
}
}).exec();
},
touchStart: function touchStart(e) {
if (this.canvas) {
this.canvas.emitEvent('touchstart', [e]);
}
},
touchMove: function touchMove(e) {
if (this.canvas) {
this.canvas.emitEvent('touchmove', [e]);
}
},
touchEnd: function touchEnd(e) {
if (this.canvas) {
this.canvas.emitEvent('touchend', [e]);
}
},
press: function press(e) {
if (this.canvas) {
this.canvas.emitEvent('press', [e]);
}
}
}
}); // f2-canvas.js
/***/ }),
/* 1 */
/***/ (function(module, exports) {
module.exports = require("@antv/wx-f2");
/***/ })
/******/ ]);
\ No newline at end of file
{
"component": true,
"usingComponents": {}
}
\ No newline at end of file
<canvas
class="f2-canvas"
canvas-id="{{ canvasId }}"
bindinit="init"
bindtouchstart="touchStart"
bindtouchmove="touchMove"
bindtouchend="touchEnd"
bindlongtap="press"
>
</canvas>
/* f2-canvas.wxss */
.f2-canvas {
width: 100%;
height: 100%;
}
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
const{storeMap:storeMap,notifyStack:notifyStack}=require("../constant"),{cloneObj:cloneObj}=require("../utils");module.exports=function(t){return function(n){const{onLoad:o,onUnload:a}=n;return n.onLoad=function(n){const a=t.call(this,storeMap,n),i=cloneObj(a);notifyStack.push([this,t.bind(this),i,n]),this.setData(Object.assign({},this.data,a)),o&&o.call(this,n)},n.onUnload=function(){notifyStack.pop(),a&&a.call(this)},n}};
\ No newline at end of file
const{storeMap:storeMap}=require("../constant"),{notifyUpdate:notifyUpdate}=require("../core"),{cloneObj:cloneObj,isProxyNeeded:isProxyNeeded}=require("../utils");module.exports=function(e,t){t=t||e.constructor.name.toLowerCase();const o=Object.getOwnPropertyNames(e);return storeMap[t]||(storeMap[t]=cloneObj(e,o)),wrapToProxy(e,[t])};const wrapToProxy=(e,t)=>(Object.keys(e).forEach(o=>{isProxyNeeded(e[o])&&(e[o]=wrapToProxy(e[o],t.concat([o])))}),new Proxy(e,{get(e,o){if("__isProxy"===o)return!0;if("__data"===o)return findInStoreMap(t);const r=Reflect.get(e,o)&&Reflect.get(e,o);if(r&&r.__isProxy)return r;const n=findInStoreMap(t.concat([o]));return void 0!==n&&n||r},set(e,o,r){const n=r&&r.__isProxy&&r.__data||r,a=isProxyNeeded(n)&&wrapToProxy(cloneObj(n),t.concat([o]))||n,c=Reflect.set(e,o,a);return setValueInStoreMap(t.concat([o]),n),notifyUpdate(),c},deleteProperty:(e,o)=>!!e[o]&&(Reflect.deleteProperty(e,o),deleteKeyInStoreMap(t.concat([o])),notifyUpdate(),!0)})),findInStoreMap=e=>e.reduce((e,t)=>"pointsGranted"===t?e:e&&e[t]||void 0,storeMap),setValueInStoreMap=(e,t)=>{const o=e.length,r=e[o-1];let n=storeMap;e.forEach((e,t)=>{t!==o-1&&(n=n[e])}),n[r]=t},deleteKeyInStoreMap=e=>{const t=e.length,o=e[t-1];let r=storeMap;e.forEach((e,o)=>{o!==t-1&&(r=r[e])}),delete r[o]};
\ No newline at end of file
exports.storeMap={},exports.notifyStack=[];
\ No newline at end of file
const{storeMap:storeMap,notifyStack:notifyStack}=require("./constant"),{isEqualObj:isEqualObj,cloneObj:cloneObj}=require("./utils"),timeout=5;let batch=0;exports.notifyUpdate=function(){batch++,setTimeout(()=>{if(0==--batch){for(let t=notifyStack.length-1;t>=0;t--){const[o,e,a,i]=notifyStack[t],n=e(storeMap,i);isEqualObj(a,n)||(notifyStack[t][2]=cloneObj(n),o.setData(n))}}},5)};
\ No newline at end of file
exports.mapToData=require("./api/mapToData"),exports.observe=require("./api/observe");
\ No newline at end of file
const isEqualObj=function(t,e){if(Object.prototype.toString.call(t)!==Object.prototype.toString.call(e))return!1;if(Object.keys(t).length!==Object.keys(e).length)return!1;let r=!0;return Object.keys(t).forEach(c=>{switch(Object.prototype.toString.call(t[c])){case"[object Object]":isEqualObj(t[c],e[c])||(r=!1);break;case"[object Array]":isEqualArray(t[c],e[c])||(r=!1);break;default:t[c]!==e[c]&&(r=!1)}}),r},isEqualArray=(t,e)=>{if(Object.prototype.toString.call(t)!==Object.prototype.toString.call(e))return!1;if(t.length!==e.length)return!1;let r=!0;return t.forEach((t,c)=>{t!==e[c]&&(r=!1)}),r};exports.isEqualObj=isEqualObj;const cloneObj=function(t,e){let r={};return Object.keys(t).forEach(c=>{if(!e||e.includes(c))switch(Object.prototype.toString.call(t[c])){case"[object Object]":r[c]=cloneObj(t[c]);break;case"[object Array]":r[c]=cloneArray(t[c]);break;default:r[c]=t[c]}}),r},cloneArray=t=>t.map(t=>{switch(Object.prototype.toString.call(t)){case"[object Object]":return cloneObj(t);case"[object Array]":return cloneArray(t);default:return t}});exports.cloneObj=cloneObj,exports.isProxyNeeded=(t=>{const e=Object.prototype.toString.call(t);return"[object Object]"===e||"[object Array]"===e});
\ No newline at end of file
<!--miniprogram/pages/report/report.wxml-->
<!-- miniprogram/pages/report/report.wxml -->
<view class="container report">
<view class="report-header">
<view class="report-header-user">
<view class="report-header-userInfo">
<view class="report-header-userName">
{{userInfo.name}}
</view>
<view class="report-header-userAccount">
{{userInfo.cellphone}}
</view>
<view class="report-header-userName">{{userInfo.name}}</view>
<view class="report-header-userAccount">{{userInfo.cellphone}}</view>
</view>
<view class="report-header-userImg">
<image class="report-header-userIcon" src="../../images/img_yonghu_default@2x.png" />
</view>
</view>
<!-- <view class="report-header-account">
......
......@@ -45,7 +45,10 @@
border-radius: 50%;
background-color: #fff;
}
.report-header-userIcon {
width: 120rpx;
height: 120rpx;
}
.report-header-account {
display: flex;
justify-content: space-around;
......
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