Commit bba1df0b by lingyu0918

初始化提交

parent cedbc6e4
Showing with 5127 additions and 994 deletions
# Mac
.DS_Store
**/.DS_Store
# vim/vi
*.swp
# JavaScript
node_modules/
.node_modules/
.eslintcache
unpackage/dist/build/
unpackage/dist/dev/
# python
*.pyc
......@@ -15,4 +15,8 @@ export default {
@import '@/themes/base.scss';
@import '@/themes/theme.scss';
page {
padding-bottom: constant(safe-area-inset-bottom);
padding-bottom: env(safe-area-inset-bottom);
}
</style>
......@@ -7,8 +7,6 @@ export function userLoginToken(data) {
method: 'post',
data: data
})
console.log('userLoginToken')
console.log(result)
return result
}
......
let QRCode = {};
(function () {
/**
* 获取单个字符的utf8编码
* unicode BMP平面约65535个字符
* @param {num} code
* return {array}
*/
function unicodeFormat8(code) {
// 1 byte
var c0, c1, c2;
if (code < 128) {
return [code];
// 2 bytes
} else if (code < 2048) {
c0 = 192 + (code >> 6);
c1 = 128 + (code & 63);
return [c0, c1];
// 3 bytes
} else {
c0 = 224 + (code >> 12);
c1 = 128 + (code >> 6 & 63);
c2 = 128 + (code & 63);
return [c0, c1, c2];
}
}
/**
* 获取字符串的utf8编码字节串
* @param {string} string
* @return {array}
*/
function getUTF8Bytes(string) {
var utf8codes = [];
for (var i = 0; i < string.length; i++) {
var code = string.charCodeAt(i);
var utf8 = unicodeFormat8(code);
for (var j = 0; j < utf8.length; j++) {
utf8codes.push(utf8[j]);
}
}
return utf8codes;
}
/**
* 二维码算法实现
* @param {string} data 要编码的信息字符串
* @param {num} errorCorrectLevel 纠错等级
*/
function QRCodeAlg(data, errorCorrectLevel) {
this.typeNumber = -1; //版本
this.errorCorrectLevel = errorCorrectLevel;
this.modules = null; //二维矩阵,存放最终结果
this.moduleCount = 0; //矩阵大小
this.dataCache = null; //数据缓存
this.rsBlocks = null; //版本数据信息
this.totalDataCount = -1; //可使用的数据量
this.data = data;
this.utf8bytes = getUTF8Bytes(data);
this.make();
}
QRCodeAlg.prototype = {
constructor: QRCodeAlg,
/**
* 获取二维码矩阵大小
* @return {num} 矩阵大小
*/
getModuleCount: function () {
return this.moduleCount;
},
/**
* 编码
*/
make: function () {
this.getRightType();
this.dataCache = this.createData();
this.createQrcode();
},
/**
* 设置二位矩阵功能图形
* @param {bool} test 表示是否在寻找最好掩膜阶段
* @param {num} maskPattern 掩膜的版本
*/
makeImpl: function (maskPattern) {
this.moduleCount = this.typeNumber * 4 + 17;
this.modules = new Array(this.moduleCount);
for (var row = 0; row < this.moduleCount; row++) {
this.modules[row] = new Array(this.moduleCount);
}
this.setupPositionProbePattern(0, 0);
this.setupPositionProbePattern(this.moduleCount - 7, 0);
this.setupPositionProbePattern(0, this.moduleCount - 7);
this.setupPositionAdjustPattern();
this.setupTimingPattern();
this.setupTypeInfo(true, maskPattern);
if (this.typeNumber >= 7) {
this.setupTypeNumber(true);
}
this.mapData(this.dataCache, maskPattern);
},
/**
* 设置二维码的位置探测图形
* @param {num} row 探测图形的中心横坐标
* @param {num} col 探测图形的中心纵坐标
*/
setupPositionProbePattern: function (row, col) {
for (var r = -1; r <= 7; r++) {
if (row + r <= -1 || this.moduleCount <= row + r) continue;
for (var c = -1; c <= 7; c++) {
if (col + c <= -1 || this.moduleCount <= col + c) continue;
if ((0 <= r && r <= 6 && (c == 0 || c == 6)) || (0 <= c && c <= 6 && (r == 0 || r == 6)) || (2 <= r && r <= 4 && 2 <= c && c <= 4)) {
this.modules[row + r][col + c] = true;
} else {
this.modules[row + r][col + c] = false;
}
}
}
},
/**
* 创建二维码
* @return {[type]} [description]
*/
createQrcode: function () {
var minLostPoint = 0;
var pattern = 0;
var bestModules = null;
for (var i = 0; i < 8; i++) {
this.makeImpl(i);
var lostPoint = QRUtil.getLostPoint(this);
if (i == 0 || minLostPoint > lostPoint) {
minLostPoint = lostPoint;
pattern = i;
bestModules = this.modules;
}
}
this.modules = bestModules;
this.setupTypeInfo(false, pattern);
if (this.typeNumber >= 7) {
this.setupTypeNumber(false);
}
},
/**
* 设置定位图形
* @return {[type]} [description]
*/
setupTimingPattern: function () {
for (var r = 8; r < this.moduleCount - 8; r++) {
if (this.modules[r][6] != null) {
continue;
}
this.modules[r][6] = (r % 2 == 0);
if (this.modules[6][r] != null) {
continue;
}
this.modules[6][r] = (r % 2 == 0);
}
},
/**
* 设置矫正图形
* @return {[type]} [description]
*/
setupPositionAdjustPattern: function () {
var pos = QRUtil.getPatternPosition(this.typeNumber);
for (var i = 0; i < pos.length; i++) {
for (var j = 0; j < pos.length; j++) {
var row = pos[i];
var col = pos[j];
if (this.modules[row][col] != null) {
continue;
}
for (var r = -2; r <= 2; r++) {
for (var c = -2; c <= 2; c++) {
if (r == -2 || r == 2 || c == -2 || c == 2 || (r == 0 && c == 0)) {
this.modules[row + r][col + c] = true;
} else {
this.modules[row + r][col + c] = false;
}
}
}
}
}
},
/**
* 设置版本信息(7以上版本才有)
* @param {bool} test 是否处于判断最佳掩膜阶段
* @return {[type]} [description]
*/
setupTypeNumber: function (test) {
var bits = QRUtil.getBCHTypeNumber(this.typeNumber);
for (var i = 0; i < 18; i++) {
var mod = (!test && ((bits >> i) & 1) == 1);
this.modules[Math.floor(i / 3)][i % 3 + this.moduleCount - 8 - 3] = mod;
this.modules[i % 3 + this.moduleCount - 8 - 3][Math.floor(i / 3)] = mod;
}
},
/**
* 设置格式信息(纠错等级和掩膜版本)
* @param {bool} test
* @param {num} maskPattern 掩膜版本
* @return {}
*/
setupTypeInfo: function (test, maskPattern) {
var data = (QRErrorCorrectLevel[this.errorCorrectLevel] << 3) | maskPattern;
var bits = QRUtil.getBCHTypeInfo(data);
// vertical
for (var i = 0; i < 15; i++) {
var mod = (!test && ((bits >> i) & 1) == 1);
if (i < 6) {
this.modules[i][8] = mod;
} else if (i < 8) {
this.modules[i + 1][8] = mod;
} else {
this.modules[this.moduleCount - 15 + i][8] = mod;
}
// horizontal
var mod = (!test && ((bits >> i) & 1) == 1);
if (i < 8) {
this.modules[8][this.moduleCount - i - 1] = mod;
} else if (i < 9) {
this.modules[8][15 - i - 1 + 1] = mod;
} else {
this.modules[8][15 - i - 1] = mod;
}
}
// fixed module
this.modules[this.moduleCount - 8][8] = (!test);
},
/**
* 数据编码
* @return {[type]} [description]
*/
createData: function () {
var buffer = new QRBitBuffer();
var lengthBits = this.typeNumber > 9 ? 16 : 8;
buffer.put(4, 4); //添加模式
buffer.put(this.utf8bytes.length, lengthBits);
for (var i = 0, l = this.utf8bytes.length; i < l; i++) {
buffer.put(this.utf8bytes[i], 8);
}
if (buffer.length + 4 <= this.totalDataCount * 8) {
buffer.put(0, 4);
}
// padding
while (buffer.length % 8 != 0) {
buffer.putBit(false);
}
// padding
while (true) {
if (buffer.length >= this.totalDataCount * 8) {
break;
}
buffer.put(QRCodeAlg.PAD0, 8);
if (buffer.length >= this.totalDataCount * 8) {
break;
}
buffer.put(QRCodeAlg.PAD1, 8);
}
return this.createBytes(buffer);
},
/**
* 纠错码编码
* @param {buffer} buffer 数据编码
* @return {[type]}
*/
createBytes: function (buffer) {
var offset = 0;
var maxDcCount = 0;
var maxEcCount = 0;
var length = this.rsBlock.length / 3;
var rsBlocks = new Array();
for (var i = 0; i < length; i++) {
var count = this.rsBlock[i * 3 + 0];
var totalCount = this.rsBlock[i * 3 + 1];
var dataCount = this.rsBlock[i * 3 + 2];
for (var j = 0; j < count; j++) {
rsBlocks.push([dataCount, totalCount]);
}
}
var dcdata = new Array(rsBlocks.length);
var ecdata = new Array(rsBlocks.length);
for (var r = 0; r < rsBlocks.length; r++) {
var dcCount = rsBlocks[r][0];
var ecCount = rsBlocks[r][1] - dcCount;
maxDcCount = Math.max(maxDcCount, dcCount);
maxEcCount = Math.max(maxEcCount, ecCount);
dcdata[r] = new Array(dcCount);
for (var i = 0; i < dcdata[r].length; i++) {
dcdata[r][i] = 0xff & buffer.buffer[i + offset];
}
offset += dcCount;
var rsPoly = QRUtil.getErrorCorrectPolynomial(ecCount);
var rawPoly = new QRPolynomial(dcdata[r], rsPoly.getLength() - 1);
var modPoly = rawPoly.mod(rsPoly);
ecdata[r] = new Array(rsPoly.getLength() - 1);
for (var i = 0; i < ecdata[r].length; i++) {
var modIndex = i + modPoly.getLength() - ecdata[r].length;
ecdata[r][i] = (modIndex >= 0) ? modPoly.get(modIndex) : 0;
}
}
var data = new Array(this.totalDataCount);
var index = 0;
for (var i = 0; i < maxDcCount; i++) {
for (var r = 0; r < rsBlocks.length; r++) {
if (i < dcdata[r].length) {
data[index++] = dcdata[r][i];
}
}
}
for (var i = 0; i < maxEcCount; i++) {
for (var r = 0; r < rsBlocks.length; r++) {
if (i < ecdata[r].length) {
data[index++] = ecdata[r][i];
}
}
}
return data;
},
/**
* 布置模块,构建最终信息
* @param {} data
* @param {} maskPattern
* @return {}
*/
mapData: function (data, maskPattern) {
var inc = -1;
var row = this.moduleCount - 1;
var bitIndex = 7;
var byteIndex = 0;
for (var col = this.moduleCount - 1; col > 0; col -= 2) {
if (col == 6) col--;
while (true) {
for (var c = 0; c < 2; c++) {
if (this.modules[row][col - c] == null) {
var dark = false;
if (byteIndex < data.length) {
dark = (((data[byteIndex] >>> bitIndex) & 1) == 1);
}
var mask = QRUtil.getMask(maskPattern, row, col - c);
if (mask) {
dark = !dark;
}
this.modules[row][col - c] = dark;
bitIndex--;
if (bitIndex == -1) {
byteIndex++;
bitIndex = 7;
}
}
}
row += inc;
if (row < 0 || this.moduleCount <= row) {
row -= inc;
inc = -inc;
break;
}
}
}
}
};
/**
* 填充字段
*/
QRCodeAlg.PAD0 = 0xEC;
QRCodeAlg.PAD1 = 0x11;
//---------------------------------------------------------------------
// 纠错等级对应的编码
//---------------------------------------------------------------------
var QRErrorCorrectLevel = [1, 0, 3, 2];
//---------------------------------------------------------------------
// 掩膜版本
//---------------------------------------------------------------------
var QRMaskPattern = {
PATTERN000: 0,
PATTERN001: 1,
PATTERN010: 2,
PATTERN011: 3,
PATTERN100: 4,
PATTERN101: 5,
PATTERN110: 6,
PATTERN111: 7
};
//---------------------------------------------------------------------
// 工具类
//---------------------------------------------------------------------
var QRUtil = {
/*
每个版本矫正图形的位置
*/
PATTERN_POSITION_TABLE: [
[],
[6, 18],
[6, 22],
[6, 26],
[6, 30],
[6, 34],
[6, 22, 38],
[6, 24, 42],
[6, 26, 46],
[6, 28, 50],
[6, 30, 54],
[6, 32, 58],
[6, 34, 62],
[6, 26, 46, 66],
[6, 26, 48, 70],
[6, 26, 50, 74],
[6, 30, 54, 78],
[6, 30, 56, 82],
[6, 30, 58, 86],
[6, 34, 62, 90],
[6, 28, 50, 72, 94],
[6, 26, 50, 74, 98],
[6, 30, 54, 78, 102],
[6, 28, 54, 80, 106],
[6, 32, 58, 84, 110],
[6, 30, 58, 86, 114],
[6, 34, 62, 90, 118],
[6, 26, 50, 74, 98, 122],
[6, 30, 54, 78, 102, 126],
[6, 26, 52, 78, 104, 130],
[6, 30, 56, 82, 108, 134],
[6, 34, 60, 86, 112, 138],
[6, 30, 58, 86, 114, 142],
[6, 34, 62, 90, 118, 146],
[6, 30, 54, 78, 102, 126, 150],
[6, 24, 50, 76, 102, 128, 154],
[6, 28, 54, 80, 106, 132, 158],
[6, 32, 58, 84, 110, 136, 162],
[6, 26, 54, 82, 110, 138, 166],
[6, 30, 58, 86, 114, 142, 170]
],
G15: (1 << 10) | (1 << 8) | (1 << 5) | (1 << 4) | (1 << 2) | (1 << 1) | (1 << 0),
G18: (1 << 12) | (1 << 11) | (1 << 10) | (1 << 9) | (1 << 8) | (1 << 5) | (1 << 2) | (1 << 0),
G15_MASK: (1 << 14) | (1 << 12) | (1 << 10) | (1 << 4) | (1 << 1),
/*
BCH编码格式信息
*/
getBCHTypeInfo: function (data) {
var d = data << 10;
while (QRUtil.getBCHDigit(d) - QRUtil.getBCHDigit(QRUtil.G15) >= 0) {
d ^= (QRUtil.G15 << (QRUtil.getBCHDigit(d) - QRUtil.getBCHDigit(QRUtil.G15)));
}
return ((data << 10) | d) ^ QRUtil.G15_MASK;
},
/*
BCH编码版本信息
*/
getBCHTypeNumber: function (data) {
var d = data << 12;
while (QRUtil.getBCHDigit(d) - QRUtil.getBCHDigit(QRUtil.G18) >= 0) {
d ^= (QRUtil.G18 << (QRUtil.getBCHDigit(d) - QRUtil.getBCHDigit(QRUtil.G18)));
}
return (data << 12) | d;
},
/*
获取BCH位信息
*/
getBCHDigit: function (data) {
var digit = 0;
while (data != 0) {
digit++;
data >>>= 1;
}
return digit;
},
/*
获取版本对应的矫正图形位置
*/
getPatternPosition: function (typeNumber) {
return QRUtil.PATTERN_POSITION_TABLE[typeNumber - 1];
},
/*
掩膜算法
*/
getMask: function (maskPattern, i, j) {
switch (maskPattern) {
case QRMaskPattern.PATTERN000:
return (i + j) % 2 == 0;
case QRMaskPattern.PATTERN001:
return i % 2 == 0;
case QRMaskPattern.PATTERN010:
return j % 3 == 0;
case QRMaskPattern.PATTERN011:
return (i + j) % 3 == 0;
case QRMaskPattern.PATTERN100:
return (Math.floor(i / 2) + Math.floor(j / 3)) % 2 == 0;
case QRMaskPattern.PATTERN101:
return (i * j) % 2 + (i * j) % 3 == 0;
case QRMaskPattern.PATTERN110:
return ((i * j) % 2 + (i * j) % 3) % 2 == 0;
case QRMaskPattern.PATTERN111:
return ((i * j) % 3 + (i + j) % 2) % 2 == 0;
default:
throw new Error("bad maskPattern:" + maskPattern);
}
},
/*
获取RS的纠错多项式
*/
getErrorCorrectPolynomial: function (errorCorrectLength) {
var a = new QRPolynomial([1], 0);
for (var i = 0; i < errorCorrectLength; i++) {
a = a.multiply(new QRPolynomial([1, QRMath.gexp(i)], 0));
}
return a;
},
/*
获取评价
*/
getLostPoint: function (qrCode) {
var moduleCount = qrCode.getModuleCount(),
lostPoint = 0,
darkCount = 0;
for (var row = 0; row < moduleCount; row++) {
var sameCount = 0;
var head = qrCode.modules[row][0];
for (var col = 0; col < moduleCount; col++) {
var current = qrCode.modules[row][col];
//level 3 评价
if (col < moduleCount - 6) {
if (current && !qrCode.modules[row][col + 1] && qrCode.modules[row][col + 2] && qrCode.modules[row][col + 3] && qrCode.modules[row][col + 4] && !qrCode.modules[row][col + 5] && qrCode.modules[row][col + 6]) {
if (col < moduleCount - 10) {
if (qrCode.modules[row][col + 7] && qrCode.modules[row][col + 8] && qrCode.modules[row][col + 9] && qrCode.modules[row][col + 10]) {
lostPoint += 40;
}
} else if (col > 3) {
if (qrCode.modules[row][col - 1] && qrCode.modules[row][col - 2] && qrCode.modules[row][col - 3] && qrCode.modules[row][col - 4]) {
lostPoint += 40;
}
}
}
}
//level 2 评价
if ((row < moduleCount - 1) && (col < moduleCount - 1)) {
var count = 0;
if (current) count++;
if (qrCode.modules[row + 1][col]) count++;
if (qrCode.modules[row][col + 1]) count++;
if (qrCode.modules[row + 1][col + 1]) count++;
if (count == 0 || count == 4) {
lostPoint += 3;
}
}
//level 1 评价
if (head ^ current) {
sameCount++;
} else {
head = current;
if (sameCount >= 5) {
lostPoint += (3 + sameCount - 5);
}
sameCount = 1;
}
//level 4 评价
if (current) {
darkCount++;
}
}
}
for (var col = 0; col < moduleCount; col++) {
var sameCount = 0;
var head = qrCode.modules[0][col];
for (var row = 0; row < moduleCount; row++) {
var current = qrCode.modules[row][col];
//level 3 评价
if (row < moduleCount - 6) {
if (current && !qrCode.modules[row + 1][col] && qrCode.modules[row + 2][col] && qrCode.modules[row + 3][col] && qrCode.modules[row + 4][col] && !qrCode.modules[row + 5][col] && qrCode.modules[row + 6][col]) {
if (row < moduleCount - 10) {
if (qrCode.modules[row + 7][col] && qrCode.modules[row + 8][col] && qrCode.modules[row + 9][col] && qrCode.modules[row + 10][col]) {
lostPoint += 40;
}
} else if (row > 3) {
if (qrCode.modules[row - 1][col] && qrCode.modules[row - 2][col] && qrCode.modules[row - 3][col] && qrCode.modules[row - 4][col]) {
lostPoint += 40;
}
}
}
}
//level 1 评价
if (head ^ current) {
sameCount++;
} else {
head = current;
if (sameCount >= 5) {
lostPoint += (3 + sameCount - 5);
}
sameCount = 1;
}
}
}
// LEVEL4
var ratio = Math.abs(100 * darkCount / moduleCount / moduleCount - 50) / 5;
lostPoint += ratio * 10;
return lostPoint;
}
};
//---------------------------------------------------------------------
// QRMath使用的数学工具
//---------------------------------------------------------------------
var QRMath = {
/*
将n转化为a^m
*/
glog: function (n) {
if (n < 1) {
throw new Error("glog(" + n + ")");
}
return QRMath.LOG_TABLE[n];
},
/*
将a^m转化为n
*/
gexp: function (n) {
while (n < 0) {
n += 255;
}
while (n >= 256) {
n -= 255;
}
return QRMath.EXP_TABLE[n];
},
EXP_TABLE: new Array(256),
LOG_TABLE: new Array(256)
};
for (var i = 0; i < 8; i++) {
QRMath.EXP_TABLE[i] = 1 << i;
}
for (var i = 8; i < 256; i++) {
QRMath.EXP_TABLE[i] = QRMath.EXP_TABLE[i - 4] ^ QRMath.EXP_TABLE[i - 5] ^ QRMath.EXP_TABLE[i - 6] ^ QRMath.EXP_TABLE[i - 8];
}
for (var i = 0; i < 255; i++) {
QRMath.LOG_TABLE[QRMath.EXP_TABLE[i]] = i;
}
//---------------------------------------------------------------------
// QRPolynomial 多项式
//---------------------------------------------------------------------
/**
* 多项式类
* @param {Array} num 系数
* @param {num} shift a^shift
*/
function QRPolynomial(num, shift) {
if (num.length == undefined) {
throw new Error(num.length + "/" + shift);
}
var offset = 0;
while (offset < num.length && num[offset] == 0) {
offset++;
}
this.num = new Array(num.length - offset + shift);
for (var i = 0; i < num.length - offset; i++) {
this.num[i] = num[i + offset];
}
}
QRPolynomial.prototype = {
get: function (index) {
return this.num[index];
},
getLength: function () {
return this.num.length;
},
/**
* 多项式乘法
* @param {QRPolynomial} e 被乘多项式
* @return {[type]} [description]
*/
multiply: function (e) {
var num = new Array(this.getLength() + e.getLength() - 1);
for (var i = 0; i < this.getLength(); i++) {
for (var j = 0; j < e.getLength(); j++) {
num[i + j] ^= QRMath.gexp(QRMath.glog(this.get(i)) + QRMath.glog(e.get(j)));
}
}
return new QRPolynomial(num, 0);
},
/**
* 多项式模运算
* @param {QRPolynomial} e 模多项式
* @return {}
*/
mod: function (e) {
var tl = this.getLength(),
el = e.getLength();
if (tl - el < 0) {
return this;
}
var num = new Array(tl);
for (var i = 0; i < tl; i++) {
num[i] = this.get(i);
}
while (num.length >= el) {
var ratio = QRMath.glog(num[0]) - QRMath.glog(e.get(0));
for (var i = 0; i < e.getLength(); i++) {
num[i] ^= QRMath.gexp(QRMath.glog(e.get(i)) + ratio);
}
while (num[0] == 0) {
num.shift();
}
}
return new QRPolynomial(num, 0);
}
};
//---------------------------------------------------------------------
// RS_BLOCK_TABLE
//---------------------------------------------------------------------
/*
二维码各个版本信息[块数, 每块中的数据块数, 每块中的信息块数]
*/
var RS_BLOCK_TABLE = [
// L
// M
// Q
// H
// 1
[1, 26, 19],
[1, 26, 16],
[1, 26, 13],
[1, 26, 9],
// 2
[1, 44, 34],
[1, 44, 28],
[1, 44, 22],
[1, 44, 16],
// 3
[1, 70, 55],
[1, 70, 44],
[2, 35, 17],
[2, 35, 13],
// 4
[1, 100, 80],
[2, 50, 32],
[2, 50, 24],
[4, 25, 9],
// 5
[1, 134, 108],
[2, 67, 43],
[2, 33, 15, 2, 34, 16],
[2, 33, 11, 2, 34, 12],
// 6
[2, 86, 68],
[4, 43, 27],
[4, 43, 19],
[4, 43, 15],
// 7
[2, 98, 78],
[4, 49, 31],
[2, 32, 14, 4, 33, 15],
[4, 39, 13, 1, 40, 14],
// 8
[2, 121, 97],
[2, 60, 38, 2, 61, 39],
[4, 40, 18, 2, 41, 19],
[4, 40, 14, 2, 41, 15],
// 9
[2, 146, 116],
[3, 58, 36, 2, 59, 37],
[4, 36, 16, 4, 37, 17],
[4, 36, 12, 4, 37, 13],
// 10
[2, 86, 68, 2, 87, 69],
[4, 69, 43, 1, 70, 44],
[6, 43, 19, 2, 44, 20],
[6, 43, 15, 2, 44, 16],
// 11
[4, 101, 81],
[1, 80, 50, 4, 81, 51],
[4, 50, 22, 4, 51, 23],
[3, 36, 12, 8, 37, 13],
// 12
[2, 116, 92, 2, 117, 93],
[6, 58, 36, 2, 59, 37],
[4, 46, 20, 6, 47, 21],
[7, 42, 14, 4, 43, 15],
// 13
[4, 133, 107],
[8, 59, 37, 1, 60, 38],
[8, 44, 20, 4, 45, 21],
[12, 33, 11, 4, 34, 12],
// 14
[3, 145, 115, 1, 146, 116],
[4, 64, 40, 5, 65, 41],
[11, 36, 16, 5, 37, 17],
[11, 36, 12, 5, 37, 13],
// 15
[5, 109, 87, 1, 110, 88],
[5, 65, 41, 5, 66, 42],
[5, 54, 24, 7, 55, 25],
[11, 36, 12],
// 16
[5, 122, 98, 1, 123, 99],
[7, 73, 45, 3, 74, 46],
[15, 43, 19, 2, 44, 20],
[3, 45, 15, 13, 46, 16],
// 17
[1, 135, 107, 5, 136, 108],
[10, 74, 46, 1, 75, 47],
[1, 50, 22, 15, 51, 23],
[2, 42, 14, 17, 43, 15],
// 18
[5, 150, 120, 1, 151, 121],
[9, 69, 43, 4, 70, 44],
[17, 50, 22, 1, 51, 23],
[2, 42, 14, 19, 43, 15],
// 19
[3, 141, 113, 4, 142, 114],
[3, 70, 44, 11, 71, 45],
[17, 47, 21, 4, 48, 22],
[9, 39, 13, 16, 40, 14],
// 20
[3, 135, 107, 5, 136, 108],
[3, 67, 41, 13, 68, 42],
[15, 54, 24, 5, 55, 25],
[15, 43, 15, 10, 44, 16],
// 21
[4, 144, 116, 4, 145, 117],
[17, 68, 42],
[17, 50, 22, 6, 51, 23],
[19, 46, 16, 6, 47, 17],
// 22
[2, 139, 111, 7, 140, 112],
[17, 74, 46],
[7, 54, 24, 16, 55, 25],
[34, 37, 13],
// 23
[4, 151, 121, 5, 152, 122],
[4, 75, 47, 14, 76, 48],
[11, 54, 24, 14, 55, 25],
[16, 45, 15, 14, 46, 16],
// 24
[6, 147, 117, 4, 148, 118],
[6, 73, 45, 14, 74, 46],
[11, 54, 24, 16, 55, 25],
[30, 46, 16, 2, 47, 17],
// 25
[8, 132, 106, 4, 133, 107],
[8, 75, 47, 13, 76, 48],
[7, 54, 24, 22, 55, 25],
[22, 45, 15, 13, 46, 16],
// 26
[10, 142, 114, 2, 143, 115],
[19, 74, 46, 4, 75, 47],
[28, 50, 22, 6, 51, 23],
[33, 46, 16, 4, 47, 17],
// 27
[8, 152, 122, 4, 153, 123],
[22, 73, 45, 3, 74, 46],
[8, 53, 23, 26, 54, 24],
[12, 45, 15, 28, 46, 16],
// 28
[3, 147, 117, 10, 148, 118],
[3, 73, 45, 23, 74, 46],
[4, 54, 24, 31, 55, 25],
[11, 45, 15, 31, 46, 16],
// 29
[7, 146, 116, 7, 147, 117],
[21, 73, 45, 7, 74, 46],
[1, 53, 23, 37, 54, 24],
[19, 45, 15, 26, 46, 16],
// 30
[5, 145, 115, 10, 146, 116],
[19, 75, 47, 10, 76, 48],
[15, 54, 24, 25, 55, 25],
[23, 45, 15, 25, 46, 16],
// 31
[13, 145, 115, 3, 146, 116],
[2, 74, 46, 29, 75, 47],
[42, 54, 24, 1, 55, 25],
[23, 45, 15, 28, 46, 16],
// 32
[17, 145, 115],
[10, 74, 46, 23, 75, 47],
[10, 54, 24, 35, 55, 25],
[19, 45, 15, 35, 46, 16],
// 33
[17, 145, 115, 1, 146, 116],
[14, 74, 46, 21, 75, 47],
[29, 54, 24, 19, 55, 25],
[11, 45, 15, 46, 46, 16],
// 34
[13, 145, 115, 6, 146, 116],
[14, 74, 46, 23, 75, 47],
[44, 54, 24, 7, 55, 25],
[59, 46, 16, 1, 47, 17],
// 35
[12, 151, 121, 7, 152, 122],
[12, 75, 47, 26, 76, 48],
[39, 54, 24, 14, 55, 25],
[22, 45, 15, 41, 46, 16],
// 36
[6, 151, 121, 14, 152, 122],
[6, 75, 47, 34, 76, 48],
[46, 54, 24, 10, 55, 25],
[2, 45, 15, 64, 46, 16],
// 37
[17, 152, 122, 4, 153, 123],
[29, 74, 46, 14, 75, 47],
[49, 54, 24, 10, 55, 25],
[24, 45, 15, 46, 46, 16],
// 38
[4, 152, 122, 18, 153, 123],
[13, 74, 46, 32, 75, 47],
[48, 54, 24, 14, 55, 25],
[42, 45, 15, 32, 46, 16],
// 39
[20, 147, 117, 4, 148, 118],
[40, 75, 47, 7, 76, 48],
[43, 54, 24, 22, 55, 25],
[10, 45, 15, 67, 46, 16],
// 40
[19, 148, 118, 6, 149, 119],
[18, 75, 47, 31, 76, 48],
[34, 54, 24, 34, 55, 25],
[20, 45, 15, 61, 46, 16]
];
/**
* 根据数据获取对应版本
* @return {[type]} [description]
*/
QRCodeAlg.prototype.getRightType = function () {
for (var typeNumber = 1; typeNumber < 41; typeNumber++) {
var rsBlock = RS_BLOCK_TABLE[(typeNumber - 1) * 4 + this.errorCorrectLevel];
if (rsBlock == undefined) {
throw new Error("bad rs block @ typeNumber:" + typeNumber + "/errorCorrectLevel:" + this.errorCorrectLevel);
}
var length = rsBlock.length / 3;
var totalDataCount = 0;
for (var i = 0; i < length; i++) {
var count = rsBlock[i * 3 + 0];
var dataCount = rsBlock[i * 3 + 2];
totalDataCount += dataCount * count;
}
var lengthBytes = typeNumber > 9 ? 2 : 1;
if (this.utf8bytes.length + lengthBytes < totalDataCount || typeNumber == 40) {
this.typeNumber = typeNumber;
this.rsBlock = rsBlock;
this.totalDataCount = totalDataCount;
break;
}
}
};
//---------------------------------------------------------------------
// QRBitBuffer
//---------------------------------------------------------------------
function QRBitBuffer() {
this.buffer = new Array();
this.length = 0;
}
QRBitBuffer.prototype = {
get: function (index) {
var bufIndex = Math.floor(index / 8);
return ((this.buffer[bufIndex] >>> (7 - index % 8)) & 1);
},
put: function (num, length) {
for (var i = 0; i < length; i++) {
this.putBit(((num >>> (length - i - 1)) & 1));
}
},
putBit: function (bit) {
var bufIndex = Math.floor(this.length / 8);
if (this.buffer.length <= bufIndex) {
this.buffer.push(0);
}
if (bit) {
this.buffer[bufIndex] |= (0x80 >>> (this.length % 8));
}
this.length++;
}
};
// xzedit
let qrcodeAlgObjCache = [];
/**
* 二维码构造函数,主要用于绘制
* @param {参数列表} opt 传递参数
* @return {}
*/
QRCode = function (opt) {
//设置默认参数
this.options = {
text: '',
size: 256,
correctLevel: 3,
background: '#ffffff',
foreground: '#000000',
pdground: '#000000',
image: '',
imageSize: 30,
canvasId: opt.canvasId,
context: opt.context,
usingComponents: opt.usingComponents,
showLoading: opt.showLoading,
loadingText: opt.loadingText,
};
if (typeof opt === 'string') { // 只编码ASCII字符串
opt = {
text: opt
};
}
if (opt) {
for (var i in opt) {
this.options[i] = opt[i];
}
}
//使用QRCodeAlg创建二维码结构
var qrCodeAlg = null;
for (var i = 0, l = qrcodeAlgObjCache.length; i < l; i++) {
if (qrcodeAlgObjCache[i].text == this.options.text && qrcodeAlgObjCache[i].text.correctLevel == this.options.correctLevel) {
qrCodeAlg = qrcodeAlgObjCache[i].obj;
break;
}
}
if (i == l) {
qrCodeAlg = new QRCodeAlg(this.options.text, this.options.correctLevel);
qrcodeAlgObjCache.push({
text: this.options.text,
correctLevel: this.options.correctLevel,
obj: qrCodeAlg
});
}
/**
* 计算矩阵点的前景色
* @param {Obj} config
* @param {Number} config.row 点x坐标
* @param {Number} config.col 点y坐标
* @param {Number} config.count 矩阵大小
* @param {Number} config.options 组件的options
* @return {String}
*/
let getForeGround = function (config) {
var options = config.options;
if (options.pdground && (
(config.row > 1 && config.row < 5 && config.col > 1 && config.col < 5) ||
(config.row > (config.count - 6) && config.row < (config.count - 2) && config.col > 1 && config.col < 5) ||
(config.row > 1 && config.row < 5 && config.col > (config.count - 6) && config.col < (config.count - 2))
)) {
return options.pdground;
}
return options.foreground;
}
// 创建canvas
let createCanvas = function (options) {
if(options.showLoading){
uni.showLoading({
title: options.loadingText,
mask: true
});
}
var ctx = uni.createCanvasContext(options.canvasId, options.context);
var count = qrCodeAlg.getModuleCount();
var ratioSize = options.size;
var ratioImgSize = options.imageSize;
//计算每个点的长宽
var tileW = (ratioSize / count).toPrecision(4);
var tileH = (ratioSize / count).toPrecision(4);
//绘制
for (var row = 0; row < count; row++) {
for (var col = 0; col < count; col++) {
var w = (Math.ceil((col + 1) * tileW) - Math.floor(col * tileW));
var h = (Math.ceil((row + 1) * tileW) - Math.floor(row * tileW));
var foreground = getForeGround({
row: row,
col: col,
count: count,
options: options
});
ctx.setFillStyle(qrCodeAlg.modules[row][col] ? foreground : options.background);
ctx.fillRect(Math.round(col * tileW), Math.round(row * tileH), w, h);
}
}
if (options.image) {
var x = Number(((ratioSize - ratioImgSize) / 2).toFixed(2));
var y = Number(((ratioSize - ratioImgSize) / 2).toFixed(2));
drawRoundedRect(ctx, x, y, ratioImgSize, ratioImgSize, 2, 6, true, true)
ctx.drawImage(options.image, x, y, ratioImgSize, ratioImgSize);
// 画圆角矩形
function drawRoundedRect(ctxi, x, y, width, height, r, lineWidth, fill, stroke) {
ctxi.setLineWidth(lineWidth);
ctxi.setFillStyle(options.background);
ctxi.setStrokeStyle(options.background);
ctxi.beginPath(); // draw top and top right corner
ctxi.moveTo(x + r, y);
ctxi.arcTo(x + width, y, x + width, y + r, r); // draw right side and bottom right corner
ctxi.arcTo(x + width, y + height, x + width - r, y + height, r); // draw bottom and bottom left corner
ctxi.arcTo(x, y + height, x, y + height - r, r); // draw left and top left corner
ctxi.arcTo(x, y, x + r, y, r);
ctxi.closePath();
if (fill) {
ctxi.fill();
}
if (stroke) {
ctxi.stroke();
}
}
}
setTimeout(() => {
ctx.draw(true, () => {
// 保存到临时区域
setTimeout(() => {
uni.canvasToTempFilePath({
width: options.width,
height: options.height,
destWidth: options.width,
destHeight: options.height,
canvasId: options.canvasId,
quality: Number(1),
success: function (res) {
if (options.cbResult) {
// 由于官方还没有统一此接口的输出字段,所以先判定下 支付宝为 res.apFilePath
if (!empty(res.tempFilePath)) {
options.cbResult(res.tempFilePath)
} else if (!empty(res.apFilePath)) {
options.cbResult(res.apFilePath)
} else {
options.cbResult(res.tempFilePath)
}
}
},
fail: function (res) {
if (options.cbResult) {
options.cbResult(res)
}
},
complete: function () {
uni.hideLoading();
},
}, options.context);
}, options.text.length + 100);
});
}, options.usingComponents ? 0 : 150);
}
createCanvas(this.options);
// 空判定
let empty = function (v) {
let tp = typeof v,
rt = false;
if (tp == "number" && String(v) == "") {
rt = true
} else if (tp == "undefined") {
rt = true
} else if (tp == "object") {
if (JSON.stringify(v) == "{}" || JSON.stringify(v) == "[]" || v == null) rt = true
} else if (tp == "string") {
if (v == "" || v == "undefined" || v == "null" || v == "{}" || v == "[]") rt = true
} else if (tp == "function") {
rt = false
}
return rt
}
};
QRCode.prototype.clear = function (fn) {
var ctx = uni.createCanvasContext(this.options.canvasId, this.options.context)
ctx.clearRect(0, 0, this.options.size, this.options.size)
ctx.draw(false, () => {
if (fn) {
fn()
}
})
};
})()
export default QRCode
\ No newline at end of file
<template xlang="wxml" minapp="mpvue">
<view class="tki-qrcode">
<canvas class="tki-qrcode-canvas" :canvas-id="cid" :style="{width:cpSize+'px',height:cpSize+'px'}" />
<image v-show="show" :src="result" :style="{width:cpSize+'px',height:cpSize+'px'}" />
</view>
</template>
<script>
import QRCode from "./qrcode.js"
let qrcode
export default {
name: "tki-qrcode",
props: {
cid: {
type: String,
default: 'tki-qrcode-canvas'
},
size: {
type: Number,
default: 200
},
unit: {
type: String,
default: 'upx'
},
show: {
type: Boolean,
default: true
},
val: {
type: String,
default: ''
},
background: {
type: String,
default: '#ffffff'
},
foreground: {
type: String,
default: '#000000'
},
pdground: {
type: String,
default: '#000000'
},
icon: {
type: String,
default: ''
},
iconSize: {
type: Number,
default: 40
},
lv: {
type: Number,
default: 3
},
onval: {
type: Boolean,
default: false
},
loadMake: {
type: Boolean,
default: false
},
usingComponents: {
type: Boolean,
default: true
},
showLoading: {
type: Boolean,
default: true
},
loadingText: {
type: String,
default: '二维码生成中'
},
},
data() {
return {
result: '',
}
},
methods: {
_makeCode() {
let that = this
if (!this._empty(this.val)) {
qrcode = new QRCode({
context: that, // 上下文环境
canvasId:that.cid, // canvas-id
usingComponents: that.usingComponents, // 是否是自定义组件
showLoading: that.showLoading, // 是否显示loading
loadingText: that.loadingText, // loading文字
text: that.val, // 生成内容
size: that.cpSize, // 二维码大小
background: that.background, // 背景色
foreground: that.foreground, // 前景色
pdground: that.pdground, // 定位角点颜色
correctLevel: that.lv, // 容错级别
image: that.icon, // 二维码图标
imageSize: that.iconSize,// 二维码图标大小
cbResult: function (res) { // 生成二维码的回调
that._result(res)
},
});
} else {
uni.showToast({
title: '二维码内容不能为空',
icon: 'none',
duration: 2000
});
}
},
_clearCode() {
this._result('')
qrcode.clear()
},
_saveCode() {
let that = this;
if (this.result != "") {
uni.saveImageToPhotosAlbum({
filePath: that.result,
success: function () {
uni.showToast({
title: '二维码保存成功',
icon: 'success',
duration: 2000
});
}
});
}
},
_result(res) {
this.result = res;
this.$emit('result', res)
},
_empty(v) {
let tp = typeof v,
rt = false;
if (tp == "number" && String(v) == "") {
rt = true
} else if (tp == "undefined") {
rt = true
} else if (tp == "object") {
if (JSON.stringify(v) == "{}" || JSON.stringify(v) == "[]" || v == null) rt = true
} else if (tp == "string") {
if (v == "" || v == "undefined" || v == "null" || v == "{}" || v == "[]") rt = true
} else if (tp == "function") {
rt = false
}
return rt
}
},
watch: {
size: function (n, o) {
if (n != o && !this._empty(n)) {
this.cSize = n
if (!this._empty(this.val)) {
setTimeout(() => {
this._makeCode()
}, 100);
}
}
},
val: function (n, o) {
if (this.onval) {
if (n != o && !this._empty(n)) {
setTimeout(() => {
this._makeCode()
}, 0);
}
}
}
},
computed: {
cpSize() {
if(this.unit == "upx"){
return uni.upx2px(this.size)
}else{
return this.size
}
}
},
mounted: function () {
if (this.loadMake) {
if (!this._empty(this.val)) {
setTimeout(() => {
this._makeCode()
}, 0);
}
}
},
}
</script>
<style>
.tki-qrcode {
position: relative;
}
.tki-qrcode-canvas {
position: fixed;
top: -99999upx;
left: -99999upx;
z-index: -99999;
}
</style>
......@@ -22,7 +22,7 @@ switch (appId) {
config.domain = 'https://minzhisheng.mynatapp.cc'
config.urlBase = 'http://139.159.137.113:9080/api/'
config.urlUpload = ''
config.urlRes = ''
config.urlRes = '@/static/image/'
config.other.clientId = 'oauth'
config.other.clientSecret = 'b1e34c71-3e25-4db4-9c93-2b5a0bf95fe9'
break
......
{
"name": "hongai-i-doctor",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"dependencies": {
"tki-qrcode": "^0.1.6"
},
"devDependencies": {
"eslint": "^8.2.0",
"eslint-config-airbnb": "^19.0.0"
}
},
"node_modules/@eslint/eslintrc": {
"version": "1.2.2",
"dev": true,
"license": "MIT",
"dependencies": {
"ajv": "^6.12.4",
"debug": "^4.3.2",
"espree": "^9.3.1",
"globals": "^13.9.0",
"ignore": "^5.2.0",
"import-fresh": "^3.2.1",
"js-yaml": "^4.1.0",
"minimatch": "^3.0.4",
"strip-json-comments": "^3.1.1"
},
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
}
},
"node_modules/@humanwhocodes/config-array": {
"version": "0.9.5",
"dev": true,
"license": "Apache-2.0",
"dependencies": {
"@humanwhocodes/object-schema": "^1.2.1",
"debug": "^4.1.1",
"minimatch": "^3.0.4"
},
"engines": {
"node": ">=10.10.0"
}
},
"node_modules/@humanwhocodes/object-schema": {
"version": "1.2.1",
"dev": true,
"license": "BSD-3-Clause"
},
"node_modules/acorn": {
"version": "8.7.1",
"dev": true,
"license": "MIT",
"bin": {
"acorn": "bin/acorn"
},
"engines": {
"node": ">=0.4.0"
}
},
"node_modules/acorn-jsx": {
"version": "5.3.2",
"dev": true,
"license": "MIT",
"peerDependencies": {
"acorn": "^6.0.0 || ^7.0.0 || ^8.0.0"
}
},
"node_modules/ajv": {
"version": "6.12.6",
"dev": true,
"license": "MIT",
"dependencies": {
"fast-deep-equal": "^3.1.1",
"fast-json-stable-stringify": "^2.0.0",
"json-schema-traverse": "^0.4.1",
"uri-js": "^4.2.2"
},
"funding": {
"type": "github",
"url": "https://github.com/sponsors/epoberezkin"
}
},
"node_modules/ansi-regex": {
"version": "5.0.1",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
}
},
"node_modules/ansi-styles": {
"version": "4.3.0",
"dev": true,
"license": "MIT",
"dependencies": {
"color-convert": "^2.0.1"
},
"engines": {
"node": ">=8"
},
"funding": {
"url": "https://github.com/chalk/ansi-styles?sponsor=1"
}
},
"node_modules/argparse": {
"version": "2.0.1",
"dev": true,
"license": "Python-2.0"
},
"node_modules/balanced-match": {
"version": "1.0.2",
"dev": true,
"license": "MIT"
},
"node_modules/brace-expansion": {
"version": "1.1.11",
"dev": true,
"license": "MIT",
"dependencies": {
"balanced-match": "^1.0.0",
"concat-map": "0.0.1"
}
},
"node_modules/call-bind": {
"version": "1.0.2",
"dev": true,
"license": "MIT",
"dependencies": {
"function-bind": "^1.1.1",
"get-intrinsic": "^1.0.2"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/callsites": {
"version": "3.1.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=6"
}
},
"node_modules/chalk": {
"version": "4.1.2",
"dev": true,
"license": "MIT",
"dependencies": {
"ansi-styles": "^4.1.0",
"supports-color": "^7.1.0"
},
"engines": {
"node": ">=10"
},
"funding": {
"url": "https://github.com/chalk/chalk?sponsor=1"
}
},
"node_modules/color-convert": {
"version": "2.0.1",
"dev": true,
"license": "MIT",
"dependencies": {
"color-name": "~1.1.4"
},
"engines": {
"node": ">=7.0.0"
}
},
"node_modules/color-name": {
"version": "1.1.4",
"dev": true,
"license": "MIT"
},
"node_modules/concat-map": {
"version": "0.0.1",
"dev": true,
"license": "MIT"
},
"node_modules/confusing-browser-globals": {
"version": "1.0.11",
"dev": true,
"license": "MIT"
},
"node_modules/cross-spawn": {
"version": "7.0.3",
"dev": true,
"license": "MIT",
"dependencies": {
"path-key": "^3.1.0",
"shebang-command": "^2.0.0",
"which": "^2.0.1"
},
"engines": {
"node": ">= 8"
}
},
"node_modules/debug": {
"version": "4.3.4",
"dev": true,
"license": "MIT",
"dependencies": {
"ms": "2.1.2"
},
"engines": {
"node": ">=6.0"
},
"peerDependenciesMeta": {
"supports-color": {
"optional": true
}
}
},
"node_modules/deep-is": {
"version": "0.1.4",
"dev": true,
"license": "MIT"
},
"node_modules/define-properties": {
"version": "1.1.4",
"dev": true,
"license": "MIT",
"dependencies": {
"has-property-descriptors": "^1.0.0",
"object-keys": "^1.1.1"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/doctrine": {
"version": "3.0.0",
"dev": true,
"license": "Apache-2.0",
"dependencies": {
"esutils": "^2.0.2"
},
"engines": {
"node": ">=6.0.0"
}
},
"node_modules/es-abstract": {
"version": "1.19.5",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.2",
"es-to-primitive": "^1.2.1",
"function-bind": "^1.1.1",
"get-intrinsic": "^1.1.1",
"get-symbol-description": "^1.0.0",
"has": "^1.0.3",
"has-symbols": "^1.0.3",
"internal-slot": "^1.0.3",
"is-callable": "^1.2.4",
"is-negative-zero": "^2.0.2",
"is-regex": "^1.1.4",
"is-shared-array-buffer": "^1.0.2",
"is-string": "^1.0.7",
"is-weakref": "^1.0.2",
"object-inspect": "^1.12.0",
"object-keys": "^1.1.1",
"object.assign": "^4.1.2",
"string.prototype.trimend": "^1.0.4",
"string.prototype.trimstart": "^1.0.4",
"unbox-primitive": "^1.0.1"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/es-to-primitive": {
"version": "1.2.1",
"dev": true,
"license": "MIT",
"dependencies": {
"is-callable": "^1.1.4",
"is-date-object": "^1.0.1",
"is-symbol": "^1.0.2"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/escape-string-regexp": {
"version": "4.0.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=10"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/eslint": {
"version": "8.14.0",
"dev": true,
"license": "MIT",
"dependencies": {
"@eslint/eslintrc": "^1.2.2",
"@humanwhocodes/config-array": "^0.9.2",
"ajv": "^6.10.0",
"chalk": "^4.0.0",
"cross-spawn": "^7.0.2",
"debug": "^4.3.2",
"doctrine": "^3.0.0",
"escape-string-regexp": "^4.0.0",
"eslint-scope": "^7.1.1",
"eslint-utils": "^3.0.0",
"eslint-visitor-keys": "^3.3.0",
"espree": "^9.3.1",
"esquery": "^1.4.0",
"esutils": "^2.0.2",
"fast-deep-equal": "^3.1.3",
"file-entry-cache": "^6.0.1",
"functional-red-black-tree": "^1.0.1",
"glob-parent": "^6.0.1",
"globals": "^13.6.0",
"ignore": "^5.2.0",
"import-fresh": "^3.0.0",
"imurmurhash": "^0.1.4",
"is-glob": "^4.0.0",
"js-yaml": "^4.1.0",
"json-stable-stringify-without-jsonify": "^1.0.1",
"levn": "^0.4.1",
"lodash.merge": "^4.6.2",
"minimatch": "^3.0.4",
"natural-compare": "^1.4.0",
"optionator": "^0.9.1",
"regexpp": "^3.2.0",
"strip-ansi": "^6.0.1",
"strip-json-comments": "^3.1.0",
"text-table": "^0.2.0",
"v8-compile-cache": "^2.0.3"
},
"bin": {
"eslint": "bin/eslint.js"
},
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
},
"funding": {
"url": "https://opencollective.com/eslint"
}
},
"node_modules/eslint-config-airbnb": {
"version": "19.0.4",
"dev": true,
"license": "MIT",
"dependencies": {
"eslint-config-airbnb-base": "^15.0.0",
"object.assign": "^4.1.2",
"object.entries": "^1.1.5"
},
"engines": {
"node": "^10.12.0 || ^12.22.0 || ^14.17.0 || >=16.0.0"
},
"peerDependencies": {
"eslint": "^7.32.0 || ^8.2.0",
"eslint-plugin-import": "^2.25.3",
"eslint-plugin-jsx-a11y": "^6.5.1",
"eslint-plugin-react": "^7.28.0",
"eslint-plugin-react-hooks": "^4.3.0"
}
},
"node_modules/eslint-config-airbnb-base": {
"version": "15.0.0",
"dev": true,
"license": "MIT",
"dependencies": {
"confusing-browser-globals": "^1.0.10",
"object.assign": "^4.1.2",
"object.entries": "^1.1.5",
"semver": "^6.3.0"
},
"engines": {
"node": "^10.12.0 || >=12.0.0"
},
"peerDependencies": {
"eslint": "^7.32.0 || ^8.2.0",
"eslint-plugin-import": "^2.25.2"
}
},
"node_modules/eslint-scope": {
"version": "7.1.1",
"dev": true,
"license": "BSD-2-Clause",
"dependencies": {
"esrecurse": "^4.3.0",
"estraverse": "^5.2.0"
},
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
}
},
"node_modules/eslint-utils": {
"version": "3.0.0",
"dev": true,
"license": "MIT",
"dependencies": {
"eslint-visitor-keys": "^2.0.0"
},
"engines": {
"node": "^10.0.0 || ^12.0.0 || >= 14.0.0"
},
"funding": {
"url": "https://github.com/sponsors/mysticatea"
},
"peerDependencies": {
"eslint": ">=5"
}
},
"node_modules/eslint-utils/node_modules/eslint-visitor-keys": {
"version": "2.1.0",
"dev": true,
"license": "Apache-2.0",
"engines": {
"node": ">=10"
}
},
"node_modules/eslint-visitor-keys": {
"version": "3.3.0",
"dev": true,
"license": "Apache-2.0",
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
}
},
"node_modules/espree": {
"version": "9.3.1",
"dev": true,
"license": "BSD-2-Clause",
"dependencies": {
"acorn": "^8.7.0",
"acorn-jsx": "^5.3.1",
"eslint-visitor-keys": "^3.3.0"
},
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
}
},
"node_modules/esquery": {
"version": "1.4.0",
"dev": true,
"license": "BSD-3-Clause",
"dependencies": {
"estraverse": "^5.1.0"
},
"engines": {
"node": ">=0.10"
}
},
"node_modules/esrecurse": {
"version": "4.3.0",
"dev": true,
"license": "BSD-2-Clause",
"dependencies": {
"estraverse": "^5.2.0"
},
"engines": {
"node": ">=4.0"
}
},
"node_modules/estraverse": {
"version": "5.3.0",
"dev": true,
"license": "BSD-2-Clause",
"engines": {
"node": ">=4.0"
}
},
"node_modules/esutils": {
"version": "2.0.3",
"dev": true,
"license": "BSD-2-Clause",
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/fast-deep-equal": {
"version": "3.1.3",
"dev": true,
"license": "MIT"
},
"node_modules/fast-json-stable-stringify": {
"version": "2.1.0",
"dev": true,
"license": "MIT"
},
"node_modules/fast-levenshtein": {
"version": "2.0.6",
"dev": true,
"license": "MIT"
},
"node_modules/file-entry-cache": {
"version": "6.0.1",
"dev": true,
"license": "MIT",
"dependencies": {
"flat-cache": "^3.0.4"
},
"engines": {
"node": "^10.12.0 || >=12.0.0"
}
},
"node_modules/flat-cache": {
"version": "3.0.4",
"dev": true,
"license": "MIT",
"dependencies": {
"flatted": "^3.1.0",
"rimraf": "^3.0.2"
},
"engines": {
"node": "^10.12.0 || >=12.0.0"
}
},
"node_modules/flatted": {
"version": "3.2.5",
"dev": true,
"license": "ISC"
},
"node_modules/fs.realpath": {
"version": "1.0.0",
"dev": true,
"license": "ISC"
},
"node_modules/function-bind": {
"version": "1.1.1",
"dev": true,
"license": "MIT"
},
"node_modules/functional-red-black-tree": {
"version": "1.0.1",
"dev": true,
"license": "MIT"
},
"node_modules/get-intrinsic": {
"version": "1.1.1",
"dev": true,
"license": "MIT",
"dependencies": {
"function-bind": "^1.1.1",
"has": "^1.0.3",
"has-symbols": "^1.0.1"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/get-symbol-description": {
"version": "1.0.0",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.2",
"get-intrinsic": "^1.1.1"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/glob": {
"version": "7.2.0",
"dev": true,
"license": "ISC",
"dependencies": {
"fs.realpath": "^1.0.0",
"inflight": "^1.0.4",
"inherits": "2",
"minimatch": "^3.0.4",
"once": "^1.3.0",
"path-is-absolute": "^1.0.0"
},
"engines": {
"node": "*"
},
"funding": {
"url": "https://github.com/sponsors/isaacs"
}
},
"node_modules/glob-parent": {
"version": "6.0.2",
"dev": true,
"license": "ISC",
"dependencies": {
"is-glob": "^4.0.3"
},
"engines": {
"node": ">=10.13.0"
}
},
"node_modules/globals": {
"version": "13.13.0",
"dev": true,
"license": "MIT",
"dependencies": {
"type-fest": "^0.20.2"
},
"engines": {
"node": ">=8"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/has": {
"version": "1.0.3",
"dev": true,
"license": "MIT",
"dependencies": {
"function-bind": "^1.1.1"
},
"engines": {
"node": ">= 0.4.0"
}
},
"node_modules/has-bigints": {
"version": "1.0.2",
"dev": true,
"license": "MIT",
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/has-flag": {
"version": "4.0.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
}
},
"node_modules/has-property-descriptors": {
"version": "1.0.0",
"dev": true,
"license": "MIT",
"dependencies": {
"get-intrinsic": "^1.1.1"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/has-symbols": {
"version": "1.0.3",
"dev": true,
"license": "MIT",
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/has-tostringtag": {
"version": "1.0.0",
"dev": true,
"license": "MIT",
"dependencies": {
"has-symbols": "^1.0.2"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/ignore": {
"version": "5.2.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">= 4"
}
},
"node_modules/import-fresh": {
"version": "3.3.0",
"dev": true,
"license": "MIT",
"dependencies": {
"parent-module": "^1.0.0",
"resolve-from": "^4.0.0"
},
"engines": {
"node": ">=6"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/imurmurhash": {
"version": "0.1.4",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=0.8.19"
}
},
"node_modules/inflight": {
"version": "1.0.6",
"dev": true,
"license": "ISC",
"dependencies": {
"once": "^1.3.0",
"wrappy": "1"
}
},
"node_modules/inherits": {
"version": "2.0.4",
"dev": true,
"license": "ISC"
},
"node_modules/internal-slot": {
"version": "1.0.3",
"dev": true,
"license": "MIT",
"dependencies": {
"get-intrinsic": "^1.1.0",
"has": "^1.0.3",
"side-channel": "^1.0.4"
},
"engines": {
"node": ">= 0.4"
}
},
"node_modules/is-bigint": {
"version": "1.0.4",
"dev": true,
"license": "MIT",
"dependencies": {
"has-bigints": "^1.0.1"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/is-boolean-object": {
"version": "1.1.2",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.2",
"has-tostringtag": "^1.0.0"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/is-callable": {
"version": "1.2.4",
"dev": true,
"license": "MIT",
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/is-date-object": {
"version": "1.0.5",
"dev": true,
"license": "MIT",
"dependencies": {
"has-tostringtag": "^1.0.0"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/is-extglob": {
"version": "2.1.1",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/is-glob": {
"version": "4.0.3",
"dev": true,
"license": "MIT",
"dependencies": {
"is-extglob": "^2.1.1"
},
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/is-negative-zero": {
"version": "2.0.2",
"dev": true,
"license": "MIT",
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/is-number-object": {
"version": "1.0.7",
"dev": true,
"license": "MIT",
"dependencies": {
"has-tostringtag": "^1.0.0"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/is-regex": {
"version": "1.1.4",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.2",
"has-tostringtag": "^1.0.0"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/is-shared-array-buffer": {
"version": "1.0.2",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.2"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/is-string": {
"version": "1.0.7",
"dev": true,
"license": "MIT",
"dependencies": {
"has-tostringtag": "^1.0.0"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/is-symbol": {
"version": "1.0.4",
"dev": true,
"license": "MIT",
"dependencies": {
"has-symbols": "^1.0.2"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/is-weakref": {
"version": "1.0.2",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.2"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/isexe": {
"version": "2.0.0",
"dev": true,
"license": "ISC"
},
"node_modules/js-yaml": {
"version": "4.1.0",
"dev": true,
"license": "MIT",
"dependencies": {
"argparse": "^2.0.1"
},
"bin": {
"js-yaml": "bin/js-yaml.js"
}
},
"node_modules/json-schema-traverse": {
"version": "0.4.1",
"dev": true,
"license": "MIT"
},
"node_modules/json-stable-stringify-without-jsonify": {
"version": "1.0.1",
"dev": true,
"license": "MIT"
},
"node_modules/levn": {
"version": "0.4.1",
"dev": true,
"license": "MIT",
"dependencies": {
"prelude-ls": "^1.2.1",
"type-check": "~0.4.0"
},
"engines": {
"node": ">= 0.8.0"
}
},
"node_modules/lodash.merge": {
"version": "4.6.2",
"dev": true,
"license": "MIT"
},
"node_modules/minimatch": {
"version": "3.1.2",
"dev": true,
"license": "ISC",
"dependencies": {
"brace-expansion": "^1.1.7"
},
"engines": {
"node": "*"
}
},
"node_modules/ms": {
"version": "2.1.2",
"dev": true,
"license": "MIT"
},
"node_modules/natural-compare": {
"version": "1.4.0",
"dev": true,
"license": "MIT"
},
"node_modules/object-inspect": {
"version": "1.12.0",
"dev": true,
"license": "MIT",
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/object-keys": {
"version": "1.1.1",
"dev": true,
"license": "MIT",
"engines": {
"node": ">= 0.4"
}
},
"node_modules/object.assign": {
"version": "4.1.2",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.0",
"define-properties": "^1.1.3",
"has-symbols": "^1.0.1",
"object-keys": "^1.1.1"
},
"engines": {
"node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/object.entries": {
"version": "1.1.5",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.2",
"define-properties": "^1.1.3",
"es-abstract": "^1.19.1"
},
"engines": {
"node": ">= 0.4"
}
},
"node_modules/once": {
"version": "1.4.0",
"dev": true,
"license": "ISC",
"dependencies": {
"wrappy": "1"
}
},
"node_modules/optionator": {
"version": "0.9.1",
"dev": true,
"license": "MIT",
"dependencies": {
"deep-is": "^0.1.3",
"fast-levenshtein": "^2.0.6",
"levn": "^0.4.1",
"prelude-ls": "^1.2.1",
"type-check": "^0.4.0",
"word-wrap": "^1.2.3"
},
"engines": {
"node": ">= 0.8.0"
}
},
"node_modules/parent-module": {
"version": "1.0.1",
"dev": true,
"license": "MIT",
"dependencies": {
"callsites": "^3.0.0"
},
"engines": {
"node": ">=6"
}
},
"node_modules/path-is-absolute": {
"version": "1.0.1",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/path-key": {
"version": "3.1.1",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
}
},
"node_modules/prelude-ls": {
"version": "1.2.1",
"dev": true,
"license": "MIT",
"engines": {
"node": ">= 0.8.0"
}
},
"node_modules/punycode": {
"version": "2.1.1",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=6"
}
},
"node_modules/regexpp": {
"version": "3.2.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
},
"funding": {
"url": "https://github.com/sponsors/mysticatea"
}
},
"node_modules/resolve-from": {
"version": "4.0.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=4"
}
},
"node_modules/rimraf": {
"version": "3.0.2",
"dev": true,
"license": "ISC",
"dependencies": {
"glob": "^7.1.3"
},
"bin": {
"rimraf": "bin.js"
},
"funding": {
"url": "https://github.com/sponsors/isaacs"
}
},
"node_modules/semver": {
"version": "6.3.0",
"dev": true,
"license": "ISC",
"bin": {
"semver": "bin/semver.js"
}
},
"node_modules/shebang-command": {
"version": "2.0.0",
"dev": true,
"license": "MIT",
"dependencies": {
"shebang-regex": "^3.0.0"
},
"engines": {
"node": ">=8"
}
},
"node_modules/shebang-regex": {
"version": "3.0.0",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
}
},
"node_modules/side-channel": {
"version": "1.0.4",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.0",
"get-intrinsic": "^1.0.2",
"object-inspect": "^1.9.0"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/string.prototype.trimend": {
"version": "1.0.4",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.2",
"define-properties": "^1.1.3"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/string.prototype.trimstart": {
"version": "1.0.4",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.2",
"define-properties": "^1.1.3"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/strip-ansi": {
"version": "6.0.1",
"dev": true,
"license": "MIT",
"dependencies": {
"ansi-regex": "^5.0.1"
},
"engines": {
"node": ">=8"
}
},
"node_modules/strip-json-comments": {
"version": "3.1.1",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/supports-color": {
"version": "7.2.0",
"dev": true,
"license": "MIT",
"dependencies": {
"has-flag": "^4.0.0"
},
"engines": {
"node": ">=8"
}
},
"node_modules/text-table": {
"version": "0.2.0",
"dev": true,
"license": "MIT"
},
"node_modules/tki-qrcode": {
"version": "0.1.6",
"resolved": "https://registry.npmmirror.com/tki-qrcode/-/tki-qrcode-0.1.6.tgz",
"integrity": "sha512-EnnlS8psowC7PsW3MDYcxvJYkuklX3WAZ/BYanR4TdBHTu74GfjTBX8Y16REP+AeDENiVtBPh4jtTRL2P736hQ=="
},
"node_modules/type-check": {
"version": "0.4.0",
"dev": true,
"license": "MIT",
"dependencies": {
"prelude-ls": "^1.2.1"
},
"engines": {
"node": ">= 0.8.0"
}
},
"node_modules/type-fest": {
"version": "0.20.2",
"dev": true,
"license": "(MIT OR CC0-1.0)",
"engines": {
"node": ">=10"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/unbox-primitive": {
"version": "1.0.2",
"dev": true,
"license": "MIT",
"dependencies": {
"call-bind": "^1.0.2",
"has-bigints": "^1.0.2",
"has-symbols": "^1.0.3",
"which-boxed-primitive": "^1.0.2"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/uri-js": {
"version": "4.4.1",
"dev": true,
"license": "BSD-2-Clause",
"dependencies": {
"punycode": "^2.1.0"
}
},
"node_modules/v8-compile-cache": {
"version": "2.3.0",
"dev": true,
"license": "MIT"
},
"node_modules/which": {
"version": "2.0.2",
"dev": true,
"license": "ISC",
"dependencies": {
"isexe": "^2.0.0"
},
"bin": {
"node-which": "bin/node-which"
},
"engines": {
"node": ">= 8"
}
},
"node_modules/which-boxed-primitive": {
"version": "1.0.2",
"dev": true,
"license": "MIT",
"dependencies": {
"is-bigint": "^1.0.1",
"is-boolean-object": "^1.1.0",
"is-number-object": "^1.0.4",
"is-string": "^1.0.5",
"is-symbol": "^1.0.3"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
}
},
"node_modules/word-wrap": {
"version": "1.2.3",
"dev": true,
"license": "MIT",
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/wrappy": {
"version": "1.0.2",
"dev": true,
"license": "ISC"
}
},
"dependencies": {
"@eslint/eslintrc": {
"version": "1.2.2",
"dev": true,
"requires": {
"ajv": "^6.12.4",
"debug": "^4.3.2",
"espree": "^9.3.1",
"globals": "^13.9.0",
"ignore": "^5.2.0",
"import-fresh": "^3.2.1",
"js-yaml": "^4.1.0",
"minimatch": "^3.0.4",
"strip-json-comments": "^3.1.1"
}
},
"@humanwhocodes/config-array": {
"version": "0.9.5",
"dev": true,
"requires": {
"@humanwhocodes/object-schema": "^1.2.1",
"debug": "^4.1.1",
"minimatch": "^3.0.4"
}
},
"@humanwhocodes/object-schema": {
"version": "1.2.1",
"dev": true
},
"acorn": {
"version": "8.7.1",
"dev": true
},
"acorn-jsx": {
"version": "5.3.2",
"dev": true,
"requires": {}
},
"ajv": {
"version": "6.12.6",
"dev": true,
"requires": {
"fast-deep-equal": "^3.1.1",
"fast-json-stable-stringify": "^2.0.0",
"json-schema-traverse": "^0.4.1",
"uri-js": "^4.2.2"
}
},
"ansi-regex": {
"version": "5.0.1",
"dev": true
},
"ansi-styles": {
"version": "4.3.0",
"dev": true,
"requires": {
"color-convert": "^2.0.1"
}
},
"argparse": {
"version": "2.0.1",
"dev": true
},
"balanced-match": {
"version": "1.0.2",
"dev": true
},
"brace-expansion": {
"version": "1.1.11",
"dev": true,
"requires": {
"balanced-match": "^1.0.0",
"concat-map": "0.0.1"
}
},
"call-bind": {
"version": "1.0.2",
"dev": true,
"requires": {
"function-bind": "^1.1.1",
"get-intrinsic": "^1.0.2"
}
},
"callsites": {
"version": "3.1.0",
"dev": true
},
"chalk": {
"version": "4.1.2",
"dev": true,
"requires": {
"ansi-styles": "^4.1.0",
"supports-color": "^7.1.0"
}
},
"color-convert": {
"version": "2.0.1",
"dev": true,
"requires": {
"color-name": "~1.1.4"
}
},
"color-name": {
"version": "1.1.4",
"dev": true
},
"concat-map": {
"version": "0.0.1",
"dev": true
},
"confusing-browser-globals": {
"version": "1.0.11",
"dev": true
},
"cross-spawn": {
"version": "7.0.3",
"dev": true,
"requires": {
"path-key": "^3.1.0",
"shebang-command": "^2.0.0",
"which": "^2.0.1"
}
},
"debug": {
"version": "4.3.4",
"dev": true,
"requires": {
"ms": "2.1.2"
}
},
"deep-is": {
"version": "0.1.4",
"dev": true
},
"define-properties": {
"version": "1.1.4",
"dev": true,
"requires": {
"has-property-descriptors": "^1.0.0",
"object-keys": "^1.1.1"
}
},
"doctrine": {
"version": "3.0.0",
"dev": true,
"requires": {
"esutils": "^2.0.2"
}
},
"es-abstract": {
"version": "1.19.5",
"dev": true,
"requires": {
"call-bind": "^1.0.2",
"es-to-primitive": "^1.2.1",
"function-bind": "^1.1.1",
"get-intrinsic": "^1.1.1",
"get-symbol-description": "^1.0.0",
"has": "^1.0.3",
"has-symbols": "^1.0.3",
"internal-slot": "^1.0.3",
"is-callable": "^1.2.4",
"is-negative-zero": "^2.0.2",
"is-regex": "^1.1.4",
"is-shared-array-buffer": "^1.0.2",
"is-string": "^1.0.7",
"is-weakref": "^1.0.2",
"object-inspect": "^1.12.0",
"object-keys": "^1.1.1",
"object.assign": "^4.1.2",
"string.prototype.trimend": "^1.0.4",
"string.prototype.trimstart": "^1.0.4",
"unbox-primitive": "^1.0.1"
}
},
"es-to-primitive": {
"version": "1.2.1",
"dev": true,
"requires": {
"is-callable": "^1.1.4",
"is-date-object": "^1.0.1",
"is-symbol": "^1.0.2"
}
},
"escape-string-regexp": {
"version": "4.0.0",
"dev": true
},
"eslint": {
"version": "8.14.0",
"dev": true,
"requires": {
"@eslint/eslintrc": "^1.2.2",
"@humanwhocodes/config-array": "^0.9.2",
"ajv": "^6.10.0",
"chalk": "^4.0.0",
"cross-spawn": "^7.0.2",
"debug": "^4.3.2",
"doctrine": "^3.0.0",
"escape-string-regexp": "^4.0.0",
"eslint-scope": "^7.1.1",
"eslint-utils": "^3.0.0",
"eslint-visitor-keys": "^3.3.0",
"espree": "^9.3.1",
"esquery": "^1.4.0",
"esutils": "^2.0.2",
"fast-deep-equal": "^3.1.3",
"file-entry-cache": "^6.0.1",
"functional-red-black-tree": "^1.0.1",
"glob-parent": "^6.0.1",
"globals": "^13.6.0",
"ignore": "^5.2.0",
"import-fresh": "^3.0.0",
"imurmurhash": "^0.1.4",
"is-glob": "^4.0.0",
"js-yaml": "^4.1.0",
"json-stable-stringify-without-jsonify": "^1.0.1",
"levn": "^0.4.1",
"lodash.merge": "^4.6.2",
"minimatch": "^3.0.4",
"natural-compare": "^1.4.0",
"optionator": "^0.9.1",
"regexpp": "^3.2.0",
"strip-ansi": "^6.0.1",
"strip-json-comments": "^3.1.0",
"text-table": "^0.2.0",
"v8-compile-cache": "^2.0.3"
}
},
"eslint-config-airbnb": {
"version": "19.0.4",
"dev": true,
"requires": {
"eslint-config-airbnb-base": "^15.0.0",
"object.assign": "^4.1.2",
"object.entries": "^1.1.5"
}
},
"eslint-config-airbnb-base": {
"version": "15.0.0",
"dev": true,
"requires": {
"confusing-browser-globals": "^1.0.10",
"object.assign": "^4.1.2",
"object.entries": "^1.1.5",
"semver": "^6.3.0"
}
},
"eslint-scope": {
"version": "7.1.1",
"dev": true,
"requires": {
"esrecurse": "^4.3.0",
"estraverse": "^5.2.0"
}
},
"eslint-utils": {
"version": "3.0.0",
"dev": true,
"requires": {
"eslint-visitor-keys": "^2.0.0"
},
"dependencies": {
"eslint-visitor-keys": {
"version": "2.1.0",
"dev": true
}
}
},
"eslint-visitor-keys": {
"version": "3.3.0",
"dev": true
},
"espree": {
"version": "9.3.1",
"dev": true,
"requires": {
"acorn": "^8.7.0",
"acorn-jsx": "^5.3.1",
"eslint-visitor-keys": "^3.3.0"
}
},
"esquery": {
"version": "1.4.0",
"dev": true,
"requires": {
"estraverse": "^5.1.0"
}
},
"esrecurse": {
"version": "4.3.0",
"dev": true,
"requires": {
"estraverse": "^5.2.0"
}
},
"estraverse": {
"version": "5.3.0",
"dev": true
},
"esutils": {
"version": "2.0.3",
"dev": true
},
"fast-deep-equal": {
"version": "3.1.3",
"dev": true
},
"fast-json-stable-stringify": {
"version": "2.1.0",
"dev": true
},
"fast-levenshtein": {
"version": "2.0.6",
"dev": true
},
"file-entry-cache": {
"version": "6.0.1",
"dev": true,
"requires": {
"flat-cache": "^3.0.4"
}
},
"flat-cache": {
"version": "3.0.4",
"dev": true,
"requires": {
"flatted": "^3.1.0",
"rimraf": "^3.0.2"
}
},
"flatted": {
"version": "3.2.5",
"dev": true
},
"fs.realpath": {
"version": "1.0.0",
"dev": true
},
"function-bind": {
"version": "1.1.1",
"dev": true
},
"functional-red-black-tree": {
"version": "1.0.1",
"dev": true
},
"get-intrinsic": {
"version": "1.1.1",
"dev": true,
"requires": {
"function-bind": "^1.1.1",
"has": "^1.0.3",
"has-symbols": "^1.0.1"
}
},
"get-symbol-description": {
"version": "1.0.0",
"dev": true,
"requires": {
"call-bind": "^1.0.2",
"get-intrinsic": "^1.1.1"
}
},
"glob": {
"version": "7.2.0",
"dev": true,
"requires": {
"fs.realpath": "^1.0.0",
"inflight": "^1.0.4",
"inherits": "2",
"minimatch": "^3.0.4",
"once": "^1.3.0",
"path-is-absolute": "^1.0.0"
}
},
"glob-parent": {
"version": "6.0.2",
"dev": true,
"requires": {
"is-glob": "^4.0.3"
}
},
"globals": {
"version": "13.13.0",
"dev": true,
"requires": {
"type-fest": "^0.20.2"
}
},
"has": {
"version": "1.0.3",
"dev": true,
"requires": {
"function-bind": "^1.1.1"
}
},
"has-bigints": {
"version": "1.0.2",
"dev": true
},
"has-flag": {
"version": "4.0.0",
"dev": true
},
"has-property-descriptors": {
"version": "1.0.0",
"dev": true,
"requires": {
"get-intrinsic": "^1.1.1"
}
},
"has-symbols": {
"version": "1.0.3",
"dev": true
},
"has-tostringtag": {
"version": "1.0.0",
"dev": true,
"requires": {
"has-symbols": "^1.0.2"
}
},
"ignore": {
"version": "5.2.0",
"dev": true
},
"import-fresh": {
"version": "3.3.0",
"dev": true,
"requires": {
"parent-module": "^1.0.0",
"resolve-from": "^4.0.0"
}
},
"imurmurhash": {
"version": "0.1.4",
"dev": true
},
"inflight": {
"version": "1.0.6",
"dev": true,
"requires": {
"once": "^1.3.0",
"wrappy": "1"
}
},
"inherits": {
"version": "2.0.4",
"dev": true
},
"internal-slot": {
"version": "1.0.3",
"dev": true,
"requires": {
"get-intrinsic": "^1.1.0",
"has": "^1.0.3",
"side-channel": "^1.0.4"
}
},
"is-bigint": {
"version": "1.0.4",
"dev": true,
"requires": {
"has-bigints": "^1.0.1"
}
},
"is-boolean-object": {
"version": "1.1.2",
"dev": true,
"requires": {
"call-bind": "^1.0.2",
"has-tostringtag": "^1.0.0"
}
},
"is-callable": {
"version": "1.2.4",
"dev": true
},
"is-date-object": {
"version": "1.0.5",
"dev": true,
"requires": {
"has-tostringtag": "^1.0.0"
}
},
"is-extglob": {
"version": "2.1.1",
"dev": true
},
"is-glob": {
"version": "4.0.3",
"dev": true,
"requires": {
"is-extglob": "^2.1.1"
}
},
"is-negative-zero": {
"version": "2.0.2",
"dev": true
},
"is-number-object": {
"version": "1.0.7",
"dev": true,
"requires": {
"has-tostringtag": "^1.0.0"
}
},
"is-regex": {
"version": "1.1.4",
"dev": true,
"requires": {
"call-bind": "^1.0.2",
"has-tostringtag": "^1.0.0"
}
},
"is-shared-array-buffer": {
"version": "1.0.2",
"dev": true,
"requires": {
"call-bind": "^1.0.2"
}
},
"is-string": {
"version": "1.0.7",
"dev": true,
"requires": {
"has-tostringtag": "^1.0.0"
}
},
"is-symbol": {
"version": "1.0.4",
"dev": true,
"requires": {
"has-symbols": "^1.0.2"
}
},
"is-weakref": {
"version": "1.0.2",
"dev": true,
"requires": {
"call-bind": "^1.0.2"
}
},
"isexe": {
"version": "2.0.0",
"dev": true
},
"js-yaml": {
"version": "4.1.0",
"dev": true,
"requires": {
"argparse": "^2.0.1"
}
},
"json-schema-traverse": {
"version": "0.4.1",
"dev": true
},
"json-stable-stringify-without-jsonify": {
"version": "1.0.1",
"dev": true
},
"levn": {
"version": "0.4.1",
"dev": true,
"requires": {
"prelude-ls": "^1.2.1",
"type-check": "~0.4.0"
}
},
"lodash.merge": {
"version": "4.6.2",
"dev": true
},
"minimatch": {
"version": "3.1.2",
"dev": true,
"requires": {
"brace-expansion": "^1.1.7"
}
},
"ms": {
"version": "2.1.2",
"dev": true
},
"natural-compare": {
"version": "1.4.0",
"dev": true
},
"object-inspect": {
"version": "1.12.0",
"dev": true
},
"object-keys": {
"version": "1.1.1",
"dev": true
},
"object.assign": {
"version": "4.1.2",
"dev": true,
"requires": {
"call-bind": "^1.0.0",
"define-properties": "^1.1.3",
"has-symbols": "^1.0.1",
"object-keys": "^1.1.1"
}
},
"object.entries": {
"version": "1.1.5",
"dev": true,
"requires": {
"call-bind": "^1.0.2",
"define-properties": "^1.1.3",
"es-abstract": "^1.19.1"
}
},
"once": {
"version": "1.4.0",
"dev": true,
"requires": {
"wrappy": "1"
}
},
"optionator": {
"version": "0.9.1",
"dev": true,
"requires": {
"deep-is": "^0.1.3",
"fast-levenshtein": "^2.0.6",
"levn": "^0.4.1",
"prelude-ls": "^1.2.1",
"type-check": "^0.4.0",
"word-wrap": "^1.2.3"
}
},
"parent-module": {
"version": "1.0.1",
"dev": true,
"requires": {
"callsites": "^3.0.0"
}
},
"path-is-absolute": {
"version": "1.0.1",
"dev": true
},
"path-key": {
"version": "3.1.1",
"dev": true
},
"prelude-ls": {
"version": "1.2.1",
"dev": true
},
"punycode": {
"version": "2.1.1",
"dev": true
},
"regexpp": {
"version": "3.2.0",
"dev": true
},
"resolve-from": {
"version": "4.0.0",
"dev": true
},
"rimraf": {
"version": "3.0.2",
"dev": true,
"requires": {
"glob": "^7.1.3"
}
},
"semver": {
"version": "6.3.0",
"dev": true
},
"shebang-command": {
"version": "2.0.0",
"dev": true,
"requires": {
"shebang-regex": "^3.0.0"
}
},
"shebang-regex": {
"version": "3.0.0",
"dev": true
},
"side-channel": {
"version": "1.0.4",
"dev": true,
"requires": {
"call-bind": "^1.0.0",
"get-intrinsic": "^1.0.2",
"object-inspect": "^1.9.0"
}
},
"string.prototype.trimend": {
"version": "1.0.4",
"dev": true,
"requires": {
"call-bind": "^1.0.2",
"define-properties": "^1.1.3"
}
},
"string.prototype.trimstart": {
"version": "1.0.4",
"dev": true,
"requires": {
"call-bind": "^1.0.2",
"define-properties": "^1.1.3"
}
},
"strip-ansi": {
"version": "6.0.1",
"dev": true,
"requires": {
"ansi-regex": "^5.0.1"
}
},
"strip-json-comments": {
"version": "3.1.1",
"dev": true
},
"supports-color": {
"version": "7.2.0",
"dev": true,
"requires": {
"has-flag": "^4.0.0"
}
},
"text-table": {
"version": "0.2.0",
"dev": true
},
"tki-qrcode": {
"version": "0.1.6",
"resolved": "https://registry.npmmirror.com/tki-qrcode/-/tki-qrcode-0.1.6.tgz",
"integrity": "sha512-EnnlS8psowC7PsW3MDYcxvJYkuklX3WAZ/BYanR4TdBHTu74GfjTBX8Y16REP+AeDENiVtBPh4jtTRL2P736hQ=="
},
"type-check": {
"version": "0.4.0",
"dev": true,
"requires": {
"prelude-ls": "^1.2.1"
}
},
"type-fest": {
"version": "0.20.2",
"dev": true
},
"unbox-primitive": {
"version": "1.0.2",
"dev": true,
"requires": {
"call-bind": "^1.0.2",
"has-bigints": "^1.0.2",
"has-symbols": "^1.0.3",
"which-boxed-primitive": "^1.0.2"
}
},
"uri-js": {
"version": "4.4.1",
"dev": true,
"requires": {
"punycode": "^2.1.0"
}
},
"v8-compile-cache": {
"version": "2.3.0",
"dev": true
},
"which": {
"version": "2.0.2",
"dev": true,
"requires": {
"isexe": "^2.0.0"
}
},
"which-boxed-primitive": {
"version": "1.0.2",
"dev": true,
"requires": {
"is-bigint": "^1.0.1",
"is-boolean-object": "^1.1.0",
"is-number-object": "^1.0.4",
"is-string": "^1.0.5",
"is-symbol": "^1.0.3"
}
},
"word-wrap": {
"version": "1.2.3",
"dev": true
},
"wrappy": {
"version": "1.0.2",
"dev": true
}
}
}
......@@ -3,7 +3,9 @@
"scripts": {
"test": "eslint . --fix"
},
"dependencies": {},
"dependencies": {
"tki-qrcode": "^0.1.6"
},
"devDependencies": {
"eslint": "^8.2.0",
"eslint-config-airbnb": "^19.0.0"
......
{
"pages": [
{ "path": "pages/doctor/home", "style": {} },
{ "path": "pages/doctor/location", "style": {} },
{ "path": "pages/service/home", "style": {} },
{ "path": "pages/curriculum/home", "style": {} },
{ "path": "pages/doctor/doctor-code", "style": {} },
{ "path": "pages/doctor/doctor-info", "style": {} },
{ "path": "pages/doctor/doctor-evaluate", "style": {} },
{ "path": "pages/doctor/inquiry-history", "style": {} },
{ "path": "pages/article/my-article", "style": {} },
{ "path": "pages/article/article", "style": {} },
{ "path": "pages/article/add-article", "style": {} },
{ "path": "pages/article/edit-article", "style": {} },
{ "path": "pages/article/article-detail", "style": {} },
{ "path": "pages/article/article-preview", "style": {} },
{ "path": "pages/useful/useful", "style": {} },
{ "path": "pages/useful/add-useful", "style": {} },
{ "path": "pages/mine/home", "style": {} },
{ "path": "pages/login/login", "style": {} }
{ "path": "pages/login/login", "style": {} },
{ "path": "pages/login/setPwd", "style": {} },
{ "path": "pages/drug/drug", "style": {} }
],
"subPackages": [],
"globalStyle": {
......
<template>
<view class="">
<u-navbar title="新增文章" :placeholder="true"></u-navbar>
<view class="content">
<u--input
placeholder="文章标题"
border="bottom"
v-model="value"
placeholderStyle="{color:#999999}"
fontSize="44rpx"
></u--input>
</view>
<view class="btn-options flex content-between">
<view class="btn-item flex content-center items-center">
插入输入框
</view>
<view class="btn-item flex content-center items-center">
插入图片
</view>
</view>
<view class="btm-opt flex content-between">
<view class="btn-del" >
预览并发布
</view>
<view class="btn-edit">
保存到草稿箱
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
value:''
};
}
};
</script>
<style lang="scss" scoped>
.content{
padding: 16rpx 32rpx;
}
.btn-options{
.btn-item{
width: 336rpx;
height: 84rpx;
background: rgba(0, 74, 194, 0.04);
border-radius: 8rpx;
color: #004AC2;
font-size: 28rpx;
}
}
.btm-opt{
position: fixed;
bottom: 0;
left: 0;
width: 100%;
height: 132rpx;
padding: 32rpx 24rpx 0 24rpx;
background: #fff;
box-shadow: 0px -4px 12px 0px rgba(0, 0, 0, 0.08);
.btn-del{
width: 336rpx;
height: 84rpx;
text-align: center;
line-height: 84rpx;
border-radius: 8rpx;
border: 2rpx solid #F1F1F1;
font-size: 32rpx;
color: #333333;
}
.btn-edit{
width: 336rpx;
height: 84rpx;
text-align: center;
line-height: 84rpx;
border-radius: 8rpx;
background: linear-gradient(135deg, #0B57D2 0%, #77A5FF 100%);
border: 2rpx solid #F1F1F1;
font-size: 32rpx;
color: #fff;
}
}
</style>
<template>
<view class="cont">
<u-navbar title="文章详情" :placeholder="true"></u-navbar>
<view class="cont-title pt20">眼药水可以控制近视吗?</view>
<view class="cont-time">2020-12-12 10:00:00</view>
<view class="cont-html pt38" v-html="content">
</view>
<view class="btm-opt flex content-between">
<view class="btn-del" @click="handleDel">
删除
</view>
<view class="btn-edit">
编辑
</view>
</view>
</view>
</template>
<script>
export default{
data(){
return{
content:'<p>测试内容</p><image src="https://cdn.uviewui.com/uview/album/1.jpg" />'
}
},
onLoad(){
this.content=this.content.replace(/<image/g,'<image style="width:100%"')
},
methods:{
handleDel(){
uni.showModal({
content:'确定要删除该文章吗?',
success:res=>{
if(res.confirm){
}
}
})
},
handleDel(){
uni.showModal({
content:'确定要删除该文章吗?',
success:res=>{
if(res.confirm){
}
}
})
},
}
}
</script>
<style lang="scss" scoped>
.cont{
padding: 0 32rpx;
.cont-title {
font-weight: 600;
color: #333333;
line-height: 40rpx;
}
.cont-time {
padding-top: 24rpx;
font-size: 24rpx;
line-height: 24rpx;
color: #999999;
}
}
.cont-html{
padding-bottom: 142rpx;
}
.btm-opt{
position: fixed;
bottom: 0;
left: 0;
width: 100%;
height: 132rpx;
padding: 32rpx 24rpx 0 24rpx;
background: #fff;
box-shadow: 0px -4px 12px 0px rgba(0, 0, 0, 0.08);
.btn-del{
width: 336rpx;
height: 84rpx;
text-align: center;
line-height: 84rpx;
border-radius: 8rpx;
border: 2rpx solid #F1F1F1;
font-size: 32rpx;
color: #333333;
}
.btn-edit{
width: 336rpx;
height: 84rpx;
text-align: center;
line-height: 84rpx;
border-radius: 8rpx;
background: linear-gradient(135deg, #0B57D2 0%, #77A5FF 100%);
border: 2rpx solid #F1F1F1;
font-size: 32rpx;
color: #fff;
}
}
</style>
<template>
<view class="cont">
<u-navbar title="预览" :placeholder="true"></u-navbar>
<view class="cont-title pt20">眼药水可以控制近视吗?</view>
<view class="cont-time">2020-12-12 10:00:00</view>
<view class="cont-html pt38" v-html="content">
</view>
<view class="btm-opt flex content-between">
<view class="btn-edit">
预览并发布
</view>
</view>
</view>
</template>
<script>
export default{
data(){
return{
content:'<p>测试内容</p><image src="https://cdn.uviewui.com/uview/album/1.jpg" />'
}
},
onLoad(){
this.content=this.content.replace(/<image/g,'<image style="width:100%"')
},
methods:{
handleDel(){
uni.showModal({
content:'确定要删除该文章吗?',
success:res=>{
if(res.confirm){
}
}
})
},
handleDel(){
uni.showModal({
content:'确定要删除该文章吗?',
success:res=>{
if(res.confirm){
}
}
})
},
}
}
</script>
<style lang="scss" scoped>
.cont{
padding: 0 32rpx;
.cont-title {
font-weight: 600;
color: #333333;
line-height: 40rpx;
}
.cont-time {
padding-top: 24rpx;
font-size: 24rpx;
line-height: 24rpx;
color: #999999;
}
}
.cont-html{
padding-bottom: 142rpx;
}
.btm-opt{
position: fixed;
bottom: 0;
left: 0;
width: 100%;
height: 132rpx;
padding: 32rpx 24rpx 0 24rpx;
background: #fff;
box-shadow: 0px -4px 12px 0px rgba(0, 0, 0, 0.08);
.btn-edit{
width: 100%;
height: 84rpx;
text-align: center;
line-height: 84rpx;
border-radius: 8rpx;
background: linear-gradient(135deg, #0B57D2 0%, #77A5FF 100%);
border: 2rpx solid #F1F1F1;
font-size: 32rpx;
color: #fff;
}
}
</style>
<template>
<view class="">
<u-navbar title="我的文章" :placeholder="true"></u-navbar>
<view class="">
<view class="head-tabs flex items-center">
<view class="tabs-nav active" @click="checkTabs(0)">
已发布
<view class="btm-slide" v-if="idx == 0"></view>
</view>
<view class="tabs-nav" @click="checkTabs(1)">
草稿箱
<view class="btm-slide" v-if="idx == 1"></view>
</view>
</view>
</view>
<!-- 列表 -->
<articleList/>
</view>
</template>
<script>
import articleList from './componnets/article-list.vue';
export default {
components:{
articleList
},
data() {
return {
idx: 0
};
},
methods: {
// 切换选项
checkTabs(idx) {
this.idx = idx;
}
}
};
</script>
<style lang="scss" scoped>
.head-tabs {
height: 90rpx;
padding: 0 34rpx;
border-bottom: 2rpx solid #f5f6f7;
.tabs-nav {
position: relative;
margin-right: 44rpx;
color: #666666;
font-size: 30rpx;
line-height: 42rpx;
.btm-slide {
position: absolute;
bottom: -26rpx;
left: 50%;
transform: translateX(-50%);
width: 40rpx;
height: 6rpx;
background: linear-gradient(270deg, #77abff 0%, #035ceb 100%);
border-radius: 4rpx;
}
}
.active {
color: #000000;
font-weight: 500;
}
}
</style>
<template>
<view class="content">
<view class="flex pb32 pt32">
<view class="aticle-img"></view>
<view class="article-cont pl24">
<view class="article-title">眼药水可以控制近视吗?</view>
<view class="article-text text-ellipsis-1" style="width: 448rpx">提到近视提到近视控制的方法控制的方法,很很很</view>
<view class="flex pt42 content-between">
<view class="create-time ">2020-12-12 10:00:00</view>
<view class="record flex items-center">
<image style="width: 20rpx; height: 16rpx;" src="/static/image/record.png"></image>
<text>198</text>
</view>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {};
},
created() {
console.log(1);
}
};
</script>
<style lang="scss" scoped>
.content {
border-bottom: 2rpx solid #f5f6f7;
padding: 0 26rpx;
.aticle-img {
flex-shrink: 0;
width: 228rpx;
height: 152rpx;
border-radius: 12px;
background-color: #eee;
}
.article-title {
font-size: 30rpx;
color: #333333;
line-height: 40rpx;
}
.article-text {
font-size: 24rpx;
color: #999999;
line-height: 34rpx;
}
.create-time {
font-size: 24rpx;
color: #999999;
line-height: 24rpx;
}
.record {
width: 70rpx;
height: 28rpx;
background: rgba(239, 43, 45, 0.1);
line-height: 28rpx;
// opacity: 0.1;
border-radius: 4rpx;
font-size: 18rpx;
color: #ef2b2d;
}
}
</style>
<template>
<view class="cont">
<u-navbar title="编辑" :placeholder="true"></u-navbar>
<view class="cont-title pt20">眼药水可以控制近视吗?</view>
<view class="cont-time">2020-12-12 10:00:00</view>
<view class="cont-html pt38" v-html="content">
</view>
<view class="btm-opt flex content-between">
<view class="btn-edit">
预览并保存
</view>
</view>
</view>
</template>
<script>
export default{
data(){
return{
content:'<p>测试内容</p><image src="https://cdn.uviewui.com/uview/album/1.jpg" />'
}
},
onLoad(){
this.content=this.content.replace(/<image/g,'<image style="width:100%"')
},
methods:{
handleDel(){
uni.showModal({
content:'确定要删除该文章吗?',
success:res=>{
if(res.confirm){
}
}
})
},
handleDel(){
uni.showModal({
content:'确定要删除该文章吗?',
success:res=>{
if(res.confirm){
}
}
})
},
}
}
</script>
<style lang="scss" scoped>
.cont{
padding: 0 32rpx;
.cont-title {
font-weight: 600;
color: #333333;
line-height: 40rpx;
}
.cont-time {
padding-top: 24rpx;
font-size: 24rpx;
line-height: 24rpx;
color: #999999;
}
}
.cont-html{
padding-bottom: 142rpx;
}
.btm-opt{
position: fixed;
bottom: 0;
left: 0;
width: 100%;
height: 132rpx;
padding: 32rpx 24rpx 0 24rpx;
background: #fff;
box-shadow: 0px -4px 12px 0px rgba(0, 0, 0, 0.08);
.btn-edit{
width: 100%;
height: 84rpx;
text-align: center;
line-height: 84rpx;
border-radius: 8rpx;
background: linear-gradient(135deg, #0B57D2 0%, #77A5FF 100%);
border: 2rpx solid #F1F1F1;
font-size: 32rpx;
color: #fff;
}
}
</style>
<template>
<view class="">
<u-navbar title="我的文章" :placeholder="true"></u-navbar>
<!-- 列表 -->
<articleList/>
</view>
</template>
<script>
import articleList from './componnets/article-list.vue';
export default {
components:{
articleList
},
data() {
return {
idx: 0
};
},
methods: {
// 切换选项
checkTabs(idx) {
this.idx = idx;
}
}
};
</script>
<style lang="scss" scoped>
.head-tabs {
height: 90rpx;
padding: 0 34rpx;
border-bottom: 2rpx solid #f5f6f7;
.tabs-nav {
position: relative;
margin-right: 44rpx;
color: #666666;
font-size: 30rpx;
line-height: 42rpx;
.btm-slide {
position: absolute;
bottom: -26rpx;
left: 50%;
transform: translateX(-50%);
width: 40rpx;
height: 6rpx;
background: linear-gradient(270deg, #77abff 0%, #035ceb 100%);
border-radius: 4rpx;
}
}
.active {
color: #000000;
font-weight: 500;
}
}
</style>
<template>
<view class="container">
<u-navbar title="找课程" :placeholder="true"></u-navbar>
<view class="main">
<view>
<u--image width="750rpx" height="130rpx" :src="require('@/assets/doctor-help.png')"></u--image>
</view>
<view class="flex row content-between items-center mt30">
<view class="drug card flex content-center items-center">
<text>急速配药</text>
</view>
<view class="flex column content-between items-center">
<view class="consultation card">
<text>图文问诊</text>
</view>
<view class="prescription card">
<text>复诊续方</text>
</view>
</view>
</view>
<view class="mt30">
<u--image width="750rpx" height="160rpx" :src="require('@/assets/doctor-propaganda.png')"></u--image>
</view>
<view class="menu mt30">
<u--image width="750rpx" height="310rpx" :src="require('@/assets/doctor-menu.png')"></u--image>
</view>
<!-- 平台优选 -->
<view class="rcommd card mt30">
<view class="flex row content-between items-center">
<text>视频课程</text>
<view class="flex items-center">
<text class="font-20">查看更多</text>
<u-icon name="arrow-right" size="20" color="#c2ced8"></u-icon>
</view>
</view>
<view class="mt30">
<view class="roll-list-short roll-list flex row content-start">
<template v-for="(item, index) in rcommdList">
<view class="roll-item" :key="index"> </view>
</template>
<view class="roll-item-last"></view>
</view>
</view>
</view>
<!-- 找医院、找医生 -->
<view class="rcommd card mt30">
<view class="flex row content-between items-center">
<text>健康资讯</text>
<view class="flex items-center">
<text class="font-20">查看更多</text>
<u-icon name="arrow-right" size="20" color="#c2ced8"></u-icon>
</view>
</view>
<view class="tabs-box">
<u-tabs :list="tabList" :scrollable="true"></u-tabs>
</view>
<view class="mt30">
<view class="roll-list-short roll-list flex row content-start">
<template v-for="(item, index) in rcommdList">
<view class="roll-item" :key="index"> </view>
</template>
<view class="roll-item-last"></view>
</view>
</view>
</view>
</view>
<u-tabbar value="curriculum" :fixed="true" :placeholder="true" :safeAreaInsetBottom="true">
<u-tabbar-item text="找医生" name="doctor" icon="home" @click="tabbarItem"></u-tabbar-item>
<u-tabbar-item text="找服务" name="service" icon="photo" @click="tabbarItem"></u-tabbar-item>
<u-tabbar-item text="找课程" name="curriculum" icon="play-right" @click="tabbarItem"></u-tabbar-item>
<u-tabbar-item text="个人中心" name="mine" icon="account" @click="tabbarItem"></u-tabbar-item>
</u-tabbar>
</view>
</template>
<script>
export default {
data() {
return {
rcommdList: [1, 2, 3, 4, 5, 6, 7, 8],
tabList: [{ name: '全部' }, { name: '资讯' }, { name: '保健' }, { name: '女性健康' }, { name: '儿童' }, { name: '产后' }, { name: '其他' }]
}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped>
.container {
background: #004bb9;
}
.search-box {
width: 750rpx;
padding: 30rpx;
}
.search-input {
width: 600rpx;
}
.main {
padding: 30rpx 0 0 0;
border-radius: 30rpx 30rpx 0 0;
background: #f5f5f9;
}
.rcommd {
width: 750rpx;
padding: 30rpx;
background: #ffffff;
}
.tabs-box {
max-width: 750rpx;
}
.roll-list {
width: 750rpx;
overflow-x: scroll;
}
.roll-item {
position: relative;
display: inline-block;
min-width: 200rpx;
height: 200rpx;
margin: 0 20rpx 0 0;
border-radius: 10rpx;
overflow: hidden;
background: #808080;
box-shadow: 0 16rpx 20rpx 0 rgba(0, 0, 0, 0.05);
}
.roll-item-last {
min-width: 1px;
margin: 0 0 0 -1px;
}
</style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="pl28 pr28">
<view class="content flex items-center content-between ">
<view class="flex pt30">
<view class="evaluate-icon">
</view>
<view class="pl16">
<view class="evaluate-name">
刘**
</view>
<view class="score">
<image style="width:22rpx;height: 22rpx;" src="../../../static/image/score1.png" mode=""></image>
<image style="width:22rpx;height: 22rpx;" src="../../../static/image/score1.png" mode=""></image>
<image style="width:22rpx;height: 22rpx;" src="../../../static/image/score1.png" mode=""></image>
<image style="width:22rpx;height: 22rpx;" src="../../../static/image/score1.png" mode=""></image>
<image style="width:22rpx;height: 22rpx;" src="../../../static/image/score2.png" mode=""></image>
</view>
</view>
</view>
<view class="data-time">
2020-12-12 10:00:00
</view>
</view>
<view class="msg pt24 pb32">
医生非常耐心,有问必答,非常感谢!
</view>
</view>
</template>
<script>
</script>
<style lang="scss" scoped>
.content{
.evaluate-icon{
background-color: #eee;
width: 64rpx;
height: 64rpx;
border-radius: 50%;
overflow: hidden;
}
.evaluate-name{
font-size: 28rpx;
color: #333333;
line-height: 24rpx;
}
.data-time{
font-size: 24rpx;
color: #999999;
line-height: 24rpx;
}
}
.msg{
font-size: 28rpx;
color: #333333;
line-height: 28rpx;
border-bottom: 2rpx solid #F5F6F7;
}
</style>
\ No newline at end of file
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="content">
<u-navbar title="我的二维码" :placeholder="true"></u-navbar>
<view class="head ">
<view class=" content-center items-center" style="display: flex; flex-direction: column;">
<view class="doctor-icon mt40"></view>
<view class="doctor-name pt24">李白</view>
<view class="pt16">
<text class="doctor-tag">呼吸内科,儿童门诊</text>
<text class="doctor-title">主治医师</text>
</view>
<view class="head-doctor-name pt24">厦门弘爱医院</view>
</view>
</view>
<view class="content-code">
<view class="qrimg flex content-center" style="padding: 60rpx; 0">
<tki-qrcode
ref="qrcode"
cid="qrcode2"
:val="val"
:size="size"
:unit="unit"
:background="background"
:foreground="foreground"
:pdground="pdground"
:icon="icon"
:iconSize="iconsize"
:lv="lv"
:onval="onval"
:loadMake="loadMake"
:usingComponents="usingComponents"
:showLoading="true"
:loadingText="'加载中'"
@result="qrR"
/>
</view>
<view class="msg flex content-center pb42">识别二维码使用微信关注我</view>
</view>
</view>
</template>
<script>
import tkiQrcode from '@/components/tki-qrcode/tki-qrcode.vue';
export default {
components: { tkiQrcode },
data() {
return {
ifShow: true,
usingComponents:true,
val: '二维码', // 要生成的二维码值
size: 500, // 二维码大小
unit: 'upx', // 单位
background: '#000000', // 背景色
foreground: '#ffffff', // 前景色
pdground: '#ffffff', // 角标色
icon: '', // 二维码图标
iconsize: 40, // 二维码图标大小
lv: 3, // 二维码容错级别 , 一般不用设置,默认就行
onval: false, // val值变化时自动重新生成二维码
loadMake: true, // 组件加载完成后自动生成二维码
src: '' // 二维码生成后的图片地址或base64
};
},
methods:{
// 二维码生成之后生成一个图片地址
qrR(val){
// console.log(val)
}
}
};
</script>
<style>
page {
background: #f5f6f7;
}
</style>
<style lang="scss" scoped>
.content {
padding: 0 44rpx;
.head {
height: 360rpx;
background-image: url('/static/image/home-bg-color.png');
background-repeat: no-repeat;
background-size: 100%;
.doctor-icon {
width: 120rpx;
height: 120rpx;
border-radius: 50%;
border: 4rpx solid rgba(255, 255, 255, 0.15);
box-shadow: 0px 4px 20px 0px rgba(0, 0, 0, 0.01);
}
.doctor-name {
font-size: 36rpx;
color: #fff;
font-weight: 600;
line-height: 36rpx;
text-shadow: 0rpx 4rpx 20rpx rgba(0, 0, 0, 0.01);
}
.doctor-tag {
padding: 8rpx 24rpx;
background: linear-gradient(180deg, rgba(255, 255, 255, 0.15) 0%, rgba(255, 255, 255, 0.2) 100%);
opacity: 0.43;
line-height: 24rpx;
text-shadow: 0rpx 4rpx 20rpx rgba(0, 0, 0, 0.01);
border-radius: 20rpx;
font-size: 24rpx;
color: #ffffff;
}
.doctor-title {
padding: 8rpx 24rpx;
background: #eff4fb;
box-shadow: 0rpx 4rpx 20rpx 0rpx rgba(0, 0, 0, 0.01);
color: #1c62d5;
border-radius: 20rpx;
font-size: 24rpx;
margin-left: 12rpx;
}
.head-doctor-name {
font-size: 24rpx;
color: #ffffff;
line-height: 24rpx;
}
}
.content-code {
background: #fff;
.msg {
line-height: 24rpx;
font-size: 28rpx;
color: #b6b6b6;
}
}
}
</style>
<template>
<view class="">
<u-navbar title="我的评价" :placeholder="true"></u-navbar>
<view class="head-info flex">
<view class="head-icon"></view>
<view class="flex content-center pl22" style="flex-direction: column;">
<view class="flex ">
<text class="doctor-name">李白</text>
<text class="doctor-tag ml12">主治医师</text>
</view>
<view class="doctor-text pt20">呼吸内科,儿童门诊</view>
</view>
</view>
<view class="pl24 pr24">
<view class="flex pt40">
<image style="width: 44rpx; height: 44rpx;" src="/static/image/info5.png" mode=""></image>
<view class="info-title">对医生的印象</view>
</view>
<view class="flex pt28" style="flex-flow: wrap;">
<text class="tags mr24 mb20">全部</text>
<text class="tags mr24 mb20">全部</text>
<text class="tags mr24 mb20">全部</text>
<text class="tags mr24 mb20">全部</text>
<text class="tags mr24 mb20">全部</text>
<text class="tags mr24 mb20">全部</text>
</view>
</view>
<!-- 患者评价列表 -->
<view class="">
<view class="flex pt40">
<image style="width: 44rpx; height: 44rpx;" src="/static/image/info4.png" mode=""></image>
<view class="info-title">对医生的印象</view>
</view>
<evaluate-list></evaluate-list>
</view>
</view>
</template>
<script>
import evaluateList from './componnets/evaluate-list.vue'
export default{
components:{
evaluateList
},
data(){
return{
}
},
methods:{
}
}
</script>
<style lang="scss" scoped>
.head-info {
padding: 28rpx 24rpx 40rpx 24rpx;
border-bottom: 2rpx solid #f5f6f7;
.head-icon {
width: 116rpx;
height: 116rpx;
background: #eee;
border-radius: 50%;
}
.doctor-name {
font-size: 36rpx;
color: #333333;
font-weight: 600;
line-height: 36rpx;
}
.doctor-tag {
padding: 8rpx 14rpx;
background: #eff4fb;
border-radius: 20rpx;
font-size: 24rpx;
color: #1c62d5;
}
.doctor-text {
font-size: 24rpx;
color: #666666;
line-height: 24rpx;
}
}
.info-title {
padding-left: 16rpx;
font-size: 32rpx;
line-height: 44rpx;
color: #333333;
font-weight: 600;
}
.tags {
background-color: #f5f6f7;
padding: 10rpx 36rpx;
border-radius: 28rpx;
color: #555555;
font-size: 24rpx;
}
</style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
<view class="">
<u-navbar title="医生简介" :placeholder="true"></u-navbar>
<view class="head-info flex">
<view class="head-icon"></view>
<view class="flex content-center pl22" style="flex-direction: column;">
<view class="flex ">
<text class="doctor-name">李白</text>
<text class="doctor-tag ml12">主治医师</text>
</view>
<view class="doctor-text pt20">呼吸内科,儿童门诊</view>
</view>
</view>
<view class="" style="padding: 0 24rpx;">
<view class="pt40">
<view class="doctor-info flex">
<image src="/static/image/info1.png" style="width: 44rpx; height: 44rpx;" mode=""></image>
<view class="doctor-title pl16">坐诊信息</view>
</view>
<view class="doctor-content pt20 text-ellipsis-2">
小儿多动症、癫痫、小儿生长发育迟小儿多动症、癫痫、小儿生长发育迟小儿多动症、癫小儿生长发育迟小儿.....
</view>
</view>
<view style="padding-top: 80rpx;">
<view class="doctor-info flex">
<image src="/static/image/info2.png" style="width: 44rpx; height: 44rpx;" mode=""></image>
<view class="doctor-title pl16">擅长</view>
</view>
<view class="doctor-content pt20 text-ellipsis-2">
小儿多动症、癫痫、小儿生长发育迟小儿多动症、癫痫、小儿生长发育迟小儿多动症、癫小儿生长发育迟小儿.....
</view>
</view>
<view class="" style="padding-top: 80rpx;">
<view class="doctor-info flex">
<image src="/static/image/info3.png" style="width: 44rpx; height: 44rpx;" mode=""></image>
<view class="doctor-title pl16">介绍</view>
</view>
<view class="doctor-content pt20 text-ellipsis-2">
小儿多动症、癫痫、小儿生长发育迟小儿多动症、癫痫、小儿生长发育迟小儿多动症、癫小儿生长发育迟小儿.....
</view>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<script></script>
<style lang="scss" scoped></style>
<style lang="scss" scoped>
.head-info {
padding: 28rpx 24rpx 40rpx 24rpx;
border-bottom: 2rpx solid #f5f6f7;
.head-icon {
width: 116rpx;
height: 116rpx;
background: #eee;
border-radius: 50%;
}
.doctor-name {
font-size: 36rpx;
color: #333333;
font-weight: 600;
line-height: 36rpx;
}
.doctor-tag {
padding: 8rpx 14rpx;
background: #eff4fb;
border-radius: 20rpx;
font-size: 24rpx;
color: #1c62d5;
}
.doctor-text {
font-size: 24rpx;
color: #666666;
line-height: 24rpx;
}
}
.doctor-title {
font-size: 32rpx;
font-weight: 600;
line-height: 44rpx;
color: #333333;
}
.doctor-content{
font-size: 28rpx;
color: #666666;
line-height: 40rpx;
}
</style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="找医生" :placeholder="true"></u-navbar>
<!-- 搜索 -->
<view class="search-box flex row content-center">
<view class="search-input flex row items-center">
<u-search v-model="search.text" placeholder="搜医院、医生、科室、产品" actionText="搜索" :showAction="false" bgColor="#ffffff"></u-search>
</view>
<u-icon name="chat" size="40" color="#ffffff" @click="toLocation"></u-icon>
</view>
<view class="main">
<view>
<u--image width="750rpx" height="130rpx" :src="require('@/assets/doctor-help.png')"></u--image>
</view>
<view class="flex row content-between items-center mt30">
<view class="drug card flex content-center items-center">
<text>急速配药</text>
</view>
<view class="flex column content-between items-center">
<view class="consultation card">
<text>图文问诊</text>
</view>
<view class="prescription card">
<text>复诊续方</text>
</view>
</view>
</view>
<view class="mt30">
<u--image width="750rpx" height="160rpx" :src="require('@/assets/doctor-propaganda.png')"></u--image>
</view>
<view class="menu mt30">
<u--image width="750rpx" height="310rpx" :src="require('@/assets/doctor-menu.png')"></u--image>
</view>
<!-- 平台优选 -->
<view class="rcommd card mt30">
<view class="flex row content-between items-center">
<text>平台优选</text>
<view class="flex items-center">
<text class="font-20">查看更多</text>
<u-icon name="arrow-right" size="20" color="#c2ced8"></u-icon>
</view>
</view>
<view class="mt30">
<view class="roll-list-short roll-list flex row content-start">
<template v-for="(item, index) in rcommdList">
<view class="roll-item" :key="index"> </view>
</template>
<view class="roll-item-last"></view>
</view>
</view>
</view>
<!-- 找医院、找医生 -->
<view class="rcommd card mt30">
<view class="flex row content-between items-center">
<u-tabs :list="[{ name: '找医院' }, { name: '找医生' }]"></u-tabs>
<view class="flex items-center">
<text class="font-20">查看更多</text>
<u-icon name="arrow-right" size="20" color="#c2ced8"></u-icon>
</view>
</view>
<view class="mt30">
<view class="roll-list-short roll-list flex row content-start">
<template v-for="(item, index) in rcommdList">
<view class="roll-item" :key="index"> </view>
</template>
<view class="roll-item-last"></view>
</view>
</view>
</view>
</view>
<u-tabbar value="doctor" :fixed="true" :placeholder="true" :safeAreaInsetBottom="true">
<u-tabbar-item text="找医生" name="doctor" icon="home" @click="tabbarItem"></u-tabbar-item>
<u-tabbar-item text="找服务" name="service" icon="photo" @click="tabbarItem"></u-tabbar-item>
<u-tabbar-item text="找课程" name="curriculum" icon="play-right" @click="tabbarItem"></u-tabbar-item>
<u-tabbar-item text="个人中心" name="mine" icon="account" @click="tabbarItem"></u-tabbar-item>
</u-tabbar>
</view>
<view class="container">
11
</view>
</template>
<script>
export default {
data() {
return {
search: {
text: ''
},
rcommdList: [1, 2, 3, 4, 5, 6, 7, 8]
}
},
onShow() {},
methods: {
toLocation() {
uni.navigateTo({ url: '/pages/doctor/location' })
},
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
data() {
return {
search: {
text: ''
}
};
},
onShow() {},
methods: {}
};
</script>
<style lang="scss" scoped>
.container {
background: #004bb9;
}
.search-box {
width: 750rpx;
padding: 30rpx;
}
.search-input {
width: 600rpx;
}
.main {
padding: 30rpx 0 0 0;
border-radius: 30rpx 30rpx 0 0;
background: #f5f5f9;
}
.drug {
width: 330rpx;
height: 300rpx;
margin: 0 0 0 30rpx;
}
.consultation {
width: 340rpx;
height: 150rpx;
margin: 0 30rpx 30rpx 0;
}
.prescription {
width: 340rpx;
height: 150rpx;
margin: 0 30rpx 0 0;
}
.rcommd {
width: 750rpx;
padding: 30rpx;
background: #ffffff;
}
.roll-list {
width: 750rpx;
overflow-x: scroll;
}
.roll-item {
position: relative;
display: inline-block;
min-width: 200rpx;
height: 200rpx;
margin: 0 20rpx 0 0;
border-radius: 10rpx;
overflow: hidden;
background: #808080;
box-shadow: 0 16rpx 20rpx 0 rgba(0, 0, 0, 0.05);
}
.roll-item-last {
min-width: 1px;
margin: 0 0 0 -1px;
.status_bar {
height: var(--status-bar-height);
width: 100%;
}
</style>
<template>
<view class="">
<u-navbar title="问诊历史" :placeholder="true"></u-navbar>
<view class=" list pl24 pr24 pt34 pb28" v-for="i in 2" :key="i">
<view class="flex items-center content-between">
<view class="">
<text class="list-type" v-if="i==1">图文</text>
<text class="list-type prescribe" v-else>开药</text>
<text class="list-sex-age pl24">男 | 20岁</text>
</view>
<view class="list-time">2020-12-12 10:00:00</view>
</view>
<view class="list-cont pt22 text-ellipsis-3">请问医生我家宝宝这个鳃漏需要手术吗?</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {};
}
};
</script>
<style lang="scss" scoped>
.list {
border-bottom: 2rpx solid #f5f6f7;
.list-type {
background: linear-gradient(135deg, #1b6ff8 0%, #77a5ff 100%);
width: 40rpx;
height: 24rpx;
padding: 4rpx 6rpx;
border-radius: 4rpx;
font-size: 20rpx;
font-weight: 400;
color: #ffffff;
line-height: 24rpx;
font-size: 20rpx;
}
.list-time {
font-size: 24rpx;
color: #999999;
}
.list-sex-age {
font-size: 24rpx;
line-height: 24rpx;
color: #999999;
}
.list-cont {
font-size: 28rpx;
color: #666666;
line-height: 44rpx;
}
}
.prescribe {
background: linear-gradient(135deg, #05ddbd 0%, #32dfc2 100%) !important;
}
</style>
<template>
<view class="container">
<u-navbar title="选择所在城市" :placeholder="true"></u-navbar>
<!-- 搜索 -->
<view class="search-box flex row content-center">
<view class="search-input flex row items-center">
<u-search v-model="search.text" placeholder="搜医院、医生、科室、产品" actionText="搜索" :showAction="false" bgColor="#ffffff"></u-search>
</view>
</view>
<view class="main">
<u-index-list :index-list="indexList">
<template v-for="(item, index) in itemArr">
<u-index-anchor :text="indexList[index]" :key="index"></u-index-anchor>
<u-index-item :key="index">
<u-index-anchor :text="indexList[index]"></u-index-anchor>
<view class="list-cell" v-for="(cell, index) in item" :key="index"> {{ cell }} </view>
</u-index-item>
</template>
</u-index-list>
</view>
</view>
</template>
<script>
export default {
data() {
return {
search: {
text: ''
},
indexList: ['A', 'B', 'C', 'A', 'B', 'C', 'A', 'B', 'C', 'A', 'B', 'C'],
itemArr: [
['列表A1', '列表A2', '列表A3'],
['列表B1', '列表B2', '列表B3'],
['列表C1', '列表C2', '列表C3'],
['列表B1', '列表B2', '列表B3'],
['列表B1', '列表B2', '列表B3'],
['列表B1', '列表B2', '列表B3'],
['列表B1', '列表B2', '列表B3'],
['列表B1', '列表B2', '列表B3'],
['列表B1', '列表B2', '列表B3'],
['列表B1', '列表B2', '列表B3'],
['列表B1', '列表B2', '列表B3'],
['列表B1', '列表B2', '列表B3']
]
}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped>
.container {
background: #004bb9;
}
.search-box {
width: 750rpx;
padding: 30rpx;
}
.search-input {
width: 690rpx;
}
.main {
padding: 30rpx 0 0 0;
border-radius: 30rpx 30rpx 0 0;
background: #f5f5f9;
}
</style>
<template>
<view class="content">
<view class="drug-title">双醋瑞因胶囊50mg*24粒</view>
<view class="drug-company pt16">重庆赛维药业有限公司</view>
<view class="pt24"><text class="tags">弘爱互联网+药房</text></view>
</view>
</template>
<script></script>
<style lang="scss" scoped>
.content {
width: 100%;
padding: 40rpx 24rpx 36rpx 24rpx;
border: 2rpx solid #F5F6F7;
.drug-title {
font-size: 30rpx;
color: #333333;
line-height: 30rpx;
}
.drug-company {
font-weight: 400;
color: #999999;
line-height: 24rpx;
font-size: 24rpx;
}
.tags {
padding: 8rpx;
background-color: #eff4fb;
color: #1c62d5;
line-height: 24rpx;
font-size: 24rpx;
}
}
</style>
<template>
<view class="">
<u-navbar title="药品查询" :placeholder="true"></u-navbar>
<view class="head">
<text class="doctor-title">
弘爱互联网+药房
<view class="btm-slide"></view>
</text>
</view>
<!-- 搜索输入框 -->
<view class="pl24 pr24 pt20">
<view class="search-content flex">
<view class="pl20 pr20" style="line-height: 68rpx;"><img style="width: 28rpx;height: 28rpx;" src="/static/image/search.png" alt="" /></view>
<u--input :fontSize="'24rpx'" placeholder="请输入药品名称" border="none" v-model="value"></u--input>
</view>
</view>
<!-- 药品列表 -->
<drug-list></drug-list>
</view>
</template>
<script>
import drugList from './components/drug-list.vue';
export default {
components:{
drugList
},
data() {
return {
value: ''
};
}
};
</script>
<style lang="scss" scoped>
.head {
height: 90rpx;
border-bottom: 2rpx solid #f5f6f7;
.doctor-title {
position: relative;
padding: 20rpx 34rpx 28rpx 34rpx;
font-weight: 500;
line-height: 42rpx;
font-size: 30rpx;
color: #000000;
}
.btm-slide {
position: absolute;
bottom: -10rpx;
left: 50%;
transform: translateX(-50%);
width: 40rpx;
height: 6rpx;
background: linear-gradient(270deg, #77abff 0%, #035ceb 100%);
border-radius: 4rpx;
}
}
.search-content {
background: #f5f6f7;
width: 100%;
height: 68rpx;
border-radius: 6rpx;
}
</style>
<template>
<view class="container">
<u-navbar title="账号授权" back-text="返回" :placeholder="true" @leftClick="onNavbarLeftClick"></u-navbar>
<u-button type="primary" text="授权登录" @click="onLogin"></u-button>
<u-button type="primary" text="获取信息" @click="onGetUserProfile"></u-button>
<u-button type="primary" text="获取手机" open-type="getPhoneNumber" @getphonenumber="onGetPhoneNumber"></u-button>
</view>
</template>
<script>
import { userLoginToken, userGetMiniProgramPhone, userGetMiniProgramUserInfo } from '@/api/user.js'
export default {
data() {
return {}
},
onLoad() {},
onShow() {
uni.hideLoading()
},
methods: {
onLogin() {
wx.login({
success: async (result) => {
const response = await userLoginToken({
code: result.code
})
console.log('onLogin response')
console.log(response)
// 返回数据结构
// accessToken: "b2402ddf-61e4-4d07-bd1b-f22ef0fd3050"
// expiresIn: 6858
// openId: "oKJUK41TAcesZDVGf8o_Fv1EHlIg"
// refreshToken: "b2bcc403-466f-40dc-9cf8-1f626abe97ee"
// scope: "all,read,write"
// sessionKey: "the/PDm51uVkj2jR4j9rCg=="
// tokenType: "bearer"
// unionId: "ojbkR1KJEKZvEDFb1lUD97Q0aAfc"
const responseData = response.data
uni.setStorageSync('accessToken', responseData.accessToken)
uni.setStorageSync('refreshToken', responseData.refreshToken)
uni.setStorageSync('sessionKey', responseData.sessionKey)
uni.setStorageSync('openId', responseData.openId)
}
})
},
onGetUserProfile() {
wx.getUserProfile({
desc: '用于完善会员资料',
success: async (result) => {
const response = await userGetMiniProgramUserInfo({
encryptedData: result.encryptedData,
iv: result.iv,
rawData: result.rawData,
signature: result.signature
})
console.log('onGetUserProfile')
console.log(response)
}
})
},
// 获取手机号
async onGetPhoneNumber(event) {
const result = event.detail
const response = await userGetMiniProgramPhone({
encryptedData: result.encryptedData,
iv: result.iv
})
console.log('onGetPhoneNumber')
console.log(response)
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="">
<u-navbar title="" :placeholder="true"></u-navbar>
<view class="head">
<view class="head-title flex items-center pl30 pr30">
<view class="head-icon"></view>
<view class="head-text">建发健康</view>
</view>
</view>
<!-- 表单 -->
<view class="cont-form">
<u--form labelPosition="left" :errorType="errorType" :model="model" :rules="rules" ref="model">
<view class="flex items-center" style="border-bottom: 2rpx solid #EFEFEF;margin-bottom: 28rpx;">
<view class="phone-type flex items-center pl28 colro333 ft28">+86</view>
<view class="division"></view>
<u-form-item prop="userInfo.mobile" :borderBottom="false" ref="item" style="flex:1">
<u--input v-model="model.userInfo.mobile" :placeholderClass="'dep-input'" placeholder="请输入手机号" border="none"></u--input>
</u-form-item>
</view>
<view class="flex items-center" style="border-bottom: 2rpx solid #EFEFEF;">
<view class="phone-type flex items-center pl28 colro333 ft28">验证码</view>
<view class="division"></view>
<u-form-item prop="userInfo.code" :borderBottom="false" ref="item" style="flex:1">
<u--input v-model="model.userInfo.code" :placeholderClass="'dep-input'" placeholder="请输入验证码" border="none"></u--input>
<text slot="right" class="btn-submit" @click.stop="getCode">{{ tips }}</text>
<u-toast ref="uToast"></u-toast>
<u-code :seconds="seconds" @end="end" @start="start" ref="uCode" @change="codeChange"></u-code>
</u-form-item>
</view>
</u--form>
<u-button size="30rpx" class="submit" @click="handleSubmit">登录</u-button>
<view class="check-login">手机号密码登录</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
errorType: 'toast',
model: {
userInfo: {
mobile: '',
code: ''
}
},
rules: {
'userInfo.mobile': [
{
required: true,
message: '请输入手机号',
trigger: ['change', 'blur']
},
{
// 自定义验证函数,见上说明
validator: (rule, value, callback) => {
// 上面有说,返回true表示校验通过,返回false表示不通过
// uni.$u.test.mobile()就是返回true或者false的
return uni.$u.test.mobile(value);
},
message: '手机号码不正确',
// 触发器可以同时用blur和change
trigger: ['change', 'blur']
}
],
'userInfo.code': {
type: 'string',
required: true,
len: 4,
message: '请填写4位验证码',
trigger: ['blur']
}
},
tips: '获取验证码',
seconds: 60
};
},
onLoad() {},
onShow() {},
methods: {
handleSubmit() {
this.$refs.model
.validate()
.then(res => {})
.catch(errors => {
// uni.$u.toast('校验失败');
});
},
codeChange(text) {
this.tips = text;
},
getCode() {
// 先判断手机号是否为空
// if(!uni.$u.test.mobile(this.model.userInfo.mobile)){
// return uni.showLoading({
// title: '请输入正确的手机号',
// icon:'none'
// });
// }
if (this.$refs.uCode.canGetCode) {
uni.showModal({
content: '我们将发送短信到这个手机号码:+86' + this.model.userInfo.mobile,
success: res => {
if (res.confirm) {
// 模拟向后端请求验证码
uni.showLoading({
title: '正在获取验证码'
});
setTimeout(() => {
uni.hideLoading();
// 这里此提示会被this.start()方法中的提示覆盖
uni.$u.toast('验证码已发送');
// 通知验证码组件内部开始倒计时
this.$refs.uCode.start();
}, 2000);
}
}
});
} else {
uni.$u.toast('倒计时结束后再发送');
}
},
end() {
uni.$u.toast('倒计时结束');
},
start() {
uni.$u.toast('倒计时开始');
}
}
};
</script>
<style lang="scss" scoped>
.head {
padding-top: 80rpx;
.head-title {
.head-icon {
width: 130rpx;
height: 56rpx;
background: #eee;
}
.head-text {
width: 176rpx;
height: 40rpx;
font-size: 44rpx;
font-weight: 600;
color: #003787;
line-height: 40rpx;
}
}
}
.phone-type {
width: 156rpx;
height: 96rpx;
font-weight: 500;
color: #333333;
line-height: 28px;
}
.cont-form {
margin-top: 70rpx;
padding: 0 34rpx;
.division {
height: 32rpx;
width: 2rpx;
background: #f0f0f0;
margin-right: 28rpx;
}
}
/deep/.dep-input {
color: #999999 !important;
font-size: 28rpx !important;
line-height: 28rpx !important;
}
.btn-submit {
padding: 10rpx 16rpx;
background: #ffffff;
line-height: 44rpx;
border: 2rpx solid #d9d9d9;
border-radius: 10rpx;
font-weight: 400;
color: rgba(0, 0, 0, 0.65);
font-size: 28rpx;
}
.submit {
margin-top: 68rpx;
height: 96rpx;
// background: linear-gradient(135deg, #0B57D2 0%, #77A5FF 100%) #004AC2;
background: #004ac2;
// box-shadow: 0px 8px 12px 0px rgba(0, 74, 194, 0.08), 0px 4px 10px 0px rgba(20, 101, 232, 0.17);
border-radius: 48rpx;
font-size: 30rpx;
font-weight: 600;
color: #ffffff;
line-height: 42rpx;
text-shadow: 0rpx 8rpx 12rpx rgba(0, 74, 194, 0.08);
}
.check-login {
padding-top: 32rpx;
padding-left: 36rpx;
font-size: 24rpx;
font-weight: 400;
color: #333333;
line-height: 40rpx;
}
</style>
<template>
<view class="">
<u-navbar title="" :placeholder="true"></u-navbar>
<view class="cont">
<view class="head-title color333 ft36 flex content-center" style="padding-top: 86rpx;">请设置账号密码</view>
<view class="head-msg pt28">如果您是首次登陆,或者已经忘记账号密码,可以在本页设置账号密码。后续可通过手机号+微信密码登陆账号。</view>
</view>
<view class="cont-form">
<u--form labelPosition="left" :errorType="errorType" :model="model" :rules="rules" ref="model">
<view class="flex items-center" style="border-bottom: 2rpx solid #EFEFEF;margin-bottom: 28rpx;">
<view class="phone-type flex items-center pl28 colro333 ft28">+86</view>
<view class="division"></view>
<u-form-item prop="userInfo.mobile" :borderBottom="false" ref="item" style="flex:1">
<u--input v-model="model.userInfo.mobile" :placeholderClass="'dep-input'" placeholder="请输入手机号" border="none"></u--input>
</u-form-item>
</view>
<view class="flex items-center" style="border-bottom: 2rpx solid #EFEFEF;margin-bottom: 28rpx;">
<view class="phone-type flex items-center pl28 colro333 ft28">密码</view>
<view class="division"></view>
<u-form-item prop="userInfo.password" :borderBottom="false" ref="item" style="flex:1">
<u--input v-model="model.userInfo.password" :placeholderClass="'dep-input'" placeholder="请设置密码" border="none"></u--input>
</u-form-item>
</view>
<view class="flex items-center" style="border-bottom: 2rpx solid #EFEFEF;margin-bottom: 28rpx;">
<view class="phone-type flex items-center pl28 colro333 ft28">确认密码</view>
<view class="division"></view>
<u-form-item prop="userInfo.cnfmPwd" :borderBottom="false" ref="item" style="flex:1">
<u--input v-model="model.userInfo.cnfmPwd" :placeholderClass="'dep-input'" placeholder="请再次设置密码" border="none"></u--input>
</u-form-item>
</view>
</u--form>
<u-button size="30rpx" class="submit" @click="handleSubmit">保存</u-button>
</view>
</view>
</template>
<script>
export default {
data() {
return {
errorType: '',
model: {
userInfo: {
mobile: '',
password:'',
cnfmPwd:''
}
},
rules: {}
};
},
methods: {}
};
</script>
<style lang="scss" scoped>
.cont {
padding: 0 32rpx;
.head-title {
font-weight: 600;
line-height: 40rpx;
}
.head-msg {
font-size: 30rpx;
font-weight: 400;
color: #4e4f50;
line-height: 56rpx;
}
}
.phone-type {
width: 156rpx;
height: 96rpx;
font-weight: 500;
color: #333333;
line-height: 28px;
}
.cont-form {
margin-top: 70rpx;
padding: 0 34rpx;
.division {
height: 32rpx;
width: 2rpx;
background: #f0f0f0;
margin-right: 28rpx;
}
}
/deep/.dep-input {
color: #999999 !important;
font-size: 28rpx !important;
line-height: 28rpx !important;
}
.submit {
margin-top: 68rpx;
height: 96rpx;
// background: linear-gradient(135deg, #0B57D2 0%, #77A5FF 100%) #004AC2;
background: #004ac2;
// box-shadow: 0px 8px 12px 0px rgba(0, 74, 194, 0.08), 0px 4px 10px 0px rgba(20, 101, 232, 0.17);
border-radius: 48rpx;
font-size: 30rpx;
font-weight: 600;
color: #ffffff;
line-height: 42rpx;
text-shadow: 0rpx 8rpx 12rpx rgba(0, 74, 194, 0.08);
}
</style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="找服务" :placeholder="true"></u-navbar>
<!-- 搜索 -->
<view class="search-box flex row content-center">
<view class="search-input flex row items-center">
<u-search v-model="search.text" placeholder="搜产品、服务" actionText="搜索" :showAction="false" bgColor="#ffffff"></u-search>
</view>
<u-icon name="chat" size="40" color="#ffffff"></u-icon>
<u-icon name="chat" size="40" color="#ffffff"></u-icon>
<u-icon name="chat" size="40" color="#ffffff"></u-icon>
</view>
<view class="main">
<view>
<u--image width="750rpx" height="160rpx" :src="require('@/assets/doctor-propaganda.png')"></u--image>
</view>
<view class="menu">
<view class="menu-item card menu-item-row">
<u-icon name="chat" size="40" color="#ffffff"></u-icon>
<text>急速配药</text>
</view>
<view class="menu-item card">
<u-icon name="chat" size="40" color="#ffffff"></u-icon>
<text>急速配药</text>
</view>
<view class="menu-item card">
<u-icon name="chat" size="40" color="#ffffff"></u-icon>
<text>急速配药</text>
</view>
<view class="menu-item card">
<u-icon name="chat" size="40" color="#ffffff"></u-icon>
<text>急速配药</text>
</view>
<view class="menu-item card">
<u-icon name="chat" size="40" color="#ffffff"></u-icon>
<text>急速配药</text>
</view>
</view>
<view>
<u--image width="750rpx" height="130rpx" :src="require('@/assets/service-other.png')"></u--image>
</view>
<!-- 限时专场、体验专区、餐饮专区 -->
<view class="rcommd card mt30">
<view class="flex row content-between items-center">
<u-tabs :list="[{ name: '限时专场' }, { name: '体验专区' }, { name: '餐饮专区' }]"></u-tabs>
<view class="flex items-center">
<text class="font-20">查看更多</text>
<u-icon name="arrow-right" size="20" color="#c2ced8"></u-icon>
</view>
</view>
<view class="mt30">
<u-list @scrolltolower="scrolltolower">
<u-list-item v-for="(item, index) in rcommdList" :key="index">
<u-cell :title="`列表长度-${index + 1}`">
<u-avatar slot="icon" shape="square" size="35" :src="item.url" customStyle="margin: -3px 5px -3px 0"></u-avatar>
</u-cell>
</u-list-item>
</u-list>
</view>
</view>
</view>
<u-tabbar value="service" :fixed="true" :placeholder="true" :safeAreaInsetBottom="true">
<u-tabbar-item text="找医生" name="doctor" icon="home" @click="tabbarItem"></u-tabbar-item>
<u-tabbar-item text="找服务" name="service" icon="photo" @click="tabbarItem"></u-tabbar-item>
<u-tabbar-item text="找课程" name="curriculum" icon="play-right" @click="tabbarItem"></u-tabbar-item>
<u-tabbar-item text="个人中心" name="mine" icon="account" @click="tabbarItem"></u-tabbar-item>
</u-tabbar>
</view>
</template>
<script>
export default {
data() {
return {
rcommdList: [1, 2, 3],
urls: ['https://cdn.uviewui.com/uview/album/1.jpg', 'https://cdn.uviewui.com/uview/album/2.jpg', 'https://cdn.uviewui.com/uview/album/3.jpg', 'https://cdn.uviewui.com/uview/album/4.jpg', 'https://cdn.uviewui.com/uview/album/5.jpg', 'https://cdn.uviewui.com/uview/album/6.jpg', 'https://cdn.uviewui.com/uview/album/7.jpg', 'https://cdn.uviewui.com/uview/album/8.jpg', 'https://cdn.uviewui.com/uview/album/9.jpg', 'https://cdn.uviewui.com/uview/album/10.jpg']
}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped>
.container {
background: #004bb9;
}
.search-box {
width: 750rpx;
padding: 30rpx;
}
.search-input {
width: 490rpx;
}
.main {
padding: 30rpx 0 0 0;
border-radius: 30rpx 30rpx 0 0;
background: #f5f5f9;
}
.menu {
display: grid;
grid-template-columns: 240rpx 200rpx 200rpx;
grid-gap: 20rpx;
grid-template-rows: 130rpx 130rpx;
width: 750rpx;
margin: 30rpx 0;
padding: 0 30rpx;
}
.menu-item {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
background: #289efa;
}
.menu-item-row {
grid-row-start: 1;
grid-row-end: 3;
}
</style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="container">
<u-navbar title="医生主页" :placeholder="true"></u-navbar>
<view class="main"> </view>
</view>
</template>
<script>
export default {
data() {
return {}
},
onShow() {},
methods: {
tabbarItem(itemName) {
console.log(itemName)
uni.navigateTo({ url: '/pages/' + itemName + '/home' })
}
}
}
</script>
<style lang="scss" scoped></style>
<template>
<view class="">
<u-navbar title="新增常用语句" :placeholder="true"></u-navbar>
<view class="content">
<u--textarea v-model="value" placeholder="请输入..." style="background-color: #F5F6F7;min-height: 500rpx;" :autoHeight="true" maxlength="2000" count></u--textarea>
</view>
<view class="btm-opt flex content-between">
<view class="btn-edit">
确定
</view>
</view>
</view>
</template>
<script>
export default{
data(){
return{
value:''
}
}
}
</script>
<style lang="scss" scoped>
.content{
padding: 16rpx 24rpx;
}
.btm-opt{
position: fixed;
bottom: 0;
left: 0;
width: 100%;
height: 132rpx;
padding: 32rpx 24rpx 0 24rpx;
background: #fff;
box-shadow: 0px -4px 12px 0px rgba(0, 0, 0, 0.08);
.btn-edit{
width: 100%;
height: 84rpx;
text-align: center;
line-height: 84rpx;
border-radius: 8rpx;
background: linear-gradient(135deg, #0B57D2 0%, #77A5FF 100%);
border: 2rpx solid #F1F1F1;
font-size: 32rpx;
color: #fff;
}
}
</style>
\ No newline at end of file
<template>
<view class="">
<u-navbar title="常用语" :placeholder="true"></u-navbar>
<view class="list" v-for="i in 3">
糖尿病是一组以高血糖为特征的代谢性疾病。
</view>
<view class="btm-opt flex content-between">
<view class="btn-del" >
管理常用语句
</view>
<view class="btn-edit">
添加常用语
</view>
</view>
</view>
</template>
<script>
</script>
<style lang="scss" scoped>
.list{
padding: 20rpx 24rpx;
font-size: 30rpx;
color: #4E4F50;
line-height: 56rpx;
border-bottom: 2rpx solid #F5F6F7;
}
.btm-opt{
position: fixed;
bottom: 0;
left: 0;
width: 100%;
height: 132rpx;
padding: 32rpx 24rpx 0 24rpx;
background: #fff;
box-shadow: 0px -4px 12px 0px rgba(0, 0, 0, 0.08);
.btn-del{
width: 336rpx;
height: 84rpx;
text-align: center;
line-height: 84rpx;
border-radius: 8rpx;
border: 2rpx solid #F1F1F1;
font-size: 32rpx;
color: #333333;
}
.btn-edit{
width: 336rpx;
height: 84rpx;
text-align: center;
line-height: 84rpx;
border-radius: 8rpx;
background: linear-gradient(135deg, #0B57D2 0%, #77A5FF 100%);
border: 2rpx solid #F1F1F1;
font-size: 32rpx;
color: #fff;
}
}
</style>
\ No newline at end of file
......@@ -232,4 +232,16 @@
.pl44 { padding-left: 44rpx; }
.pl46 { padding-left: 46rpx; }
.pl48 { padding-left: 48rpx; }
.pl50 { padding-left: 50rpx; }
\ No newline at end of file
.pl50 { padding-left: 50rpx; }
.color333{
color:#333333
}
.ft22{font-size: 22rpx;}
.ft24{font-size: 24rpx;}
.ft26{font-size: 26rpx;}
.ft28{font-size: 28rpx;}
.ft30{font-size: 30rpx;}
.ft32{font-size: 32rpx;}
.ft34{font-size: 34rpx;}
.ft36{font-size: 36rpx;}
.ft38{font-size: 38rpx;}
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 sign in to comment