7 | 小程序云开发挑战赛 8 | 参赛作品 FindJob 9 |
10 | -------------------------------------------------------------------------------- /cloudfunctions/post-stat/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "post-stat", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "wx-server-sdk": "~2.2.0" 13 | } 14 | } -------------------------------------------------------------------------------- /cloudfunctions/user-login/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "user-login", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "wx-server-sdk": "~2.2.0" 13 | } 14 | } -------------------------------------------------------------------------------- /cloudfunctions/get-stat-pv/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "get-stat-pv", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "wx-server-sdk": "~2.2.0" 13 | } 14 | } -------------------------------------------------------------------------------- /cloudfunctions/is-favorite/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "is-favorite", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "wx-server-sdk": "~2.2.0" 13 | } 14 | } -------------------------------------------------------------------------------- /cloudfunctions/save-favorite/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "save-favorite", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "wx-server-sdk": "~2.2.0" 13 | } 14 | } -------------------------------------------------------------------------------- /cloudfunctions/user-favorite/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "user-favorite", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "wx-server-sdk": "~2.2.0" 13 | } 14 | } -------------------------------------------------------------------------------- /scf/serverless.yaml: -------------------------------------------------------------------------------- 1 | component: scf 2 | name: ap-guangzhou_dotnet_demo 3 | org: app 4 | app: dotnet_demo 5 | stage: dev 6 | inputs: 7 | name: dotnet_demo 8 | src: ./ 9 | description: dotnet demo function. Dotnet模版函数 10 | handler: index.main_handler 11 | runtime: CustomRuntime 12 | namespace: default 13 | region: ap-guangzhou 14 | memorySize: 128 15 | timeout: 3 16 | -------------------------------------------------------------------------------- /cloudfunctions/get-stat-apply/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "get-stat-apply", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "wx-server-sdk": "~2.2.0" 13 | } 14 | } -------------------------------------------------------------------------------- /cloudfunctions/get-stat-top-city/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "get-stat-top-city", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "wx-server-sdk": "~2.2.0" 13 | } 14 | } -------------------------------------------------------------------------------- /cloudfunctions/get-stat-top-search/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "get-stat-top-search", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "wx-server-sdk": "~2.2.0" 13 | } 14 | } -------------------------------------------------------------------------------- /scf/README.md: -------------------------------------------------------------------------------- 1 | # API接口说明 2 | 3 | 找工作提供2个接口, 聚合查询招聘网站的岗位数据 以及查看岗位的详细信息。 4 | 5 | 1. 查询招聘网站的岗位数据 6 | - path: /api/jobs/getjobs?sources=xxxx&city=xxx&searchkey=xxxxx&pageindex=1 7 | - method: httpget 8 | - 格式: json 9 | 2. 查看岗位的详细信息 10 | - path: /api/jobs/getdetailsinfo?source=xxxx&url=xxx 11 | - method: httpget 12 | - 格式: json 13 | 14 | # 应用配置 15 | 16 | 使用Redis 用户的最新查询数据,默认缓存10分钟。 -------------------------------------------------------------------------------- /miniprogram/pages/job/detail.wxss: -------------------------------------------------------------------------------- 1 | .job-detail-container { 2 | position: relative; 3 | padding-bottom: 100rpx; 4 | } 5 | 6 | .job-base-infol { 7 | background: white; 8 | } 9 | 10 | .apply-job { 11 | position: fixed; 12 | bottom: 0; 13 | left: 0; 14 | width: 100%; 15 | box-shadow: 0 0 8px rgba(0,0,0,0.1); 16 | } 17 | 18 | .company-intro { 19 | line-height: 180%; 20 | } -------------------------------------------------------------------------------- /cloudfunctions/is-favorite/index.js: -------------------------------------------------------------------------------- 1 | const cloud = require('wx-server-sdk') 2 | cloud.init() 3 | const db = cloud.database() 4 | 5 | exports.main = async (event, context) => { 6 | const openId = cloud.getWXContext().OPENID; 7 | var favorite = await db.collection('favorites').where({ 8 | openId: openId, 9 | url: event.url 10 | }).get(); 11 | return favorite.data.length > 0; 12 | } -------------------------------------------------------------------------------- /scf/LBS.Amap.SDK/Models/BaseParameter.cs: -------------------------------------------------------------------------------- 1 | using System.ComponentModel.DataAnnotations; 2 | 3 | namespace LBS.Amap.SDK.Models 4 | { 5 | public abstract class BaseParameter 6 | { 7 | ///可选值:JSON,XML10 | ///
Sorry, there's nothing at this address.
8 |需要搜索的IP地址(仅支持国内)若不填写IP,则取客户http之中的请求来进行定位13 | ///
选择数字签名认证的付费用户必填20 | ///
图表正在加载中...
7 | } 8 | 9 | @code { 10 | PieConfig chartConfig = new PieConfig 11 | { 12 | Height = 650, 13 | Title = new Title 14 | { 15 | Visible = true, 16 | Text = "FindJob 搜索城市 Top10 排行榜" 17 | }, 18 | Description = new Description 19 | { 20 | Visible = true, 21 | Text = "本图表统计 FindJob 搜索次数最多的城市", 22 | }, 23 | ForceFit = true, 24 | Padding = "auto", 25 | Meta = new 26 | { 27 | _id = new 28 | { 29 | Alias = "城市" 30 | }, 31 | count = new 32 | { 33 | Alias = "搜索次数" 34 | } 35 | }, 36 | AngleField = "count", 37 | ColorField = "_id", 38 | Label = new PieLabelConfig 39 | { 40 | Visible = true, 41 | Type = "inner" 42 | } 43 | }; 44 | 45 | IChartComponent chartInstance = null; 46 | IEnumerable图表正在加载中...
7 | } 8 | 9 | @code { 10 | BarConfig chartConfig = new BarConfig 11 | { 12 | Height = 650, 13 | Title = new Title 14 | { 15 | Visible = true, 16 | Text = "FindJob 搜索关键词 Top10 排行榜" 17 | }, 18 | Description = new Description 19 | { 20 | Visible = true, 21 | Text = "本图表统计 FindJob 搜索次数最多的关键词", 22 | }, 23 | ForceFit = true, 24 | Padding = "auto", 25 | XField = "count", 26 | YField = "_id", 27 | Meta = new 28 | { 29 | _id = new 30 | { 31 | Alias = "关键词" 32 | }, 33 | count = new 34 | { 35 | Alias = "搜索次数" 36 | } 37 | }, 38 | Label = new BarViewConfigLabel 39 | { 40 | Visible = true, 41 | Position = "left" 42 | } 43 | }; 44 | 45 | IChartComponent chartInstance = null; 46 | IEnumerableLoading...
19 |规则遵循:国家、省份、城市、区县、城镇、乡村、街道、门牌号码、屋邨、大厦13 | ///
如果需要解析多个地址的话,请用"|"进行间隔,并且将 batch 参数设置为 true,最多支持 10 个地址进进行"|"分割形式的请求14 | ///
可选输入内容包括:指定城市的中文(如北京)、指定城市的中文全拼(beijing)、citycode(010)、adcode(110000),不支持县级市22 | ///
当指定城市查询内容为空时,会进行全国范围内的地址转换检索23 | ///
callback 值是用户定义的函数名称,此参数只在 output 参数设置为 JSON 时有效43 | ///
可选值:城市名称/citycode25 | ///
图表正在加载中...
7 | } 8 | 9 | @code { 10 | LineConfig chartConfig = new LineConfig 11 | { 12 | Height = 650, 13 | Title = new Title 14 | { 15 | Visible = true, 16 | Text = "FindJob 访问统计" 17 | }, 18 | Description = new Description 19 | { 20 | Visible = true, 21 | Text = "本图表统计30天内 FindJob 访问情况", 22 | }, 23 | ForceFit = true, 24 | Padding = "auto", 25 | XField = "_id", 26 | YField = "pv", 27 | Meta = new 28 | { 29 | _id = new 30 | { 31 | Alias = "日期" 32 | }, 33 | pv = new 34 | { 35 | Alias = "PV" 36 | } 37 | }, 38 | Label = new ColumnViewConfigLabel 39 | { 40 | Visible = true, 41 | Style = new TextStyle 42 | { 43 | FontSize = 12, 44 | FontWeight = 600, 45 | Opacity = 60, 46 | } 47 | }, 48 | Interactions = new Interaction[] 49 | { 50 | new Interaction 51 | { 52 | Type = "slider", 53 | Cfg = new 54 | { 55 | start = 0, 56 | end = 1, 57 | } 58 | } 59 | }, 60 | Smooth = true 61 | }; 62 | 63 | IChartComponent chartInstance = null; 64 | List图表正在加载中...
7 | } 8 | 9 | @code { 10 | ColumnConfig chartConfig = new ColumnConfig 11 | { 12 | Height = 650, 13 | Title = new Title 14 | { 15 | Visible = true, 16 | Text = "FindJob 申请职位按钮点击统计" 17 | }, 18 | Description = new Description 19 | { 20 | Visible = true, 21 | Text = "本图表统计30天内 FindJob 申请职位按钮点击情况", 22 | }, 23 | ForceFit = true, 24 | Padding = "auto", 25 | XField = "_id", 26 | YField = "pv", 27 | Meta = new 28 | { 29 | _id = new 30 | { 31 | Alias = "日期" 32 | }, 33 | pv = new 34 | { 35 | Alias = "点击量" 36 | } 37 | }, 38 | Label = new ColumnViewConfigLabel 39 | { 40 | Visible = true, 41 | Position = "middle", 42 | Style = new TextStyle 43 | { 44 | FontSize = 12, 45 | FontWeight = 600, 46 | Opacity = 60, 47 | } 48 | }, 49 | Interactions = new Interaction[] 50 | { 51 | new Interaction 52 | { 53 | Type = "slider", 54 | Cfg = new 55 | { 56 | start = 0, 57 | end = 1, 58 | } 59 | } 60 | } 61 | }; 62 | 63 | IChartComponent chartInstance = null; 64 | List